Return of the mystery error.

This is not a mystery error. This error pops up on some bad

    > fonts when the FontManager creates the dictionary of TTF
    > based fonts. An example is the CSD Font that installs with
    > jgrasp (jgrasp.org).

That is very helpful -- if one of you can send me a problematic font
file offlist I will try and replicate and fix this bug. By running in
--verbose-debug, you should be able to ascertain which file is causing
the grief.

    > BTW: As the bakoma fonts are free now, is this ttf cache
    > needed by default anymore? The CTAN bakoma.zip includes now
    > 140 TTF fonts.

I don't see how license of the bakoma fonts and the ttf cache are
related. The cache is used to store a dictionary of which fonts were
found on your system so that it doesn't have to search the system
every time. I do not want to configure mpl to use only the bakoma
fonts since I haven't been too impressed with the cm*10*.ttf fonts I
used with mathtext. For example, last I checked they did not appear
to have kerning information, and the letter stroke thicknesses appear
uneven to me in some cases. Perhaps the others are better, or I am
doing something wrong.

But in any case, thanks for the heads up on the license change. I
have update mpl CVS with the new fonts and license info.

JDH

John Hunter wrote:

"Carl" == Carl Dr Kleffner <cmkleffner@...380...> writes:
           
   > This is not a mystery error. This error pops up on some bad
   > fonts when the FontManager creates the dictionary of TTF
   > based fonts. An example is the CSD Font that installs with
   > jgrasp (jgrasp.org).

That is very helpful -- if one of you can send me a problematic font
file offlist I will try and replicate and fix this bug. By running in
--verbose-debug, you should be able to ascertain which file is causing
the grief.

Here's the verbose-debug output.

C:\proj\compclust\win32\compclustshell>C:\Python23\python.exe matplotlibtest.py
--verbose-debug
matplotlib data path C:\Python23\share\matplotlib
$HOME=C:\Documents and Settings\King
CONFIGDIR=C:\Documents and Settings\King\.matplotlib
loaded rc file C:\Python23\share\matplotlib\matplotlibrc
matplotlib version 0.83.1
verbose.level debug
interactive is False
platform is win32
loaded modules: ['pylab', '__future__', 'copy_reg', 'sre_compile', 'distutils',
'locale', '_sre', '__main__', 'site', '__builtin__', 'datetime', 'matplotlib.tem
pfile', 'encodings', 'os.path', 'encodings.encodings', 'sre_constants', 'distuti
ls.string', 'dateutil', 'matplotlib.datetime', 'strop', '_random', 'tempfile', '
errno', 'matplotlib.warnings', 'encodings.codecs', 'matplotlib.sys', 're', 'ntpa
th', 'pytz.sys', 'UserDict', 'distutils.sysconfig', 'encodings.exceptions', 'nt'
, 'pytz.sets', 'math', 'stat', 'zipimport', 'string', 'warnings', 'encodings.typ
es', '_codecs', 'sets', 'distutils.os', 'matplotlib', 'encodings.cp1252', 'sys',
'pytz.tzinfo', 'pytz', 'pytz.datetime', 'matplotlib.__future__', 'codecs', 'dis
tutils.re', 'matplotlib.pytz', 'types', 'matplotlib.dateutil', '_locale', 'matpl
otlib.os', 'thread', 'sre', 'bisect', 'matplotlib.distutils', 'signal', 'distuti
ls.errors', 'random', 'linecache', 'itertools', 'time', 'exceptions', 'sre_parse
', 'pytz.bisect', 'distutils.sys', 'os']
numerix Numeric 23.8
font search path ['C:\\Python23\\share\\matplotlib']
trying fontname C:\Python23\share\matplotlib\cmex10.ttf
trying fontname C:\Python23\share\matplotlib\cmmi10.ttf
trying fontname C:\Python23\share\matplotlib\cmr10.ttf
trying fontname C:\Python23\share\matplotlib\VeraMono.ttf
trying fontname C:\Python23\share\matplotlib\cmsy10.ttf
trying fontname C:\Python23\share\matplotlib\VeraSeBd.ttf
trying fontname C:\Python23\share\matplotlib\cmtt10.ttf
trying fontname C:\Python23\share\matplotlib\Vera.ttf
Assertion failed: ob_refcnt == 0, file CXX\cxx_extensions.cxx, line 1031

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

-Brandon King

P.S. Thanks guys for helping with this!

Hi Guys,
    I found the font that was causing the problem by adding 'verbose.report('CreateFontDict: %s' % (fpath), 'debug')' just
inside the 'for fpath in fontfiles:' inside the font_manager.createFontDict function. Here's the last part of the output:

CreateFontDict: C:\WINDOWS\Fonts\VIVALDII.TTF
CreateFontDict: c:\windows\fonts\lfax.ttf
CreateFontDict: C:\WINDOWS\Fonts\PALSCRI.TTF
CreateFontDict: c:\windows\fonts\orlando.ttf
Assertion failed: ob_refcnt == 0, file CXX\cxx_extensions.cxx, line 1031

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

···

----------------------------------------------------------------------------

When I remove orlando.tff from c:\windows\fonts\, matplotlib works fine. Thanks again for your help guys!

-Brandon King

Brandon King wrote:

John Hunter wrote:

   > This is not a mystery error. This error pops up on some bad
   > fonts when the FontManager creates the dictionary of TTF
   > based fonts. An example is the CSD Font that installs with
   > jgrasp (jgrasp.org). That is very helpful -- if one of you can send me a problematic font
file offlist I will try and replicate and fix this bug. By running in
--verbose-debug, you should be able to ascertain which file is causing
the grief.

Here's the verbose-debug output.

C:\proj\compclust\win32\compclustshell>C:\Python23\python.exe matplotlibtest.py
--verbose-debug
matplotlib data path C:\Python23\share\matplotlib
$HOME=C:\Documents and Settings\King
CONFIGDIR=C:\Documents and Settings\King\.matplotlib
loaded rc file C:\Python23\share\matplotlib\matplotlibrc
matplotlib version 0.83.1
verbose.level debug
interactive is False
platform is win32
loaded modules: ['pylab', '__future__', 'copy_reg', 'sre_compile', 'distutils',
'locale', '_sre', '__main__', 'site', '__builtin__', 'datetime', 'matplotlib.tem
pfile', 'encodings', 'os.path', 'encodings.encodings', 'sre_constants', 'distuti
ls.string', 'dateutil', 'matplotlib.datetime', 'strop', '_random', 'tempfile', '
errno', 'matplotlib.warnings', 'encodings.codecs', 'matplotlib.sys', 're', 'ntpa
th', 'pytz.sys', 'UserDict', 'distutils.sysconfig', 'encodings.exceptions', 'nt'
, 'pytz.sets', 'math', 'stat', 'zipimport', 'string', 'warnings', 'encodings.typ
es', '_codecs', 'sets', 'distutils.os', 'matplotlib', 'encodings.cp1252', 'sys',
'pytz.tzinfo', 'pytz', 'pytz.datetime', 'matplotlib.__future__', 'codecs', 'dis
tutils.re', 'matplotlib.pytz', 'types', 'matplotlib.dateutil', '_locale', 'matpl
otlib.os', 'thread', 'sre', 'bisect', 'matplotlib.distutils', 'signal', 'distuti
ls.errors', 'random', 'linecache', 'itertools', 'time', 'exceptions', 'sre_parse
', 'pytz.bisect', 'distutils.sys', 'os']
numerix Numeric 23.8
font search path ['C:\\Python23\\share\\matplotlib']
trying fontname C:\Python23\share\matplotlib\cmex10.ttf
trying fontname C:\Python23\share\matplotlib\cmmi10.ttf
trying fontname C:\Python23\share\matplotlib\cmr10.ttf
trying fontname C:\Python23\share\matplotlib\VeraMono.ttf
trying fontname C:\Python23\share\matplotlib\cmsy10.ttf
trying fontname C:\Python23\share\matplotlib\VeraSeBd.ttf
trying fontname C:\Python23\share\matplotlib\cmtt10.ttf
trying fontname C:\Python23\share\matplotlib\Vera.ttf
Assertion failed: ob_refcnt == 0, file CXX\cxx_extensions.cxx, line 1031

This application has requested the Runtime to terminate it in an unusual way.
Please contact the application's support team for more information.

-Brandon King

P.S. Thanks guys for helping with this!

-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO September
19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * TechWell - Software Conferences, Training, & Resources
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
matplotlib-users List Signup and Options