ijgnd/anki__BetterSearch

Browser not showing any cards

drmarmalademd opened this issue · 10 comments

Hello,

I am on Anki 2.1.23 on a mac.

With this add-on enabled, my browser is completely blank and does not show any cards (even with empty search fields and lots of trying to play around and find a card). I have isolated the issue to this add-on (I have several others but this is the only one that fixed the problem when I disabled it).

Could you please investigate this? As the browser is completely blank, it isn't throwing any errors - so I do not have any codes for you. Happy to provide anything else you may need, though.

Thanks!

ijgnd commented

Thanks for your report. For me it works in 2.1.22 but I don't have a Mac. So I need more info.

my add-on just inserts the tag or deck name, it doesn't start the search. So if I open a new browser, type in "tag:", then select the tag "random_tag" in my add-on window and press enter to close the window the browser will be empty and in the search field I'll have tag:"random_tag*". Only after pressing Return once more I get results.

I have isolated the issue to this add-on (I have several others but this is the only one that fixed the problem when I disabled it).

Disabling add-ons selectively is very useful. But maybe the problem is not this add-on alone but a bad interaction between this add-on and another one.

Does this problem persist if all other add-ons are disabled and you use just this one add-on?

If the problem disappears: Enable another add-on, restart and try again. Or enable half of the add-ons, restart, and try again. Then repeat until you find the conflict and tell me which add-ons conflict.

Do you have exact steps for me to repeat, maybe a screencast, screenshots?

Also very useful: from the main window click on Help->About. In the window that opens click the "Copy Debug Info" Button and share the copied text.

I have many add-ons, so that is entirely possible. I have gone through and spent a fair amount of time disabling groups of add-ons - but can't identify any other sources of the problem.

I could share a screencast if needed, but it wouldn't be too helpful, I think. The browser just displays no notes at all, no matter how I alter the search field.

This is my debug info:

Anki 2.1.23 (de9543ff) Python 3.8.0 Qt 5.13.1 PyQt 5.14.1
Platform: Mac 10.15.3
Flags: frz=True ao=True sv=2
Add-ons, last update check: 2020-03-28 09:49:36


===Add-ons (active)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
'' ['put_ALL_due_learning_cards_first', 0, 'None', '']
'' ['review_heatmap', 0, 'None', '']
AK - No Tags Pop-up ['show_warning_with_no_tags', 0, 'None', '']
AMBOSS add-on ['0amboss_addon', 2020-02-03T17:28, 'None', '']
Add Hyperlink ['318752047', 2019-10-27T23:17, 'None', '']
Add Table ['1237621971', 2020-03-02T21:37, 'None', '']
Advanced Browser ['874215009', 2020-02-20T17:39, 'None', '']
Anki Killstreaks ['579111794', 2020-03-10T13:20, 'None', '']
Anki Simulator ['anki_simulator', 2020-03-25T17:48, 'None', '']
Batch Editing ['291119185', 2019-09-19T13:04, 'None', '']
Batch Remove Formatting eg bold italics etc ['1734822644', 2018-09-24T11:34, 'None', '']
BetterTags ['bettertags', 2020-01-28T15:30, 'None', '']
Browser Resizer ['1435775540', 2020-02-07T19:39, 'None', mod]
Browser Search Box Quick Insert Tag Deck Notetype ['1052724801', 2020-03-23T19:22, 'None', mod]
Browser TableEditor side-by-side horizontal split ['831846358', 2020-01-15T16:51, 'None', mod]
Clickable Tags v20 Anki 2120 support ['1739176371', 2020-03-13T10:25, 'None', '']
Cloze Overlapper ['cloze_overlapper', 2019-02-01T07:37, 'None', '']
Coronavirus Tracker ['1313091126', 2020-03-18T13:59, 'None', '']
Create Filtered Deck from the Browser ['861263371', 2019-03-01T22:14, 'None', '']
Custom background image and gear icon ['1210908941', 0, 'None', mod]
Customize Keyboard Shortcuts ['24411424', 2020-03-11T01:05, 'None', mod]
Customize Sidebar ['1988760596', 2020-01-16T17:12, 'None', mod]
Deck name in title 21 ['699175524', 2019-06-26T21:57, 'None', '']
Edit Field During Review Cloze ['385888438', 2020-03-20T05:16, 'None', mod]
Extended Card Stats During Review ['1008566916', 2019-03-01T22:14, 'None', '']
Extended Tag AddEdit Dialog ['1135507717', 2020-03-25T18:31, 'None', mod]
External Note Editor for the Browser ['browser_external_note_editor', 2020-03-10T13:42, 'None', '']
Fastbar- with nightmode support ['46611790', 2020-03-20T10:34, 'None', '']
Free Weekend - or Any Other Day ['742185195', 2020-01-24T10:34, 'None', mod]
Frozen Fields ['516643804', 2020-02-29T23:12, 'None', '']
High Yield Tags ['1918380616', 2020-03-10T19:11, 'None', mod]
Highlight Search Results in the Browser ['225180905', 2019-03-02T18:36, 'None', '']
Hint Hotkeys ['1844908621', 2019-02-26T13:58, 'None', '']
HoochieMama Randomize Rev Queue ['1460733408', 2020-02-17T22:14, 'None', '']
HoochiePapa Randomize New Queue ['1173108619', 2020-02-17T22:14, 'None', '']
Image Occlusion Enhanced for Anki 21 alpha ['1374772155', 2019-09-19T13:05, 'None', '']
Image Style Editor ['1593969147', 2020-03-05T23:51, 'None', mod]
ImageResizer ['1214357311', 2019-02-27T20:33, 'None', '']
Improved Quizlet to Anki 21 Importer ['538351043', 2020-02-24T19:00, 'None', '']
Learning Step and Review Interval Retention ['1949865265', 2020-01-11T19:33, 'None', '']
Mini Format Pack ['295889520', 2019-03-01T22:13, 'None', '']
More Decks Stats and Time Left ['1556734708', 2020-01-21T08:23, 'None', mod]
More Overview Stats 21 ['738807903', 2019-02-26T13:51, 'None', mod]
No Distractions Full Screen Clean review interface  TabletTouch support ['1049863218', 2020-03-28T04:00, 'v4.0', mod]
Open Added Today from Reviewer ['861864770', 2019-02-22T14:19, 'None', '']
Opening the same window multiple time ['354407385', 2020-03-09T07:57, 'None', '']
Pop-up Dictionary beta ['153625306', 2019-06-26T21:52, 'None', '']
Progress Bar ['2091361802', 2019-03-02T21:27, 'None', mod]
Progress Graphs and Stats for Learned and Matured Cards ['266436365', 2019-07-31T22:43, 'None', '']
Quick Colour Changing ['2491935955', 2019-03-02T21:26, 'None', mod]
ReMemorize Rescheduler with sibling and logging v130 ['323586997', 2020-02-03T13:57, 'None', mod]
Rebuild All  Empty All for Anki 21 ['1810938259', 2018-07-20T00:40, 'None', '']
Refocus Card when Reviewing 21 ['1642550423', 2019-03-04T13:20, 'None', '']
Resize images in editor ['1103084694', 2020-03-21T04:58, 'None', mod]
Special Fields ['1102281552', 2020-03-24T09:45, 'None', mod]
Speed Focus Mode auto-alert auto-reveal auto-fail/good ['1046608507', 2019-06-02T05:11, 'None', '']
Spelling Police ['1410276506', 2020-03-02T21:13, 'None', mod]
Symbols As You Type ['2040501954', 2020-03-17T23:36, 'None', '']
Symbols ['1461102936', 2019-04-23T09:37, 'None', mod]
TagSelectorV2 ['1022577188', 2018-09-16T23:06, 'None', '']
The KING of Button Add-ons ['374005964', 2020-03-20T10:34, 'None', mod]
True Retention ['613684242', 2019-06-26T21:55, 'None', '']
Visual Feedback for Reviews ['review_feedback', 2020-01-29T14:43, 'None', '']
Web Browser - Search terms Import texts and images automatically ['864545277', 2020-01-19T14:46, 'None', mod]
Zoom 21 ['1846592880', 2020-03-02T21:37, 'None', '']
add-on dialog searchfilter bar ['561945101', 2020-01-21T18:38, 'None', '']
when is next learning card due today due ['563204849', 2019-12-22T23:49, 'None', mod]

===IDs of active AnkiWeb add-ons===
1008566916 1022577188 1046608507 1049863218 1052724801 1102281552 1103084694 1135507717 1173108619 1210908941 1214357311 1237621971 1313091126 1374772155 1410276506 1435775540 1460733408 1461102936 153625306 1556734708 1593969147 1642550423 1734822644 1739176371 1810938259 1844908621 1846592880 1918380616 1949865265 1988760596 2040501954 2091361802 225180905 24411424 2491935955 266436365 291119185 295889520 318752047 323586997 354407385 374005964 385888438 46611790 516643804 538351043 561945101 563204849 579111794 613684242 699175524 738807903 742185195 831846358 861263371 861864770 864545277 874215009

===Add-ons (inactive)===
(add-on provided name [Add-on folder, installed at, version, is config changed])
'' ['popup_dictionary', 0, 'None', mod]
'' ['zoom', 0, 'None', '']
Additional Card Fields Fork for 21 ['744725736', 2020-02-17T14:42, 'None', mod]
Answer Button Sounds ['679615590', 2020-02-20T10:10, 'None', '']
Blitzkrieg II - Advanced Browser Sidebar BETA7 ['564851917', 2020-02-25T13:57, 'None', '']
Browser Card Info Bar ['2140680811', 2020-02-19T09:19, 'None', mod]
Button Colours Good Again ['2494384865', 2020-02-09T07:18, 'None', mod]
Card Info During Review ['2179254157', 2019-12-17T03:31, 'None', '']
Clickable Tags v11 ['380714095', 2020-03-22T09:56, 'None', '']
Convert Subdecks to Tag Hierarchy ['1172858842', 2020-02-23T17:03, 'None', '']
Dancing Baloney Allows changing wallpapers with live preview ['378638814', 2020-03-27T01:28, 'None', '']
Echelon - Improved Hierarchical Tags for Anki 21 - Unsupported ['829533913', 2020-03-02T21:37, 'None', '']
Enhance main window ['877182321', 2020-02-15T21:51, 'None', mod]
Fastbar another toolbar for Anki 21 beta ['1955978390', 2019-09-03T22:10, 'None', '']
Full Screen Toggle ['1612375712', 2020-02-23T22:46, 'None', '']
Hierarchical Tags 2  Anki 2117 support ['594329229', 2020-01-29T10:05, 'None', '']
Load Balanced Scheduler ['208879074', 2019-07-23T22:37, 'None', '']
Maximum image height and width in card editor ['229181581', 2020-02-20T03:10, 'None', mod]
Night Mode ['1496166067', 2019-06-26T21:54, 'None', '']
Pokemanki ['633922407', 2020-03-03T22:10, 'None', '']
Puppy Reinforcement ['puppy_reinforcement', 2020-02-05T02:16, 'None', '']
Redesign ['1914733489', 2020-02-29T17:46, 'None', '']
Remaining time for Anki 21 ['1508357010', 2020-03-28T08:43, 'None', '']
Reset Ease ['947935257', 2019-11-14T18:58, 'None', '']
Spell Checker ['spell_checker', 0, 'None', '']
Syllabus - Anki Statistics and Export by Tag and Deck ['668156440', 2020-01-19T14:52, 'None', mod]
load balancer ['1417170896', 2020-02-17T15:02, 'None', '']
porting_clickable_tags ['porting_clickable_tags', 0, 'None', '']
ijgnd commented

I can't reproduce the problem on my computer with Anki 2.1.22. I can't test 2.1.23 because I don't have a Mac.

Maybe someone with a Mac might help. But you should narrow down the list of add-ons. Few people are willing to download 58 add-ons and look for conflicts. No one cares as much as you about your problem.

If you have many add-ons already disabled disabling all other ones and remembering which ones you need to re-enable later is time-consuming.

Personally I would exit Anki. Then I would rename the addons21 folder (e.g. to addons21-temp disabled). Then I would restart Anki. Anki will create a new and empty addons21 folder. Then I would install my add-on. Then I would restart Anki and check if I can reproduce the problem. If not install the rest of the 58 add-ons [see below] and then narrow down to find the conflict.

How to find your addons21 folder: https://docs.ankiweb.net/#/files?id=file-locations

How to install all your addons: Just copy the numbers from your first answer that are under "IDs of active AnkiWeb add-ons"

I’ll do some digging. Thanks for looking into it.

I'm having a similar issue, but instead, I'm getting this error whenever I click on any of my decks / tags or attempt a search in the browser: anki "Invalid search - please check for typing mistakes". I had to disable 3 addons to fix this issue. The 3 addons were bettertags, advanced browser and Browser: Table/Editor side-by-side (horizontal split). Enabling any one of these addons will cause the same issue (ie: if I re-enable only bettertags, I still get the same issue). This happened suddenly (I can't think of what might have caused it). I'm currently running anki 2.1.26 on windows.

Edit: I just solved the issue by force syncing my collection from my ankidroid. I still have no idea why this happened. The only thing I can think of is that I changed one of my cards note type from basic to cloze.

Same issue for me, and started happening randomly without a clear precipitant. I've been using BetterSearch for a long time, but today suddenly my browser will not display any cards no matter what is in the search field (completely empty, deck:current, etc.). Disabling BetterSearch fixes the problem. I'm not sure what changed that is now causing this problem. It's really a bummer because I rely on BetterSearch and use it multiple times a day, but my only solution for now is to disable it.

ijgnd commented

@ardent246: Thanks for reporting this. I assume your problem still persists.

So far I could never reproduce the problem. So I have no idea where to look for a solution. I need your help. Could you share the following info and/or try this:

  • What's your Anki version? If it's not 2.1.30 maybe update and try again?
  • Could you disable all other add-ons, restart Anki and try again?
  • Could you reset the config of BetterSearch to the defaults (it's in the lower left corner of config dialog for my add-on). Make sure that "-Modify Search Bar" is set to false and "-Add Button to the Browser Search Bar" is set to false. Then restart Anki. Does the problem persist?
  • What OS do you use? Just share the info from the main window->Help->About. In the window that opens click the "Copy Debug Info" Button and share the copied text.
  • Can you run from the main window "Check database" and "Check empty cards" and then restart Anki and try again?

You write "today suddenly my browser will not display any cards". It rarely happens that a bug occurs without any changes in the underlying system. Probably something has changed. The problem is we don't know what. Probably something non-obvious or under the hood. Maybe Anki now updates add-ons daily. Do you remember if you got an add-on update shortly before the problem started? Do you remember if you did anything non-obvious?

ijgnd commented

@ardent246: Another idea if you don't mind doing some technical stuff. You could modify one line in the source code of my add-on and tell me if this changes anything. If this makes the browser list appear again I have a better idea where to look.

Change this line in the file __init__.py in my add-on folder with a text editor from

Browser.onBrowserSearchEditTextChange = onBrowserSearchEditTextChange

to

# Browser.onBrowserSearchEditTextChange = onBrowserSearchEditTextChange

How to find your addons21 folder: https://docs.ankiweb.net/#/files?id=file-locations

Then restart Anki. Adding a # deactivates the line. This disables the detection of typed key words like tag: or deck. Instead you have to use custom shortcuts to open the filter dialog. This modification is not meant as a permanent solution but just for diagnostics.

ijgnd commented

@ardent246, @drmarmalademd, @bananas121: When you have the problem that with BetterSearch the browser will not display any cards make a screencast and share it here. Ideally show some searches you do, and go to main window->Help->About. In the window that opens click the "Copy Debug Info" Button and paste the text e.g. into a field in an add window so that I see it.

Maybe there's some solution that's obvious when I see it or I'll have an idea. Not likely, but possible. I know that that's work but you might help many other people who also have the problem (but don't make it to github).

Here's an example of how such a screencast could look like. I first show the add-on window and the debug info in an add window, then I reproduce the problem. The screencast is taken from a bug report I made here which the other add-on creator found useful.

ijgnd commented

too old, no feedback