Repository navigation
test: live CDP download guid coverage and unroute interception deadlock fix - #643
Merged
Merged
Conversation
A Page.enable'd CDPSession plus a real download is what used to kill the driver connection; keep a browser-level regression next to the unit tests. Co-authored-by: Max Schmitt <max@schmitt.mx>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Test Results SummaryThis comment shows the latest test results for this pull request.
|
TestContextUnrouteCallShouldStopContextRouteFromHAR hung on WebKit macOS because onRoute held the context lock while waiting for setNetworkInterceptionPatterns. Dispatch then blocked in page.onClose on the same lock, so neither the interception reply nor context.Close could complete. Release the lock before the round-trip, and do the same in Route and Unroute so wait-for-handlers cannot pin the mutex either. Co-authored-by: Max Schmitt <max@schmitt.mx>
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.
Follow-up to #642 plus a deadlock that showed up on this PR’s WebKit macOS oldstable job.
Live CDP download coverage
Adds
TestCDPSessionDownloadDoesNotCloseConnection:NewCDPSession→Page.enable→Page.setDownloadBehavior→ an attachment download. Chrome’sPage.downloadWillBeginpayload carries a downloadguidthat is not a Playwright channel; the test asserts that event arrives intact andbrowser.NewContext()still works afterwards.Route mutex deadlock
CI failure in webkit / macos-latest / go oldstable was not that CDP test (it passed in 0.32s).
TestContextUnrouteCallShouldStopContextRouteFromHARhung 12m48s:onRouteheld the context mutex while waiting forsetNetworkInterceptionPatternspage.onCloseon the same mutexcontext.Close()from test cleanup never got its replyThe client now snapshots/mutates the route list under the lock, then releases it before the protocol round-trip. Same change on page and context
Route/Unrouteso wait-for-handlers cannot pin the mutex either.