Arthur-Milchior / anki-database-check-explained

Explain why you need to check database and what is done to fix it, in detail
GNU General Public License v3.0
2 stars 2 forks source link

Could it have caused this? https://anki.tenderapp.com/discussions/ankidesktop/39239-due-date-is-due-number-1970-or-2045 #4

Open Arthur-Milchior opened 4 years ago

Arthur-Milchior commented 4 years ago

Could it have caused this? https://anki.tenderapp.com/discussions/ankidesktop/39239-due-date-is-due-number-1970-or-2045

Originally posted by @aleksejrs in https://github.com/Arthur-Milchior/anki-database-check-explained/issues/2#issuecomment-596261936

Arthur-Milchior commented 4 years ago

@aleksejrs If you ask the question, I assume it is because you're using this add-on, right ?

It seems almost impossible to state with 100% certainty that your bug is not related to my add-on. But I don't see any reason to believe it's related to this add-on in particular. If you find a way to reproduce the bug; to ensure that a due date suddenly move to 1970 or 2045, then we could study it. But right now I don't see anything pointing to my add-on. This add-on gives more explanation, but use the same code as anki. It also corrects three more things, none are related to due values.

Depending on whether you know how to code, you should probably create an add-on which warns you when a card's due date either move to the paste or goes after 2030. That may help figure out what create the bug.

By the way, I've 9 cards due after 2030. From the evry first deck I used, with extremely simple question. So I can believe that I just pressed easy each time

aleksejrs commented 4 years ago

The misscheduled cards could have been misscheduled by me using ReMemorize though. When reading about your addon, I noticed "the one with the greatest due date", but kind of missed the "Ties are broken by the one with greatest ease" part, which would mean the duplicate cards would have to have a broken ease (like 0) to be overridden by broken ones.

Arthur-Milchior commented 4 years ago

The sentence you quote deals with a very specific case. When you have two cards C1 and C2 which have the same card type and the same note. I explained to Damien and probably on reddit how to create this bug. But it's rare enough so that Damien decided not to fix it as far as I know. It's hard to do this bug by accident.

Anyway, this change would delete one of the two duplicate card but would not change their due value

aleksejrs commented 4 years ago

I think it's "Emptying filtered deck, keeping cards in learning", but I can't find it here.

aleksejrs commented 4 years ago

Confirmed that it happens with "Emptying filtered deck, keeping cards in learning" and not without.

  1. Anki 2.0.52.

  2. Only that add-on installed.

  3. Have this card (nid:1554206828671):

2020-03-19 @ 11:11  Relearn 2   1440m   200%    6.5s
2020-03-19 @ 09:29  Relearn 2   90m 200%    6.1s
2020-03-19 @ 09:21  Relearn 1   5m  200%    7.7s
2020-03-19 @ 09:16  Review  1   5m  200%    10.4s
2019-10-05 @ 21:34  Review  2   22d 220%    6.3s
2019-09-04 @ 01:48  Review  2   15d 235%    0.9s
2019-08-15 @ 07:41  Review  3   14d 250%    4.7s
2019-08-02 @ 23:29  Resched 0   12d 250%    0.0s

4.

  1. Filter the card into the filtered deck.

  2. Fail the card.

  3. Empty the deck.

Added   2019-08-02
First Review    2019-08-02
Latest Review   2020-03-24
Due 1970-01-01
Ease    180%
Reviews 8
Lapses  2
Date    Type    Rating  Interval    Ease    Time
2020-03-24 @ 21:38  Review  1   10m 180%    3.5s
2020-03-19 @ 11:11  Relearn 2   1440m   200%    6.5s
2020-03-19 @ 09:29  Relearn 2   90m 200%    6.1s
2020-03-19 @ 09:21  Relearn 1   5m  200%    7.7s
2020-03-19 @ 09:16  Review  1   5m  200%    10.4s
2019-10-05 @ 21:34  Review  2   22d 220%    6.3s
2019-09-04 @ 01:48  Review  2   15d 235%    0.9s
2019-08-15 @ 07:41  Review  3   14d 250%    4.7s
2019-08-02 @ 23:29  Resched 0   12d 250%    0.0s

Here is a log (with different steps etc.) that resulted in "2953" showing up in the Browser in place of "1970-01-01"; I am not sure how to reproduce it:

Added   2019-08-02
First Review    2019-08-02
Latest Review   2020-03-24
Due 1970-01-01
Ease    200%
Reviews 8
Lapses  1
Average Time    5.3s
Total Time  48.0s
Note ID 1554206828671
Card ID 1564777746767
Date    Type    Rating  Interval    Ease    Time
2020-03-24 @ 11:07  Relearn 2   1d  200%    6.3s
2020-03-19 @ 11:11  Relearn 2   1440m   200%    6.5s
2020-03-19 @ 09:29  Relearn 2   90m 200%    6.1s
2020-03-19 @ 09:21  Relearn 1   5m  200%    7.7s
2020-03-19 @ 09:16  Review  1   5m  200%    10.4s
2019-10-05 @ 21:34  Review  2   22d 220%    6.3s
2019-09-04 @ 01:48  Review  2   15d 235%    0.9s
2019-08-15 @ 07:41  Review  3   14d 250%    4.7s
2019-08-02 @ 23:29  Resched 0   12d 250%    0.0s

Another card, with "2973":

Added   2019-11-21
First Review    2019-11-28
Latest Review   2020-03-24
Due 1970-01-01
Ease    245%
Reviews 8
Lapses  1
Average Time    4.8s
Total Time  38.0s
Note ID 1574298960569
Card ID 1574298981197
Date    Type    Rating  Interval    Ease    Time
2020-03-24 @ 10:15  Review  4   10d 245%    3.9s
2020-03-20 @ 05:56  Relearn 3   4d  230%    2.9s
2020-03-19 @ 20:30  Relearn 2   90m 230%    3.6s
2020-03-19 @ 20:22  Review  1   5m  230%    4.4s
2020-02-03 @ 16:52  Review  3   1.5mo   250%    3.2s
2019-12-28 @ 13:01  Review  3   1.2mo   250%    3.5s
2019-12-03 @ 20:19  Review  3   13d 250%    13.1s
2019-11-28 @ 00:42
Arthur-Milchior commented 4 years ago

Sorry, I don't give support any more for anki 2.0. I may actually remove this add-on version from ankiweb if necessary. But it's too old a version of anki, it would take too much time to try to follow it

aleksejrs commented 4 years ago

Oh well. Maybe I should try remaking the addons I keep using 2.0 for… 2.1 is slow though.

Arthur-Milchior commented 4 years ago

I know people find 2.1 slow. I'm sorry for you.