juliencegarra / OpenMATB

OpenMATB: A Multi-Attribute Task Battery promoting task customization, software extendability and experiment replicability
Other
43 stars 32 forks source link

Can't extit program after error see log scenario with pyglet-gui #22

Closed thomakl closed 1 year ago

thomakl commented 1 year ago

Hi,

If trigger a 'OpenMATB - fatal error !' I can't exit the program with a key pressed. That would require me to force the exit by killing it. See the traceback below :

Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0
Exception ignored on calling ctypes callback function: <function Win32Window._get_window_proc.<locals>.f at 0x0000017B3C118940>
Traceback (most recent call last):
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 747, in f
    result = event_handler(msg, wParam, lParam)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\win32\__init__.py", line 819, in _event_key
    self.dispatch_event(ev, symbol, modifiers)
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\window\__init__.py", line 1352, in dispatch_event
    if EventDispatcher.dispatch_event(self, *args) != False:
  File "C:\Users\username\Projets\openmatb\venv\lib\site-packages\pyglet\event.py", line 408, in dispatch_event
    if handler(*args):
  File "C:\Users\username\Projets\openmatb\core\dialog.py", line 91, in on_key_press
    exit(0)
  File "C:\Users\username\AppData\Local\Programs\Python\Python39\lib\_sitebuiltins.py", line 26, in __call__
    raise SystemExit(code)
SystemExit: 0

NB : the fatal error was trigger because it didn't comply with the scenario I have run.

Cheers, 2023-03-17_OpenMATB-fatal_error

benoitvalery commented 1 year ago

Hi @thomakl, can you give some more information : platform used, scenario used, OpenMATB version used. Thanks (I think the bug has been corrected by @juliencegarra on his last commits : master branch).

thomakl commented 1 year ago

Hi @benoitvalery,

I am using the program :

Cheers,

benoitvalery commented 1 year ago

Hi @thomakl, This issue was resolved by the last commit. Errors are now managed in a more consistent manner, which should help to prevent this Window bug. Check the master version to see if it’s OK. Do not hesitate to re-open this ticket if need be.