I've corrected some obvious issues, and we can fix others over time.
Mypy tests are currently broken, as adding the type hints has increased
mypy's testing surface.
presumably happening if multiple requests are sent before previous
response fetch times out
Caught exception:
File "aqt/webview.py", line 314, in handler
File "aqt/editor.py", line 351, in <lambda>
File "aqt/addcards.py", line 225, in afterSave
File "aqt/addcards.py", line 231, in doClose
File "aqt/addcards.py", line 210, in _reject
File "anki/sound.py", line 417, in clearAudioQueue
File "anki/sound.py", line 117, in clearQueue
File "anki/mpv.py", line 558, in command
File "anki/mpv.py", line 352, in _send_request
File "anki/mpv.py", line 311, in _send_message
<class 'anki.mpv.MPVTimeoutError'>: unable to put request
- enable input keys for video seeking
- output debug info to stdout so it's not caught by anki's error handler
- before sending a command, check the process is still alive, and
restart if necessary - otherwise a user who closes a video window will
end up with errors