Migaku-Kanji-Addon
Migaku-Kanji-Addon copied to clipboard
[BUG] Error when pressing any key on a keyboard in stats window
Describe the bug When in the Kanji stats window, pressing any key on the keyboard triggers an Error.
To Reproduce Steps to reproduce the behavior:
- Go to 'Kanji' -> 'Stats'
- Press any key on the keyboard, for example, F11.
- See error
Expected behavior When pressed F11, the window is supposed to enter fullscreen mode. When pressed any other key, nothing happens
Desktop (please complete the following information):
- OS and Version: Arch Linux. Linux-6.5.9-arch2-1-x86_64-with-glibc2.38
- Anki Version: Anki 23.10 (51a10f0) Python 3.11.5 Qt 6.6.0 PyQt 6.6.0
Additional context
The problem is, probably, connected to PyQt6 changing API for enums, which are now scoped.
In addon/stats_window.py Qt.Key_F11
becomes Qt.Key.Key_F11
.
Making this change locally on my sistem fixes the issue.
Here is also a commit with similar changes in the anki repo: https://github.com/ankitects/anki/commit/a7812dedc096627692ab3d7e64b90be632f52134
Screenshots