glutanimate / review-heatmap

Anki add-on to help you keep track of your review activity
https://ankiweb.net/shared/info/1771074083
Other
1.2k stars 90 forks source link

1.0.0-beta fails on the QT6 beta of Anki #136

Closed ELLIOTTCABLE closed 2 years ago

ELLIOTTCABLE commented 2 years ago

Problem description

Dae's posted a QT6 beta of Anki. Most of my addons work fine, but unfortunately, that doesn't include Review Heatmap.

Checklist

Please replace the space inside the brackets with an x if the following items apply:

Information about your Anki set-up

    Anki 2.1.50 (abd671d4) Python 3.9.7 Qt 6.2.0 PyQt 6.2.0
    Platform: Mac 12.0.1
    Flags: frz=True ao=True sv=3
    Add-ons, last update check: 2021-12-02 08:37:14

    ===Add-ons (active)===
    (add-on provided name [Add-on folder, installed at, version, is config changed])

    ===IDs of active AnkiWeb add-ons===

    ===Add-ons (inactive)===
    (add-on provided name [Add-on folder, installed at, version, is config changed])

Error message (if any)

An add-on you installed failed to load. If problems persist, please go to the Tools>Add-ons menu, and disable or delete the add-on.

When loading '⁨Review Heatmap⁩':
⁨Traceback (most recent call last):
  File "aqt.addons", line 239, in loadAddons
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/__init__.py", line 124, in <module>
    initializeAddon()
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/__init__.py", line 114, in initializeAddon
    from .gui.options import initializeOptions
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/gui/options.py", line 44, in <module>
    from ..libaddon.gui.dialog_options import OptionsDialog
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/dialog_options.py", line 48, in <module>
    from .basic.dialog_mapped import MappedDialog
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/basic/dialog_mapped.py", line 43, in <module>
    from .dialog_basic import BasicDialog
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/basic/dialog_basic.py", line 40, in <module>
    from .interface import CommonWidgetInterface
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/basic/interface.py", line 54, in <module>
    from .widgets.qkeygrabber import QKeyGrabButton
  File "/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/basic/widgets/qkeygrabber.py", line 43, in <module>
    from .qt import QDialog, QPushButton, QVBoxLayout, QLabel, Qt, QKeySequence
ImportError: cannot import name 'QDialog' from 'review_heatmap.libaddon.gui.basic.widgets.qt' (/Users/ec/Library/Application Support/Anki2/addons21/review_heatmap/libaddon/gui/basic/widgets/qt.py)
glutanimate commented 2 years ago

Thanks for the report!

This particular incompatibility should be addressed by https://github.com/ankitects/anki/commit/3868e1e4a6d6a2cd25843e9d8fe0a10930e45621 and https://github.com/ankitects/anki/commit/924fd3944454356d0dc7d00beaf580d598063b7c. Coupled with the earlier work in https://github.com/ankitects/anki/pull/1440 that should eliminate most breakage points due to Qt API changes.

However, there's still work to be done to move the add-on away from Qt's now-deprecated resource system and adjust to some Anki API changes. Working on it as we speak.

grit780 commented 2 years ago

Hi

Is there any way to fix the issue where the addon isn't working with Anki 2.1.5 beta or something I can do so that my heatup shows up?

Thanks

glutanimate commented 2 years ago

Hi @grit780,

Unfortunately not at the moment, but the new release should be ready by the time 2.1.50 hits stable.

grit780 commented 2 years ago

Hi! Just wanted to let you know that the stable release is expected to be out in the next month.

According to the Anki website "Further API changes are unlikely at this point, and a stable release is tentatively penciled in for about a month from today. If you run into any bugs, please let us know, and if you’re an add-on author that would like to support 2.1.50, now would be a good time to make any necessary changes 8"

WritingWithFire commented 2 years ago

Anki 2.1.50 stable version has been released already. So..

glutanimate commented 2 years ago

Hey everyone, happy to say that v1.0.0 is out now on AnkiWeb, finally bringing full support for 2.1.50+ (Qt6 included).

Thanks again for the reports guys and please do let me know if you run into any issues with the new build!