Anki-android: Possible bug with new card number indication

Created on 4 Feb 2020  路  20Comments  路  Source: ankidroid/Anki-Android

Im not certain if the following is a bug or not but I noticed that the New Card number amount on two decks shows the value 2 but when clicked to study it says study complete. See attatched screenshot.

AnkiDroid Version = 2.9.2

Android Version = 8.0.0

ACRA UUID = 8c4ae41a-d8ac-41bd-ba77-8ac55aec197c

Screenshot_20200204-120057

Anki Ecosystem Compatibility Bug Help Wanted

All 20 comments

Probably you're using scheduler V2 and the new card limit of your parent deck is already reached. You need to increase the new card limit for the parent deck in order to be able to learn those 2 remaining new cards because the sub decks stick to the limits of the parent deck

Thankyou for letting me know. 馃槂

I just faced the same issue but for me it's not a "feature". I intentionally set parent's new items to "0" (to disable new items) and in AnkiDesktop I see that works well: neither parent nor sub-decks have new items != 0, neither in deck list nor in deck summary screen. In AnkiDroid however I can see new items with new value non-zero, but only in deck list - it's displayed correctly in deck summary.

I'd say it's deck-list display bug.

PRs happily accepted :-)

At first I would like to establish whether it's intended or actual bug :-)

I can confirm that the new card number is displayed differently in Anki Desktop and AnkiDroid when using V2 scheduler and the "new card limit" of the parent deck is set to 0:

AnkiDroid shows 4 new cards:
Screenshot_20200213-202450

Anki Desktop shows 0 new cards:
Anki

The AnkiDroid deck summary shows correctly 0 new cards:
Screenshot_20200213-202502

Actually I never realized the difference in Anki and AnkiDroid because I quite like to see the number of new cards per sub deck, even if the parent deck limit is set to 0 ;-)

But this should be tagged with the Anki Ecosystem label anyway.

thanks for confirming! I tagged it up

I just tested it with stable AnkiDroid 2.9 and the bug doesn't exist there, neither with scheduler v1 nor v2. Another user reported it works for him on 2.9.1 but not on the latest Playstore version. So the bug might be introduced in 2.9.2 (version of the thread starter)

Any commit listed here that is not 'Skipped', until you get to the 2.9.1 release (which is apparently okay) is suspect then https://github.com/ankidroid/Anki-Android/commits/hotfix-2.9.2

There aren't that many thankfully

There is typically an alpha release every few commits, so installing the relevant alpha before / after the commit can finalize locating the issue. Each commit will contain a list of the releases it is in so you can find the ones with or without a specific commit.

For instance this was in the list and might be it (I have not tested) https://github.com/ankidroid/Anki-Android/commit/7235a5bc667a6c9def934d85764cedc6594814b3 and when I expand the version list it appears to be in 2.10alpha10, so 2.10alpha9 won't have it but alpha10 will and can be used as a check

@mikehardy you were almost right ;-) alpha10 doesn't have the bug, but alpha11 has it. That's the culprit.

@Anthropos888 thank you! If we bisected correctly @Arthur-Milchior #5582 contains the only likely commits for this bug

(edited to point to the correct PR 5582, apologies)

We already new that this PR contained an error. And it was corrected in #5607
it does not mean that this PR contains no other error. But I believe that it would be worthwhile to test whether the bug still occur in alpha 17, which incorporated this correction, or not.

I'm going to check again the two commits between alpha 10 and 11 to see whether I find anything of interest here

release 2.9.3 contained the correction as well 馃 (I merged it into the hotfix branch: https://github.com/ankidroid/Anki-Android/commits/hotfix-2.9.3)

Got it. I'll make a PR today

And by "today" I meant: in ten minutes
https://github.com/ankidroid/Anki-Android/pull/5759

I just merged that PR and released 2.10alpha40 - hopefully that does the trick?

If it does I'll merge it in for release on 2.9.4 which is just about to release

Thank you @Arthur-Milchior !

You're welcome. It's the least I can do, cleaning the mess I did

Problem is solved in alpha40, thanks @Arthur-Milchior

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mashinbaz1 picture mashinbaz1  路  6Comments

david-allison-1 picture david-allison-1  路  4Comments

Anthropos888 picture Anthropos888  路  5Comments

snowtimeglass picture snowtimeglass  路  5Comments

hanpingchinese picture hanpingchinese  路  5Comments