Let’s say I am studying a deck. After doing some reviews, I exit the reviewer to go back to the Decks screen. Then, I open another deck, exit the reviewer without doing any reviews and reopen the deck that I was studying earlier.
On doing this, the queue in the original deck seems to be rebuilt. I can say this because if I exit Deck 1 on reaching a new card (but before answering it) and reopen Deck 1 and opening Deck 2, I see a series of reviews cards, not a new card.
The disadvantages of the current behaviour:
Every time the queue is rebuilt, the new cards are pushed behind, causing them to be more concentrated in the later part of the queue. In other words, they are not evenly interspersed with the review cards.
Rebuilding the queue wastes the system resources (although it doesn’t consume a significant amount of resources)
I tried to think of the reasons why rebuilding the queue in this context might be necessary but I couldn’t find any. If there is a reason, I would like to know it.
The reason this is a problem for me:
I don’t do all of my reviews in a single session because
it is too mentally taxing
I usually don’t have such a long block of free time
So, I start multiple sessions in a day and when starting a session, it is easy to accidentally click the adjacent deck on mobile. When this happens, the queue gets rebuilt.
Is queue rebuilding also relevant to how undo works? You undo a review/non-review action and sometimes you’ll see a different learning card than the card saw before, because the learning card got due just before you did the undo.
I assume this happens because new review order is trying to show you some review cards before showing any new cards? This in itself should be problematic behaviour then. I’d assume “Mix with reviews” to mean random.
When you have 100 review cards and 10 new cards, there are 10 times more chances of getting a review card than a new card even when the sorting is random.
When you click on a different deck, a different group of cards are shown, so the queue must be rebuilt. If you want to see all the cards in one session, they need to be nested under a single top-level deck which you click on.
Sorry, I did misunderstand you. But I’m afraid this would add a bunch of extra complexity to the code, and I don’t think it can be justified in this case.
When rebuilding the queue, consider not only the cards that are currently due but also those that have already been studied on the same day.
Suppose there were 165 review cards and 5 new cards at the beginning of the day. In this case, Anki should show a new card roughly after every 33 review cards.
Currently, if the queue is rebuilt (due to any cause) after doing, say, 20 cards, then Anki will start showing new cards roughly after every 29 [= (165 - 20) / 5) review cards. However, the first new card will be shown after 49 (= 20 + 29) review cards.
My idea is that when rebuilding the queue, Anki should consider that the user has already done 20 reviews cards.
So, it would show a new card after every 33 review cards and the first new card will be shown after doing 13 (= 33 - 20) additional cards.
In other words, this will ensure that the rebuilt queue is similar to the original one.
Ok, so your gripe is that the ratio of new cards and reviews is altered after cards have been studied and the queue rebuilt? Consulting the review log may be a reasonable way to mitigate that.