TSA-146: Queue verification actions so a fast Enter burst is never dropped - #466
Merged
Merged
Conversation
RomanNabukhotniidev
previously approved these changes
Sep 25, 2026
Co-authored-by: Nabukhotnii Roman <devvaggh@gmail.com>
RomanNabukhotniidev
approved these changes
Sep 25, 2026
IlliaMatushchak
approved these changes
Sep 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #146
What
Verification actions (Enter / Correct / Skip / Save edit) now go into a per-document queue instead of being dropped while a request is in flight.
processVerificationQueue) sends oneverifyat a time; the next action leaves the queue only after the previous response.rollbackentry) is applied inverifyPage.pending, i.e. when the action leaves the queue — so at most one request is outstanding androllbackholds one entry per document.isVerifyingguard fromhandleVerifyand the disabled state from the Correct / Edit / Skip buttons.Also fixed
verifyPage.fulfilledno longer setscursorPageNofrom the server response — during a burst it would pull the cursor back several pages.loadPages.fulfilledno longer overwrites a page whose request is still in flight (a burst crossing the 5-page batch boundary would wipe its optimistic status).RollbackStatenow also stores the transcription text, so a failed save restores the original text. The ticket notes expected [FE] Editing mode on the verification screen #265 to add this, but [FE] Editing mode on the verification screen #265 was closed (TSA-265: Editing mode on the verification screen #312) without it, and the rollback logic is rewritten in this PR anyway.Behaviour changes
Eto edit again.Ctrl+Zwhile the queue is busy shows "Wait until the queued actions are saved, then undo" instead of being silently ignored.Not in scope
VerificationQueueItemcarriesdocumentId, so actions can be handed off from here later.How to test
verify.verifyrequests, all 200.verifyrequests are sent.E, change the text,Ctrl+Enter, then stop the backend → cursor returns to that page and the original text is shown, not the edited one.