ValueError if right mouse click in Matplotlib canvas

Issue #179 resolved
M. Gronle created an issue

At least for Matplot 3.4.3 and 3.4.4, a ValueError occurs if one makes a right-mouse click in the canvas:

  File "C:\itom\3rdParty\Python\lib\site-packages\matplotlib\cbook\__init__.py", line 81, in _exception_printer
    raise exc
  File "C:\itom\3rdParty\Python\lib\site-packages\matplotlib\cbook\__init__.py", line 224, in process
    func(*args, **kwargs)
  File "C:\itom\3rdParty\Python\lib\site-packages\matplotlib\backend_bases.py", line 2752, in button_press
    button_press_handler(event)
  File "C:\itom\3rdParty\Python\lib\site-packages\matplotlib\backend_bases.py", line 2618, in button_press_handler
    button_name = str(MouseButton(event.button))
  File "C:\itom\3rdParty\Python\lib\enum.py", line 339, in __call__
    return cls.__new__(cls, value)
  File "C:\itom\3rdParty\Python\lib\enum.py", line 662, in __new__
    raise ve_exc
ValueError: None is not a valid MouseButton

Comments (2)

  1. M. Gronle reporter

    It seems that backend_itom_v3.py, mouseEvent is sometimes called with the argument button=None. Check this.

  2. Log in to comment