Repository navigation
test(wsl): measure lane restarts over one held socket - #35526
Conversation
Each terminal read in the restart measurement opened a fresh connection, which on WSL spawns a new wsl.exe bridge, so first-output time counted bridge spawns the app never pays. Hold one shared control connection per restart, as the app does.
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 14 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
[Low impact] The PR appears safe to merge. SummaryThe WSL restart measurement now sends terminal calls over one held connection.
No actionable issues found. The Windows-only WSL lane was not run during this review.
|
ELI5
The WSL speed test was timing a cost the app never pays. Each time it checked whether the terminal had printed, it opened a brand-new connection, and on WSL every new connection starts a new
wsl.exe. The app opens one connection and keeps it. The test now does the same thing.What Changed
terminal.create,terminal.send, everyterminal.readpoll andterminal.closeeach opened a fresh connection to the host. On WSL, each one started a newwsl.exebridge process. The bridge spawns crowded the cold start and inflated "restart to first output".Why
The owner set a target of 2.5 s median restart to first output, measured with one held socket. The old number mixed host start-up with repeated bridge spawns, so changes to the host's start-up could not be judged against the target. Reusing the app's own connection class keeps the lane measuring what users see, without a separate client that is only used in tests.
Flag-off: no product change; only the WSL lane test (runs with
ORCA_RUN_WSL_ORCAD_LANE=1) changes.User-risk: none; test-only. The lane's restart numbers will drop from earlier receipts, so baselines must be re-read from a run that includes this change.
Linked Issue
N/A (internal performance work).
Visual Proof
N/A: test-only change with no UI.
Testing
pnpm tc,pnpm run typecheck:ci, the changed-code quality gate, anti-slop oxlint and oxlint all pass.The lane is skipped locally (needs a real WSL2 distro); it runs on the WSL lane in CI.
I manually tested these changes locally
Automated tests added/updated, or explained why not below
Review
Agent skill upstream boundary
Notes
Test-only; no security, SSH, mobile or compatibility impact.
Checklist
N/Awith reasonpnpm lint,pnpm typecheck,pnpm test, andpnpm buildpass (or CI will cover; local preferred)