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
179 stars 24 forks source link

Error on Opening in Linux #216

Closed sasank89 closed 3 years ago

sasank89 commented 3 years ago

Hi, There is a bug while opening Anki with the latest SIAC add-on update. I have copied the debug info below.

Debug info:

Anki 2.1.35 (84dcaa86) Python 3.9.1 Qt 5.15.2 PyQt 5.15.2
Platform: Linux
Flags: frz=False ao=True sv=2
Add-ons, last update check: 2021-02-17 09:32:31
Add-ons possibly involved: ⁨Searching PDF Reading  Note-Taking in Add Dialog⁩

Caught exception:
Traceback (most recent call last):
  File "/usr/lib/python3.9/site-packages/aqt/progress.py", line 53, in handler
    func()
  File "/usr/lib/python3.9/site-packages/aqt/main.py", line 142, in on_window_init
    fn()
  File "/usr/lib/python3.9/site-packages/aqt/main.py", line 231, in setupProfile
    self.loadProfile()
  File "/usr/lib/python3.9/site-packages/aqt/main.py", line 427, in loadProfile
    gui_hooks.profile_did_open()
  File "/usr/lib/python3.9/site-packages/aqt/gui_hooks.py", line 2027, in __call__
    hook()
  File "/home/sasank/.local/share/Anki2/addons21/1781298089/src/index/indexing.py", line 57, in build_index
    anki_index_data        = get_notes_in_collection()
  File "/home/sasank/.local/share/Anki2/addons21/1781298089/src/index/indexing_data.py", line 28, in get_notes_in_collection
    oList           = mw.col.db.all("select notes.id, flds, tags, did, mid from notes left join cards on notes.id = cards.nid where did in %s group by notes.id" %(deckStr))
NameError: name 'deckStr' is not defined

Thank you!

fonol commented 3 years ago

Thanks for the report, a fixed version is up on Ankiweb.

sasank89 commented 3 years ago

Thank you!