Python 3 and matplotlib 1.2 issue on Linux #1873

Closed
amitsaha opened this Issue Mar 30, 2013 · 2 comments

Comments

Projects
None yet
3 participants

When I attempt to run the histogram demo using Python 3 + matplotlib 1.2, I get this traceback:

Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib64/python3.3/tkinter/__init__.py", line 1442, in __call__
    return self.func(*args)
  File "/usr/lib64/python3.3/site-packages/matplotlib/backends/backend_tkagg.py", line 276, in resize
    self.show()
  File "/usr/lib64/python3.3/site-packages/matplotlib/backends/backend_tkagg.py", line 348, in draw
    FigureCanvasAgg.draw(self)
  File "/usr/lib64/python3.3/site-packages/matplotlib/backends/backend_agg.py", line 439, in draw
    self.figure.draw(self.renderer)
  File "/usr/lib64/python3.3/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib64/python3.3/site-packages/matplotlib/figure.py", line 1000, in draw
    func(*args)
  File "/usr/lib64/python3.3/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib64/python3.3/site-packages/matplotlib/axes.py", line 2088, in draw
    a.draw(renderer)
  File "/usr/lib64/python3.3/site-packages/matplotlib/artist.py", line 55, in draw_wrapper
    draw(artist, renderer, *args, **kwargs)
  File "/usr/lib64/python3.3/site-packages/matplotlib/axis.py", line 1051, in draw
    renderer)
  File "/usr/lib64/python3.3/site-packages/matplotlib/axis.py", line 1000, in _get_tick_bboxes
    extent = tick.label1.get_window_extent(renderer)
  File "/usr/lib64/python3.3/site-packages/matplotlib/text.py", line 753, in get_window_extent
    bbox, info = self._get_layout(self._renderer)
  File "/usr/lib64/python3.3/site-packages/matplotlib/text.py", line 305, in _get_layout
    ismath=False)
  File "/usr/lib64/python3.3/site-packages/matplotlib/backends/backend_agg.py", line 208, in get_text_width_height_descent
    font = self._get_agg_font(prop)
  File "/usr/lib64/python3.3/site-packages/matplotlib/backends/backend_agg.py", line 246, in _get_agg_font
    fname = findfont(prop)
  File "/usr/lib64/python3.3/site-packages/matplotlib/font_manager.py", line 1300, in findfont
    result = fc_match(prop, fontext)
  File "/usr/lib64/python3.3/site-packages/matplotlib/font_manager.py", line 1284, in fc_match
    for match in _fc_match_regex.finditer(output):
TypeError: can't use a string pattern on a bytes-like object

Upon setting USE_FONTCONFIG = False in font_manager.py, it worked. Not sure which one is the issue here.

Contributor

tomspur commented Apr 10, 2013

This will be fixed, once issue #1879 is solved.

Member

dmcdougall commented Jun 16, 2013

It looks like #1879 and #1921 were resolved. This should be resolved now, so I'll close it.

@amitsaha If I am mistaken and this is still a problem for you, please feel free to reopen this issue.

@dmcdougall dmcdougall closed this Jun 16, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment