Move all hand-synced cross-app wire contracts into one built workspace package, @boocode/contracts, consumed by server/web/coder/coder-web via workspace:* + a per-subpath exports map. The ws-frames and provider-config Zod schemas are schema-first (z.infer); MessageMetadata, ErrorReason, AgentSessionConfig, the provider snapshot types, and WorktreeRiskReport are each single-sourced. Deletes the byte-identical copies and their parity tests, fixes a live AgentSessionConfig drift (coder dead copy removed, unified to the web required/nullable shape), removes the dead pending_change WS arms in the fallback SPA, and inverts the build order (contracts builds first) across root build, Dockerfile, and the coder deploy docs. Reverses the shared-package decision declined in v2.5.12. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
3.7 KiB
3.7 KiB
Stale / deprecated inventory
Review list for Sam — do not delete blindly. Items marked "candidate remove" have no known runtime imports; items marked "deprecated" are still referenced or documented.
Last updated: 2026-05-26 (stale cleanup batch)
Resolved in stale cleanup (2026-05-26)
| Item | Resolution |
|---|---|
ProviderPicker.tsx |
Removed — replaced by AgentComposerBar |
SkillSlashCommand.tsx |
Removed — inlined SlashCommandPicker in ChatInput |
Provider type + api.coder.providers() |
Removed |
GET /api/providers (flat list) |
Removed — snapshot is canonical |
ssh.ts + worktree SSH |
Removed — worktrees.ts uses local host-exec.ts |
ProviderCommand vs AgentCommand |
Consolidated — AgentCommand in provider-types.ts |
pty-dispatch AgentCommand |
Renamed — PtySpawnSpec / buildPtySpawnSpec |
ProviderSnapshotStatus: 'unavailable' |
Dropped — only 'ready' | 'error' |
| Skill invoke duplication | Extracted — @boocode/server/skill-invoke |
resolveChatId duplication |
Extracted — apps/coder/src/routes/chat-resolve.ts |
| Qwen settings parse | Shared — qwen-settings.ts with readFile |
| ChatInput slash regex | Shared — lib/slash-command.ts |
Frontend (apps/web)
No open stale items from the 2026-05-26 review.
BooCoder backend (apps/coder)
| Item | Status | Notes |
|---|---|---|
apps/coder/web/ |
Fallback SPA | Standalone BooCoder UI at :9502. Primary UI is CoderPane in BooChat SPA. Keep unless host-only access is dropped. |
Large files (refactor when touched, not delete)
| File | ~Lines | Split suggestion |
|---|---|---|
CoderPane.tsx |
660+ | Extract useCoderMessages, pending changes hook, composer footer |
ChatInput.tsx |
670+ | Extract slash/mention hooks |
dispatcher.ts |
480+ | Split native vs external paths |
AgentComposerBar.tsx |
320+ | Optional: prefs vs picker UI |
acp-dispatch.ts |
300+ | Stream setup now in acp-stream.ts; session lifecycle could split further |
Docs / plans superseded by v2.2
| Item | Notes |
|---|---|
docs/superpowers/plans/2026-05-25-provider-picker-backend.md |
Pre-v2.2 flat /api/providers plan; header marks superseded. |
Roadmap / CHANGELOG mentions of ProviderPicker |
Historical truth for v2.1.0 — leave as release record. |
Already cleaned in simplify pass (2026-05-26)
- Extracted
acp-stream.ts(shared ACP NDJSON bridge) - Deduped
mergeCommands→provider-commands.ts - Parallel ACP probes + singleflight in
provider-snapshot.ts - Removed dead
getPendingSessionIdfrompermission-waiter.ts - CoderPane: WS message dedup, slash helpers, poll only when WS disconnected
Skipped (needs product decision)
- Task cancel → abort external ACP/PTY child —
AbortControllerin dispatcher not wired to cancel route - Skip ACP cold probe when DB models fresh — perf; changes snapshot semantics
Unified— shipped aspackages/typesfor provider snapshot JSON@boocode/contracts(packages/contracts/); all duplicated contracts are now single-sourced there