fonol / anki-search-inside-add-card

An add-on providing full-text-search and PDF reading functionality to Anki's Add card dialog
https://ankiweb.net/shared/info/1781298089
GNU Affero General Public License v3.0
177 stars 24 forks source link

Error Code #286

Open band0024 opened 2 years ago

band0024 commented 2 years ago

Describe the bug Never filled one of these out before but I get and error window on anki 2.1.40. The addon worked great 2 months ago. Haven't downloaded any other addons that would interfere. However, when I close out of the error window, I am still able to use the addon like normal. This only occurs when I go to open SIAC. I didn't see any other's post on the ankiweb about issues so I thought I'd give this a try. Below is the error code

**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 on the add-on support site. Debug info: Anki 2.1.40 (cf446733) Python 3.8.6 Qt 5.14.2 PyQt 5.14.2 Platform: Windows 10 Flags: frz=True ao=True sv=2 Add-ons, last update check: 2021-07-28 11:14:09

Caught exception: Traceback (most recent call last): File "aqt\webview.py", line 515, in handler File "C:\Users\banderson\AppData\Roaming\Anki2\addons21\1781298089\src__init__.py", line 261, in cb UI.fillDeckSelect(editor) File "C:\Users\banderson\AppData\Roaming\Anki2\addons21\1781298089\src\output.py", line 1158, in fillDeckSelect html = iterateMap(dmap, "", True) File "C:\Users\banderson\AppData\Roaming\Anki2\addons21\1781298089\src\output.py", line 1154, in iterateMap iterateMap(value, full, False)) File "C:\Users\banderson\AppData\Roaming\Anki2\addons21\1781298089\src\output.py", line 1154, in iterateMap iterateMap(value, full, False)) File "C:\Users\banderson\AppData\Roaming\Anki2\addons21\1781298089\src\output.py", line 1151, in iterateMap "selected" if str(did) in decks or decks == ["-1"] else "", UnboundLocalError: local variable 'did' referenced before assignment**

fonol commented 2 years ago

Hi, thanks for the report, I'll try to include a fix in the next update.

OcileCollection commented 1 year ago

@band0024 Have you tried the new update? Did it solve the issue?