Skip to content

fix(core): stop session lock errors from blaming VNC on Android teardown - #342

Merged
ElbertePlinio merged 6 commits into
mainfrom
fix/326-session-lock-wording
Oct 28, 2026
Merged

ElbertePlinio merged 6 commits into
mainfrom
fix/326-session-lock-wording

Conversation

@ElbertePlinio

@ElbertePlinio ElbertePlinio commented Oct 28, 2026 •

Copy link
Copy Markdown
Member

Android-only teardown now uses the session lock too. When a wait for that lock timed out or was cancelled, the error still talked about VNC: "Timed out waiting to ensure VNC for session " and "Cancelled while waiting for the VNC lock of session ". For an Android session that sends people looking at the wrong thing.

Both errors now name the session lock: "Timed out waiting for the lock of session " and "Cancelled while waiting for the lock of session ". The lock itself does not change. The function, constant and lock file names still say VNC, because many callers use them.

Closes #326

Requirement Verified by Scenario Result Evidence
Neutral wording in the timeout error New test A holder keeps the lock while the waiter's clock passes the 90 s deadline "Timed out waiting for the lock of session ". The test failed before the fix. session-lock.test.ts
Neutral wording in the cancel error Tests The signal is already aborted, and an abort during a wait on a viewer session "Cancelled while waiting for the lock of session " session-lock.test.ts, viewer-state.test.ts
Check tests and callers that match the old text Repo search Both old messages across TypeScript, Rust crates, docs and tests Only viewer-state.test.ts matched, and it is updated git grep at 437475b
Lock behavior unchanged Tests Core package suite and viewer state tests 1289 tests pass Local run at 437475b
Repo checks typecheck, lint, PickCheck bun run typecheck, bun run lint, pickcheck check --base origin/main Pass, no PickCheck violations Local run at 437475b

Proof: the new timeout test and the updated cancel test failed on main and pass with this change.

Reviewed with sol-loop: 1 round with gpt-6.1-sol. Sol verdict: approved. Its one nit, a race in the test helper that holds the lock, is fixed in 437475b.

The session lock now also guards Android teardown, so the timeout and cancel errors no longer mention VNC.
@ElbertePlinio
ElbertePlinio force-pushed the fix/326-session-lock-wording branch from ba32ea6 to 437475b Compare October 28, 2026 02:48
@ElbertePlinio
ElbertePlinio merged commit b5db5ce into main Oct 28, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

core: session lock errors mention VNC for Android teardown

1 participant