Fix cancellation, auth cleanup and Activity recovery after merge - #670
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.
What changes
This third sweep fixes ten failures found after #659 merged. Already-cancelled deadline operations no longer dispatch work, null abort reasons survive the Promise boundary, and malformed executor replies return structured failures. OAuth callbacks and credential tests close their scopes after final use. Credential routes own one bounded teardown, including decorated remote connectors and copied contexts, while standalone remote credential tests retain their cleanup behavior.
OAuth handoffs claim ownership atomically on CAS-capable storage. Activity loading shows a retryable error for unreadable pages and discards superseded pagination. Memory and D1 storage reject invalid expiry values before mutation, and D1 lists match embedded NUL bytes literally.
Verification
npm run release:checkpassed on894fd4911460b97a22035ab25a996e366b5a1b51: 5,056 tests, 56 existing skips, 57 Chromium tests, all static/type/build/declaration/bundle/example checks, zero production dependency vulnerabilities, and package smoke with a real Docker deployment. The tarball contains 189 files.The independent CLI tester could not launch Chromium under the macOS sandbox; the parent ran all 57 browser cases. Its shared dependency symlink also changed only esbuild path comments; generated output matches after path normalization, and the canonical checkout's generation check passed.
Scope and limits
Atomic handoff ownership requires compareAndSet. Storage without CAS retains existing consistency limits; built-in OAuth generates random 256-bit state. Public Promise APIs, the eight MCP tools, and dependency versions keep their contracts.
Fixes #660
Fixes #661
Fixes #662
Fixes #663
Fixes #664
Fixes #665
Fixes #666
Fixes #667
Fixes #668
Fixes #669