Repository navigation
refactor(whiteboard): share one board per machine and remove project rooms - #340
Merged
Merged
Conversation
Thread transfer impact✅ Thread transfer remains within every enforced ceiling.
Other scenariosAll 64 scenario measurements match All 64 scenario measurements
Baseline: Scenario and decoded snapshot size10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.
Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed. |
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.
Behavior change: yes. Replaces per-project whiteboard rooms with one shared whiteboard per machine, where users switch between topics manually using tldraw's page menu.
Why:
wbCLI, and T3 Code right-panel iframe manager.<dataDir>/room-main.json) keeps a single loaded board iframe across threads without reloading, while tldraw pages handle separation when needed.Scope and migration boundary (owner-approved):
<dataDir>/room-main.jsonand intentionally does not auto-migrate or auto-merge legacyroom-<slug>.jsonsnapshots (which often include duplicate/scratch rooms). Existing legacy files remain untouched on disk; startup logs a best-effort warning when legacy snapshots are present, andfork/whiteboard/README.mddocuments how to copy a snapshot overroom-main.jsonwhile stopped.POST /api/board/editrejects requests with a?room=query parameter (HTTP 400) and WebSocket upgrades accept only/connect(rejecting legacy/connect/<slug>sockets), so stale room-targeted clients cannot silently mutate or replay queued edits ontoroom-main.json.GET /api/boardcontinues accepting extra query parameters for read-only health-check compatibility.fork/whiteboard/run-t3.shkeeps exportingWB_CHAT_PID=$$intentionally so external scripts running inside an agent session can detect the embedded server process;wb.mjsno longer reads it.What changed:
fork/whiteboard/server/main.ts,web/board.tsx,web/bridge.ts,web/ChatSlot.tsx, andtools/wb.mjs: removed multi-room management,web/room.mjs,wb-projectroom switching, and thewb --room/agentDir/gitroom-resolution paths. The sync server serves the single shared board at/api/board,/api/board/edit, and/connect, logs a best-effort startup warning if legacyroom-*.jsonsnapshots exist, and rejects?room=on writes and/connect/<slug>WebSocket upgrades.apps/web/src/fork/whiteboard/andapps/web/src/fork/dashboard/dashboardSurface.ts: removeduseWhiteboardProject.ts, project-root lookups, and multi-board eviction inboardChannel.tsso all local threads share one/?embed=paneliframe; deleted the 2-lineuseWhiteboardProjecthook from upstreamapps/web/src/components/ChatView.tsx(reducing upstream diff by 2 lines).README.md,fork/whiteboard/{README.md,run-t3.md,run-t3.sh,skills/use-whiteboard/*}, tests (wb.check.mjs,pageMode.check.ts,boardChannel.logic.test.ts,WhiteboardPanel.browser.test.tsx), and.agents/skills/verify-whiteboard/to remove stale project-room parameters and docs.Verification:
fork/whiteboard:npm test(mathsplit, camera, mermaidschema, pageMode, wb including--roomrejection, HTTP 400 onPOST /api/board/edit?room=..., and legacy/connect/<slug>rejection) andnpm run build(tsc --noEmit && vite build) passed.apps/web:vp test run(boardChannel.logic.test.ts,WhiteboardPanel.browser.test.tsx),vp run check:changed(format, lint, knip, 10 test files / 137 tests, react compiler), andvp run typecheckpassed.wb-verify.sh up:wb pages,wb write,wb read,wb shot,wb delete,GET /api/board?room=default, andprobes/board-math.mjspassed.