Anki hit add on error

I removed the anki hub subscription, and now I cannot sync my anki and I can’t even turn off my computer because the anki app will not close. it pops up with the message “Oh no! an Anki-hub add on error has occurred”.

Error message (don't change this)
Anki 24.11 (87ccd24e)  (ao)
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1
Platform: macOS-14.2-arm64-arm-64bit

Traceback (most recent call last):

  File "aqt.taskman", line 144, in _on_closures_pending

  File "aqt.taskman", line 88, in <lambda>

  File "aqt.taskman", line 108, in wrapped_done

  File "aqt.sync", line 127, in on_future_done

  File "decorator", line 232, in fun

  File "anki.hooks", line 92, in decorator_wrapper

  File "anki.hooks", line 89, in repl

  File "/Users/aliceflament/Library/Application Support/Anki2/addons21/1322529746/gui/operations/ankihub_sync.py", line 329, in _upload_if_full_sync_triggered_by_ankihub
    if config.schema_to_do_full_upload_for_once() == collection_schema():

  File "/Users/aliceflament/Library/Application Support/Anki2/addons21/1322529746/main/utils.py", line 704, in collection_schema
    return aqt.mw.col.db.scalar("select scm from col")

AttributeError: 'NoneType' object has no attribute 'scalar'

Sentry link (for developers)

Hello,

Try force-quitting your Anki application then open Anki using safe mode.

To open Anki in safe-mode, hold Shift when clicking on the Anki application, then go to Tools → add-ons → get updates → you should be prompted to update AnkiHub

Then this should fix this issue!