feat(dashboard): cancel CLI annotate on client disconnect#40347
Conversation
Migrate BrowserTracker to the mirrored BrowserContext lifecycle events. When the last `--annotate` client socket closes, the server emits `cancelAnnotate` so the dashboard disengages annotate mode and future submissions fall back to saving as a download. Remove the superseded `pick` CLI command in favor of the `show --annotate` workflow.
Fixes a race in 'should switch screencast to -s session on show --annotate' where dashboard.evaluate() in sampleCenter() could be interrupted by the in-flight navigation triggered by innerOpenDashboardApp's page.goto. Awaiting #display visibility serializes against that navigation.
Test results for "MCP"7 failed 6555 passed, 913 skipped Merge workflow run. |
Test results for "tests 1"8 flaky41304 passed, 847 skipped Merge workflow run. |
(#40344 with test fix)