Closed ijgnd closed 4 years ago
Thank you for this exhaustive report. I'm surprised that the second error is new. There is very little I can do, because it's related to the way anki deal with windows. I'm hacking the system which is made for a single window in order to open multiple window. Doing it correctly without error about "Wrapped C/C++" would require to rewrite far too much things.
The first error should be corrected now. I've no idea yet for the last one. It's probably related to the current add-on, but I have no precise idea
Please update and let me know whether it got better: first problem should have disappeared
Thank you so much for this update. I'm not sure how long I would have taken me to figure this out (if ever). Now it mostly works for me. I could produce this error when closing a dialog.
Caught exception:
Traceback (most recent call last):
File "aqt/webview.py", line 464, in handler
File "aqt/editor.py", line 475, in <lambda>
File "aqt/addcards.py", line 248, in afterSave
File "aqt/addcards.py", line 237, in _reject
File "aqt/main.py", line 688, in maybeReset
File "aqt/main.py", line 669, in reset
File "aqt/gui_hooks.py", line 1838, in __call__
File "../Anki2/addons21/424778276/addCards.py", line 64, in onResetSameModel
return self.onReset(model=self.editor.note._model, keep=keep)
AttributeError: 'NoneType' object has no attribute '_model'
At the moment I'm trying out this minimal change to onResetSameModel and so far it seems to work:
from
return self.onReset(model=self.editor.note._model, keep=keep)
to:
model = None
if self.editor.note:
model = self.editor.note._model
return self.onReset(model=model, keep=keep)
btw: for creating the gifs I use peek.
please update. Not perfect, but should be better already
works now for me. Thanks for the quick fix.
Thanks for keeping this add-on alive!
Your most recent update fixes #2 but now I get an error when I try to close an Add window. See the screencast/gif below.
I tried with the packaged version 2.1.25 for linux from apps.ankiweb and your add-ons Opening the same window multiple time and Keep model of add cards that I installed today into a new profile. I've looked into this for about an hour now and still don't have a solution. So I posted this issue.
The full error message is:
Before I made this problem description that documents the steps I took I also ran into these errors when trying to close an add window where I didn't document exactly on how to reproduce them. Maybe these are also useful for you.
and this (this occured after a note type change in the add window):
Once more: Thanks for creating and maintaining these essential add-ons!