m-rtin / anki-ipa

Anki add-on to insert IPA transcriptions
https://ankiweb.net/shared/info/799647424
GNU Affero General Public License v3.0
19 stars 12 forks source link

Type object 'Qt' has no attribute 'Horizontal' #69

Open Philomaelum opened 8 months ago

Philomaelum commented 8 months ago

HI, Thank you very much for your work. When I clic on Edit - Add IPA an error Occur :

Error An error occurred. Please start Anki while holding down the shift key, which will temporarily disable the add-ons you have installed. If the issue only occurs when add-ons are enabled, please use the Tools>Add-ons menu item to disable some add-ons and restart Anki, repeat until you discover the add-on that is causing the problem. When you've discovered the add-on that is causing the problem, please report the issue on the add-ons section of our support site. Debug info: Anki 23.10 (51a10f09) Python 3.9.15 Qt 6.5.3 PyQt 6.5.3 Platform: macOS-14.1.1-arm64-arm-64bit Flags: frz=True ao=True sv=3 Add-ons, last update check: 2023-12-31 13:31:02 Add-ons possibly involved: ⁨Anki IPA⁩

Caught exception: Traceback (most recent call last): File "/Users/USER/Library/Application Support/Anki2/addons21/799647424/batchadding.py", line 251, in a.triggered.connect(lambda , b=browser: on_batch_edit(b)) File "/Users/USER/Library/Application Support/Anki2/addons21/799647424/batch_adding.py", line 237, in on_batch_edit dialog = AddIpaTranscriptDialog(browser, selected_notes) File "/Users/USER/Library/Application Support/Anki2/addons21/799647424/batch_adding.py", line 37, in init self._setup_buttons() File "/Users/USER/Library/Application Support/Anki2/addons21/799647424/batch_adding.py", line 83, in _setup_buttons button_box = qt.QDialogButtonBox(qt.Qt.Horizontal, self) AttributeError: type object 'Qt' has no attribute 'Horizontal'

Thank you.

daniesteban commented 8 months ago

Same problem in Linux using the last version of Anki.

Anki 23.12.1 (1a1d4d54) (ao) Python 3.9.15 Qt 6.6.1 PyQt 6.6.1 Platform: Linux-6.5.0-5-amd64-x86_64-with-glibc2.37

Traceback (most recent call last): File "/home/dani/.local/share/Anki2/addons21/799647424/batchadding.py", line 251, in a.triggered.connect(lambda , b=browser: on_batch_edit(b)) File "/home/dani/.local/share/Anki2/addons21/799647424/batch_adding.py", line 237, in on_batch_edit dialog = AddIpaTranscriptDialog(browser, selected_notes) File "/home/dani/.local/share/Anki2/addons21/799647424/batch_adding.py", line 37, in init self._setup_buttons() File "/home/dani/.local/share/Anki2/addons21/799647424/batch_adding.py", line 83, in _setup_buttons button_box = qt.QDialogButtonBox(qt.Qt.Horizontal, self) AttributeError: type object 'Qt' has no attribute 'Horizontal'

It doesn't happen if you add the IPA one by one using the shortcut

Maybe related with Qt6 version.