Repository navigation
fix(preview): serialize concurrent profile clears - #831
Merged
Merged
Conversation
Reuse the in-flight profile clear so concurrent callers wait for the same context closure before storage removal. Port the focused upstream repair and regression from b0410a4 (pingdotgg/t3code#23434), retaining shared context-pool ownership and boundary coverage. Co-authored-by: Aditya Garud <153842990+yashranaway@users.noreply.github.com>
This was referenced Nov 5, 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.
Concurrent clears of the same Preview browser profile could delete its storage before the original context finished closing. Reuse the existing clear operation so both callers wait for one context close and storage removal.
Ports the focused upstream repair and original regression from T3 Code #23434. The context lifecycle stays in the existing shared owner; boundary records map the retained regression.
Validation: all 10
ServerBrowserContextstests pass on isolated Linux with Node 26.12.1 and Vite+ 1.4.0; affected server typecheck, changed-file lint/formatting, and strict boundary check pass. The new regression fails on the original implementation for premature deletion. Independent Sol Max review found no issues. No real browser profiles or installed runtime were used.Implementation: GPT-6.1 Sol (high), Codex harness in Jones Code.
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.