Repository navigation
fix: end a stopped execute's pending navigation so later executes don't hang - #239
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.
when an execute was stopped (caller disconnect, timeout, toolbar stop) while
page.gotowaited on a server that hadn't answered, chromium keptPage.navigatein flight on the tab and queued every renderer-bound command behind it. the next execute's connectOverCDP timed out after 15s, the stop path's own commands hit the 60s extension timeout, and only closing the tab recovered.the fix:
Page.stopLoadingto the session's tabs (handled browser-side, so it answers while the navigation is pending) before closing the script's browser connection (cli/src/relay.ts onStoppingExecute hook, cli/src/session-manager.ts endStoppedScript).--timeout-ms(cli/src/session-manager/execution.ts).return 1works fast).verified end to end with headless chromium: before, the next execute after a killed caller never answered (gave up at 45s); after, ~110ms.
fixes #238