Repository navigation
fix: ScanLink worker and request stress failures (0.8.0b1) - #2
Merged
Merged
Conversation
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.
ScanLink could publish completion before the parent stored the PDF, miss the configured scan deadline, or queue malformed requests. The worker now owns terminal state publication and enforces both hard deadlines; public/protocol routes validate JSON, metadata and callbacks before scanning. Consumed PDFs keep metadata until the job TTL so competing downloads consistently yield one result and HTTP 410s.
The standalone browser client negotiates transport before scanning and sends each scan POST once. A lost accepted response returns scan_request_uncertain instead of resubmitting through the other transport. Paired with DjangoLux 1.15.1b2; candidate version is 0.8.0b1 as requested.
Validation: 40 local unit tests (one Windows-only skip), 24 paired JavaScript scenarios, real ScanWorker load with 1,000 HTTP/verified-HTTPS checks, 100 hash-verified PDFs, 50 busy submissions and 40 competing result downloads. Live testbed file-field/PDF editor, Arabic guidance, 30 scan cycles, 20-way contention and lost-response recovery passed. Hardware alone was simulated; native Windows CI gates must pass before release. Docs, changelog and tracker are updated.