Anki-android: Editing cards in custom study sub-decks during review from parent incorrectly reassigns cards to the custom deck

Created on 28 Dec 2018  Â·  10Comments  Â·  Source: ankidroid/Anki-Android

Reproduction Steps
  1. Create a normal deck and a custom study deck that takes cards from the normal deck.
  2. Start reviewing the custom study deck and edit one of the cards.
Expected Result

The card stays in the custom deck but will return to the original deck when you empty the custom study deck.

Actual Result

The default deck for the edited card is now permanently changed to the custom study deck. It has to be manually changed back and if you do this during editing, it will disappear from the custom study deck.

Research

Enter an [ x ] character to confirm the points below:

[x] I have read the support page and am reporting a bug or enhancement request specific to AnkiDroid

[x] I have checked the manual and the FAQ and could not find a solution to my issue

[x] I have searched for similar existing issues here and on the user forum - there was a post about this in July 2018 but the issue was closed unexpectedly by the user.

2.8.x Accepted Bug Priority-Low

All 10 comments

Hi there! This is a detailed bug report - thank you for taking the time to log it. It seems like all the information we need to reproduce this in AnkiDroid is present - which is extremely useful - however, I haven't tried this in Anki Desktop, and I know that the v1 scheduler had issues similar to this with custom study and sub-decks.

Have you tried similar actions in Anki Desktop?

I don't doubt this behavior is unexpected, however we try to follow Anki Desktop even where the behavior is unexpected. It would be very useful to know if this happened in Anki Desktop with the v1 scheduler (and still useful to know how the v2 scheduler handled it).

Hi, thanks for responding. Anki Desktop v1 scheduler deals with this correctly (ie: differently to AnkiDroid). To test it, do the same steps as above in Anki Desktop and then empty the custom study deck and you'll see that they all return home. I can't comment on the v2 scheduler because I've never used it.

Thanks for checking that, I appreciate it. I will see what we can do about it...

Hmm. I tried this and was unable to reproduce it on current alpha or 2.8

  1. I tag a card with "testtag"
  2. create a filtered deck with search "tag:testtag"
  3. enter filtered deck and edit the first card (change the text somewhere)
  4. visible in card browser the edit took
  5. long press the filtered deck in deck picker and empty deck
  6. all the cards returned? and you can rebuild and empty and it continues to work?

Can you give me complete steps to reproduce or a video demonstration of this?

Aha, it was more complex than I thought to reproduce. Took me a few days to
work this out.

  1. Create 2 standard decks, A and B. B contains cards, A is a dummy.
  2. Create a custom deck (C) that is a child of deck A (A::C).
  3. Use C to take cards (via a tag etc.) from deck B.
  4. Review A (!) which will include the cards currently in C.
  5. Edit a card while you are reviewing A and save the changes.
  6. When you empty deck C, the edited card will now be stuck in A instead of
    returning to B.

I think that is non standard behaviour and I know the situation is weird.
I've attached a screenshot that might explain why a person would want to do
this strange combination of decks and custom decks. Update: I have now confirmed that Anki Desktop handles this correctly (= differently to Ankidroid).

Hope that helps!

On Fri., 28 Dec. 2018, 23:06 Mike Hardy, notifications@github.com wrote:

Hmm. I tried this and was unable to reproduce it on current alpha or 2.8

  1. I tag a card with "testtag"
  2. create a filtered deck with search "tag:testtag"
  3. enter filtered deck and edit the first card (change the text
    somewhere)
  4. visible in card browser the edit took
  5. long press the filtered deck in deck picker and empty deck
  6. all the cards returned? and you can rebuild and empty and it
    continues to work?

Can you give me complete steps to reproduce or a video demonstration of
this?

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/ankidroid/Anki-Android/issues/5184#issuecomment-450373374,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AsEaVFs1wiXRUOwjjPZV5xk7ecCYT4OGks5u9jOCgaJpZM4Zjax-
.

Fascinating. I wonder if this is true of any cards in sub-decks if you are reviewing them the parent deck. It may be that the filtered deck isn't important and it's the parent::child relationship that's causing the issue?

Thanks for confirming with Anki Desktop

I thought that might be it too, but if it's not a filtered deck and just parent-child, Ankidroid behaves correctly and the deck that appears when you edit is the child, not the parent taht you're reviewing.

Very interesting - this is ace triage work, it should be relatively easy to find this one as you've really narrowed it down. Thanks @rmilt7

Just to beat the dead horse here, I realised today that the deck it gets stuck in is actually the topmost deck in your collection, irrespective of what you're reviewing.

@rmilt7 Good news (I believe): I just pushed a pull request which would correct this bug.
Remains to check whether it'll be accepted, and if so when it'll be in ankidroid

Was this page helpful?
0 / 5 - 0 ratings

Related issues

kanjieater picture kanjieater  Â·  4Comments

sudomain picture sudomain  Â·  3Comments

david-allison-1 picture david-allison-1  Â·  4Comments

OoDeLally picture OoDeLally  Â·  4Comments

mashinbaz1 picture mashinbaz1  Â·  6Comments