Skip to content

Commit

Permalink
Merge pull request #7222 from greg-roper/master
Browse files Browse the repository at this point in the history
Catch IO errors when building font cache
  • Loading branch information
NelleV committed Oct 5, 2016
2 parents dc12ca4 + ac20f76 commit b34c55d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/matplotlib/font_manager.py
Expand Up @@ -591,6 +591,9 @@ def createFontList(fontfiles, fontext='ttf'):
verbose.report("Cannot handle unicode filenames")
# print >> sys.stderr, 'Bad file is', fpath
continue
except IOError:
verbose.report("IO error - cannot open font file %s" % fpath)
continue
try:
prop = ttfFontProperty(font)
except (KeyError, RuntimeError, ValueError):
Expand Down

0 comments on commit b34c55d

Please sign in to comment.