gregorias / anki-code-highlighter

Anki plugin for code syntax highlighting.
GNU Affero General Public License v3.0
54 stars 3 forks source link

Anki error on startup with Anki theme #69

Closed algopenne closed 7 months ago

algopenne commented 7 months ago

Bug description Error on startup, sometimes crashes on startup

Reproduction steps

  1. Start Anki with notetype 'Anki themes: Simple (2.1.0)'

Expected behavior Anki to startup

Screenshots If applicable, add screenshots to help explain your problem. You may mesh screenshots with reproduction steps instead of providing them in this separate section.

Card template

https://github.com/badlydrawnrob/anki

Additional information

Additional context Although this theme may be outdated, probably not expected behavior for the add-on should throw an error just due to its existence

algopenne commented 7 months ago

Also would spam this error infinitely in windows when closing Anki sometimes as well. Once I removed the offending themes, it seems that Anki is normal again

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, repeating 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 to the add-on author.
Debug info:
Anki 23.10 (51a10f09) Python 3.9.15 Qt 6.5.3 PyQt 6.5.3
Platform: Windows-10-10.0.19045
Flags: frz=True ao=True sv=?
Add-ons, last update check: 2023-11-07 06:33:36

Caught exception:
Traceback (most recent call last):
  File "aqt.taskman", line 138, in _on_closures_pending
  File "aqt.taskman", line 82, in <lambda>
  File "aqt.taskman", line 102, in wrapped_done
  File "aqt.sync", line 119, in on_future_done
  File "aqt.main", line 1053, in on_collection_sync_finished
  File "aqt.main", line 1061, in <lambda>
  File "aqt.main", line 653, in after_sync
  File "aqt.mediasync", line 110, in show_diag_until_finished
  File "aqt.main", line 650, in after_media_sync
  File "aqt.main", line 528, in callback
  File "aqt.main", line 545, in _unloadProfile
AttributeError: 'AnkiQt' object has no attribute '_reviewer_refresh_timer'
gregorias commented 7 months ago

I can't reproduce this issue after multiple attempts nor do I see anything relevant to the plugin in the attached stacktrace. Closing.

To reopen, provide more reliable reproduction instructions or information on how this plugin is misbehaving.