Thousands of unexpected reviews logged all of a sudden

I’ve been using Anki regularly for a few years, and recently encountered an issue that I believe may be a bug. For some reason, last Thursday, over 2,500 reviews were logged in my app, despite my usual review count being around 100–150 cards per day. The reviews appear to have occurred on “Learning” cards at around 07:00 AM.

(I subtly edited some of the images so the popups don’t hide other possibly important info)

I’ve attached screenshots from my statistics tab to help visualize the issue. I’ve also tried to identify any problems by searching for “Learning” cards from that specific day within my browser, but only five cards with two normal reviews each appeared. I used the following query to search:

deck:current (-is:review is:learn) prop:rated=-5

Despite attempts to fix the issue, such as updating my Anki desktop app, running a Database Check and using the “Forget Cards” shortcut (CTRL+ALT+N), nothing has resolved the discrepancy. I also tried deleting the card history from those suspicious flashcards with this add-on [2089200096] but that didn’t work either.

I would like to hear if anyone else has encountered this issue or has suggestions on how to fix it. The issue doesn’t seem to interfere with my routine, but I’d like to fix the activity log, perhaps for just aesthetic reasons, and resume accurate tracking of my reviews.

I’m also considering rolling back from my automatic backups to a point before the bug appeared and resuming my reviews from there, but I’m open to any advice.

Here are the details of my system from the day the bug occurred (I have now updated my desktop app):

  • Anki Version: v23.12.1 (Windows 11 23H2)
  • AnkiDroid Version: 2.20 (Android 12)
  • Add-ons: None active

I posted this same issue on reddit yesterday in case anyone finds useful information there (sorry, I’m not allowed to include links in my posts).

If this requires navigating into the database file to fix the error manually, I have SQL knowledge and could install DB-sqlite in case I can simply correct a mispaired field.

I will be keeping an eye on this thread to respond promptly to all your suggestions and replies, and thank you all in advance.

EDIT: some format and typos.

1 Like

Just install Anki v24.11 from https://apps.ankiweb.net/ and the issue would disappear.

AnkiDroid 2.20 has a new type of entry (for FSRS rescheduling) that Anki <24.11 doesn’t recognize. So, it just assumes that they are learning cards.

Edit:

(I have now updated my desktop app)

I didn’t read this, sorry. Are you sure that you are on Anki 24.11 now? If yes, probably Anki 23.12.1 modified those entries permanently. Do the stats look correct on AnkiDroid? If yes, you can force a one-way sync from AnkiDroid to correct the issue.

Edit 2:

running a Database Check

Did you run this on Anki 23.12.1 or on Anki 24.11? I am guessing that running Database check on Anki 23.12.1 can modify the revlog entries incorrectly changing the value of the type column from 5 to 1.

1 Like

If AnkiDroid collection, backups, etc. don’t work, your SQL knowledge can help. After updating all your Anki clients, you would need to change the value of type column in the affected entries of the revlog table from 1 to 5.

Hi, thanks for your reply.

I am currently using Anki 24.11 (87ccd24e) with Python 3.9.18 Qt 6.6.2 PyQt 6.6.1 as seen in Help > About menu.

I have already performed a database check on both desktop and mobile versions, with no visible change. Unfortunately, on Ankidroid the stats are the same (i.e. incorrect), although I don’t know the exact moment, so I assume you are right and the change became permanent due to my desktop client being outdated.

Unfortunately I don’t check my statistics section very often.

I’ll take a look at this later, if I find a solution I’ll share the query with you so others can benefit if they find themselves in a similar situation.

I wanted to let you know that I followed your suggestion and I’ve found the involved reviews using DB Browser for SQLite 3.13.1.

I feel confident that I found the right cells, and can say so because they were all done in immediate succession, with only a microsecond between each review (as seen from the selected cells in blue), there are 2,595 in total (bottom left corner), and because they have 0 duration each (red box on the right).

Also, using an Epoch to human-readable date converter tool I confirmed that its timestamp seems to match the date in question.

However, the reviews value is 0 in the type column (and not 1 as you pointed out). In your opinion, is it reasonable to change those values ​​to 5 and see what happens?

From what I could see in this commit and in the Anki source ReviewKind enum 0 is precisely equivalent to a card in the LEARNING phase, which coincides with what is shown in my first screenshots.

I have updated all my devices and I don’t want any more conflicts between versions.

I would obviously do a backup with my app closed before pushing any changes, I just don’t want to mess things up any further before making a bulk change.

EDIT: added a proper image description.

I got too confident and couldn’t wait anymore, so I replaced every 0 to 5 in the selected cells (within the type column), then writed the changes in my collection.anki2 database, restarted the application and it worked perfectly.

I just had to force sync in one direction from Anki so my Ankidroid devices could recognize the changes.

I really appreciate your guidance @vaibhav. I don’t know if I can give you karma or if I should do something with this thread now that my problem has been solved.

Tyvm!

Oops sorry, I was misremembering. The value was indeed supposed to be 0 rather than 1.

Original Reddit post - Reddit - Dive into anything