Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3 and matplotlib 1.2 issue on Linux #1873

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

Python 3 and matplotlib 1.2 issue on Linux #1873

amitsaha opened this issue Mar 30, 2013 · 2 comments

Comments

@amitsaha
Copy link

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.

@tomspur
Copy link
Contributor

tomspur commented Apr 10, 2013

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

@dmcdougall
Copy link
Member

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants