-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] V3 Scheduler: "Invalid input: card was modified" while answering card #12946
Comments
Is it possible you are performing some action via the menus before answering that card? In the past this happened when people did things like suspend a card while reviewing. |
The issue mostly occurs when I click "show answer", then edit the card and then rate the card. But today, I suppose that I didn't perform any action via the menus before answering the card. |
I think this can be confirmed from the error report generated by AnkiDroid. |
The logs don't make this clear. Please keep an eye out for any actions you're taking around the time the problem occurs, as that will help to narrow it down. To devs: I believe this happens because AnkiDroid is performing some operation on the database. The top of the review queue can then change (eg because a learning card has become due), but the reviewer still thinks the previous card is the current one. This will happen when an operation uses raw SQL, or was not invoked with undoableOp. |
This happened again. I rated the card but nothing happened. Then, I rated the card again and I was shown the same error. When I dismissed the error, the next due card was shown. And this time, I am sure that I didn't do anything via the menu. |
If you see the same thing again, it may be worth looking up the card info of the card where nothing happened - I suspect it will show that the card was actually reviewed, and that the UI has failed to indicate it for some reason. Getting to the bottom of this may require adding some extra logging or digging through this part of the code. As some changes to this area will need to be made in #12620, this may need to wait until someone has the time to pick that up. |
Hello 👋, this issue has been opened for more than 3 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically |
I have not seen this error message since a while. But, because this message used to appear on rare occasions, I can't be sure about whether this issue has been resolved or not. |
It's not fixed. To be fixed in 2.17 |
We'll need reproduction steps to track this down. If it still occurs after a 2.17 alpha release, please let us know the steps we should take to trigger this. |
Sometimes I click the rate button and then the UI surface gets stuck. Then I click the rate button again, and I get this error. |
I'm going to move this off the 2.17 release milestone - not because we don't believe it is happening - but because it was already happening in 2.16 and I don't think it is a regression so it should not block a new public release We'll try to fix it as soon as we have solid reproduction steps but we want to make sure all the other fixes we have queued up are released as quickly as possible so we don't want to block the release |
For what it's worth, I've been experiencing those pretty frequently a couple of releases back, but since 2.16 (I think) and 2.17 alpha, I've not experiencing it anymore. So at least some cases were fixed. |
@david-allison indicates:
I think that one is a duplicate so I'm closing it to focus here |
We're getting closer to a repro here I think - user
|
I noticed this usually happens when a card is being reviewed when today is cut off (e.g. at the midnight) during review. Then this carried over card casts the error. |
There are at least 2 causes:
Focusing on answering too quickly, this can be replicated by duplicating the line: Anki-Android/AnkiDroid/src/main/java/com/ichi2/anki/AbstractFlashcardViewer.kt Lines 915 to 934 in 5425cc6
@BrayanDSO is fixing this likely going to get in the way of your refactors in the area? |
Nope. I don't care much to what happens to the AbstractFlashcardViewer/Reviewer/Previewer/CardTemplatePreviewer since I'm doing a re-write to implement #14302 |
I installed AnkiDroid 2.17.5 and I still get this "card modified" error when leaving a card open overnight (unrated) and rate it in the morning. Version data copied from the about page: |
Reproduction Steps
Expected Result
The next card is shown.
Actual Result
Sometimes, the following error is shown instead.
Note that this error occurs very rarely, maybe about once a week.
Debug info
AnkiDroid Version = 2.16alpha91
Android Version = 7.0
Manufacturer = motorola
Model = Moto C Plus
Hardware = mt6735
Webview User Agent = Mozilla/5.0 (Linux; Android 7.0; Moto C Plus Build/NRD90M.03.045; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/107.0.5304.141 Mobile Safari/537.36
ACRA UUID = c6a580cb-02cc-4970-b7a5-24615e6542e1
New schema = true
Scheduler = std3
Crash Reports Enabled = true
DatabaseV2 Enabled = true
Research
Enter an [x] character to confirm the points below:
The text was updated successfully, but these errors were encountered: