tandem-editor 0.9.0 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +36 -8
- package/README.md +43 -41
- package/dist/channel/index.js +197 -105
- package/dist/channel/index.js.map +1 -1
- package/dist/cli/index.js +206 -106
- package/dist/cli/index.js.map +1 -1
- package/dist/client/assets/{CoworkSettings-C9Dd4D9z.js → CoworkSettings-BlGNryD3.js} +1 -1
- package/dist/client/assets/index-Bnc4LNBi.css +1 -0
- package/dist/client/assets/{index-CN_6DqdC.js → index-D0gSEOxm.js} +51 -51
- package/dist/client/index.html +2 -2
- package/dist/monitor/index.js +3 -3
- package/dist/monitor/index.js.map +1 -1
- package/dist/server/index.js +386 -127
- package/dist/server/index.js.map +1 -1
- package/package.json +2 -2
- package/sample/table-test.md +8 -0
- package/skills/tandem/SKILL.md +7 -7
- package/dist/client/assets/index-Bz3WFCWw.css +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,24 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## \[Unreleased]
|
|
9
9
|
|
|
10
|
+
## \[0.9.1] - 2026-05-01
|
|
11
|
+
|
|
12
|
+
Hotfix patch bundling ADR-027 surface cleanup and file-I/O correctness fixes before the v0.10.0 Svelte conversion. All changes are patch-class; no MCP API changes.
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- **Imported Word reviewer comments now surface to Claude by default (#482)** — `.docx` reviewer comments are imported as `author: "import"`, `type: "comment"` (was `type: "note"` in the unreleased PR #474 plan). Reverts the `tandem_getAnnotations` `includeImports` opt-in introduced in PR #474 — Claude can read imported comments alongside its own without an explicit flag, which matches the .docx review workflow. The opt-in plumbing (`includeImports` parameter, `importsExcluded` response field) is removed. Existing on-disk records with `author: "import", type: "note"` migrate transparently on read via `sanitizeAnnotation`; on next import the durable record is rewritten in place. Safe because PR #474 was never tagged in a release.
|
|
17
|
+
- **Markdown tables preserved across Tiptap round-trip (#379)** — bidirectional MDAST↔Y.Doc table conversion added to `mdast-ydoc.ts`. Tables with mixed column alignment, inline marks in cells, and empty cells all survive load/save cycles. Flat-offset alignment preserved so annotations anchored after a table resolve correctly.
|
|
18
|
+
- **HTML blocks and insertion-order fixed in mdast-ydoc (#496)** — raw HTML blocks (`<div>`, `<details>`, etc.) now round-trip as `html` nodes instead of being dropped. Insertion-order bug in `blockToYxml` fixed — the two-pass Y.XmlText attach-before-populate pattern now applied uniformly to all block types.
|
|
19
|
+
- **Channel shim per-request timeouts (#364)** — event bridge and `run.ts` now use bounded request-response fetches with split SSE handshake/body watchdogs and a 1 MB SSE frame buffer cap. `tandem_reply` returns a structured timeout error instead of hanging indefinitely.
|
|
20
|
+
- **Sanitize coercions routed to migration-log (#483)** — lossy ADR-027 type coercions in `sanitize.ts` (e.g. `flag` → `note`) now emit a `migration-log.ts` entry (once per doc/kind) instead of silently rewriting records, restoring the forensic trail for ADR-027 transitions.
|
|
21
|
+
- **Doc hash required for collection logs (#495)** — annotation collection log entries now require a `docHash` field, preventing cross-document log pollution from unkeyed writes.
|
|
22
|
+
- **Standalone monitor gated on backend readiness (#491)** — `dev:standalone` waits for the backend health endpoint before starting the monitor, eliminating the startup race that caused spurious connection errors.
|
|
23
|
+
|
|
24
|
+
### Tests
|
|
25
|
+
|
|
26
|
+
- **E2E toolbar regression guard (#484)** — Playwright coverage for the redesigned toolbar (ADR-027 note/comment/highlight flow), including a regression guard for the note button empty-annotation bug (#480).
|
|
27
|
+
|
|
10
28
|
## \[0.9.0] - 2026-04-28
|
|
11
29
|
|
|
12
30
|
### Breaking Changes (MCP)
|
|
@@ -17,6 +35,9 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
17
35
|
- **`tandem_getContent` removed (#259)** — superseded by `tandem_getTextContent`.
|
|
18
36
|
- **`tandem_getSelections` removed (#259)** — superseded by `tandem_checkInbox`.
|
|
19
37
|
- **`tandem_setStatus` merged into `tandem_status` (#259)** — `tandem_status` now accepts optional write params (`text`, `focusParagraph`, `focusOffset`). When params are present it writes to awareness; when absent it reads.
|
|
38
|
+
- **`tandem_flag` deprecated (ADR-027, #473)** — returns a `DEPRECATED` error stub. Use `tandem_comment` instead. Hard-remove in v0.10.0.
|
|
39
|
+
- **`tandem_highlight` deprecated (ADR-027, #473)** — returns a `DEPRECATED` error stub. Highlights are user-only. Hard-remove in v0.10.0.
|
|
40
|
+
- **Annotation `directedAt` field removed (ADR-027, #473)** — silently ignored on input; stripped from on-disk records via `sanitizeAnnotation` and the `normalizeAnnotation` fast path on read.
|
|
20
41
|
|
|
21
42
|
### Added
|
|
22
43
|
|
|
@@ -29,6 +50,8 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
29
50
|
- **Highlight palette migration (#450)** — palette switched from 5 colors to 4 (yellow/green/blue/pink). `LEGACY_COLOR_MAP` migrates `red` → `yellow`, `purple` → `blue` on annotation load.
|
|
30
51
|
- **CI stdio smoke test (#341)** — GitHub Actions step validates the Cowork stdio bridge (`scripts/ci/stdio-smoke.mjs`) on every push.
|
|
31
52
|
- **`__MCP_SDK_VERSION__` build-time injection** — tsup reads the real SDK version from the package root (not the CJS type marker) and injects it at build time.
|
|
53
|
+
- **`tandem_getAnnotations` `includeImports` opt-in (ADR-027, #473)** — accepts `includeImports: true` to surface `author: "import"` reviewer comments imported from `.docx` files. Default still excludes them so the user triages first. When imports are filtered out, the response includes `importsExcluded: N` so Claude can prompt the user to opt in.
|
|
54
|
+
- **Deprecated-tool user notifications (ADR-027, #473)** — `tandem_highlight`, `tandem_flag`, and `tandem_suggest` stubs now `pushNotification` a warning toast in addition to returning the `DEPRECATED` mcpError, so the user sees what Claude tried.
|
|
32
55
|
|
|
33
56
|
### Fixed
|
|
34
57
|
|
|
@@ -39,11 +62,16 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
39
62
|
- **Annotation recovery guard hardening** — narrowed guard scope for edge cases in session restore.
|
|
40
63
|
- **Event-bridge error handling** — uncaught errors in SSE delivery no longer crash the event loop.
|
|
41
64
|
- **MCP SDK version resolution** — `require("@modelcontextprotocol/sdk/package.json")` resolves to `dist/cjs/package.json` (a CJS type marker without `version`); build now walks back past `dist/` to find the real version.
|
|
65
|
+
- **Silent-migration logging (ADR-027, #473)** — `parseAnnotationDoc`, `migrateToV1`, and the `directedAt` strip fast path now log via the new `migration-log.ts` module (once per `${docHash}:${kind}`) instead of silently rewriting v0 records. Restores forensic trail for the v0→v1 transition.
|
|
66
|
+
- **`normalizeReply` validation (#473)** — replies are now Zod-validated before being merged; malformed entries are dropped + logged instead of poisoning the envelope.
|
|
42
67
|
|
|
43
68
|
### Changed
|
|
44
69
|
|
|
45
70
|
- **Redesign gap audit resolved (#439)** — 7 product decisions documented in ADR-026. Design response prompt at `docs/claude-design-response-prompt.md`.
|
|
46
71
|
- **Distribution items deferred** — #316 (macOS/Linux Cowork auto-setup), #317 (cross-platform firewall scoping), #322 (network-type detection) moved to v0.13.0. Requires macOS/Linux validation hardware.
|
|
72
|
+
- **Annotation type model unified to audience-based (ADR-027, #473)** — `flag` → `note`. Three types now: `highlight` (visual marker), `note` (private), `comment` (sent to Claude). Channel observer filters notes from SSE — they never reach Claude. `checkInbox` returns only `comment` annotations.
|
|
73
|
+
- **Note toolbar UX (#480)** — Note button now opens an inline input mirroring the Comment flow.
|
|
74
|
+
- **Note card visual distinction (#481)** — amber border + warning-bg tint distinguishes notes from comments in the side panel.
|
|
47
75
|
|
|
48
76
|
### Internal
|
|
49
77
|
|
|
@@ -132,14 +160,14 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
132
160
|
|
|
133
161
|
- **Annotation GC race on startup (#334)** — `cleanupOrphanedAnnotationFiles` previously ran as a `.then()` chain during boot, racing the boot-path doc opens. On upgrade paths where `sample/welcome.md` or `CHANGELOG.md` hadn't been opened in 30+ days, the GC could unlink the annotation file between read intent and the actual read, silently returning an empty doc. Now `await`-ed before all boot-path opens.
|
|
134
162
|
- **Settings Popover extends out of view (#306)** — centered the popover in the viewport with `transform: translate(-50%, -50%)` and added `maxHeight: calc(100vh - 32px)` + `overflowY: auto` so it is always fully visible and internally scrollable on short screens.
|
|
135
|
-
- **Dark-mode
|
|
163
|
+
- **Dark-mode `*-bg` tokens inconsistent (#307)** — `--tandem-success-bg` and `--tandem-warning-bg` in dark mode were hand-coded hex while `--tandem-error-bg` used `color-mix`. All three now use `color-mix(in srgb, var(--tandem-<semantic>) 15%, var(--tandem-surface))` for consistency with light-mode behavior.
|
|
136
164
|
- **stdio bridge silent-failure paths (#336 partial)** — three paths in `src/cli/mcp-stdio.ts` (preflight exit, `http.onclose`, `http.start()` TOCTOU) previously closed stdio without writing a JSON-RPC error, producing "tools never appear in Cowork" with no diagnostics. All three now synthesize `-32000` for any in-flight request ID before exit. Remaining #336 items (channel-shim tests, Windows npx smoke, nits) carry to v0.7.0.
|
|
137
165
|
|
|
138
166
|
### Changed
|
|
139
167
|
|
|
140
168
|
- **Annotation module internals** — extracted `mergeMap<T>` helper (#324), promoted `UPLOAD_PREFIX` to shared constants (#327), centralized app-data dir resolution in `platform.ts` (#328), extracted `ReplyAuthorSchema`, trimmed module headers, and dropped unused `docContexts` map (#332). No user-facing behavior changes.
|
|
141
|
-
- **Annotation serialization upgrades legacy
|
|
142
|
-
-
|
|
169
|
+
- **Annotation serialization upgrades legacy `type` values on write (#329)** — records with non-canonical `type` (`"suggestion"` / `"question"` / anything outside `highlight` / `comment` / `flag`) are now routed through `sanitizeAnnotation` during snapshot serialization, which rewrites them to `"comment"`. **One-way lossy migration:** users with legacy-type annotations will see `type` flip to `"comment"` on the next durable write for that document — the original distinction between `suggestion` and `question` is not recoverable.
|
|
170
|
+
- **`migrateToV1` reports drop counts (#330)** — `migrateToV1(raw)` now returns `{ doc, droppedAnnotations, droppedReplies }` so future production callers can surface lossy upgrades to users rather than silently discarding malformed records. No production caller exists yet; a follow-up will wire drop counts to `npm run doctor` or a toast when the first caller lands.
|
|
143
171
|
|
|
144
172
|
### Internal
|
|
145
173
|
|
|
@@ -184,9 +212,9 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
184
212
|
|
|
185
213
|
### Fixed
|
|
186
214
|
|
|
187
|
-
- **Monitor preserves last-known
|
|
215
|
+
- **Monitor preserves last-known `documentId`** — doc-less events (e.g. `chat:message`) no longer blank out the tracked document, so the shutdown awareness clear always targets a valid document.
|
|
188
216
|
- **Monitor exits 1 on shutdown awareness failure** — if the final `clearAwareness` POST fails during SIGINT/SIGTERM, the monitor exits with a non-zero status rather than silently succeeding.
|
|
189
|
-
-
|
|
217
|
+
- **`/api/setup` returns accurate status codes** — 207 on partial failure (some targets configured, some failed) and 500 on total failure, instead of always returning 200.
|
|
190
218
|
- **Checkpoint after stdout write** — `lastEventId` is only advanced after `process.stdout.write` returns, so EPIPE on a closed pipe no longer silently skips an event on reconnect.
|
|
191
219
|
- **Async EPIPE surfaces as exit(1)** — `process.stdout.on('error')` listener now catches asynchronous EPIPE (plugin host closes pipe mid-stream); monitor exits 1 instead of silently advancing `lastEventId` past lost events.
|
|
192
220
|
- **Defensive exit on monitor fallthrough** — the retry loop exits 1 if it ever terminates without hitting the explicit exhaustion path.
|
|
@@ -196,7 +224,7 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
196
224
|
### Added
|
|
197
225
|
|
|
198
226
|
- **Claude Code plugin support** — monitor-based event push (`src/monitor/index.ts`) gives real-time notifications without polling or the channel shim. Install via `claude plugin marketplace add bloknayrb/tandem`.
|
|
199
|
-
-
|
|
227
|
+
- **`--with-channel-shim` opt-in** — `tandem setup --with-channel-shim` writes the legacy `tandem-channel` MCP entry for setups that can't install the plugin.
|
|
200
228
|
|
|
201
229
|
### Changed
|
|
202
230
|
|
|
@@ -210,7 +238,7 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
210
238
|
- **Exponential backoff on reconnect** — monitor reconnects use 2s/4s/8s/16s/30s backoff instead of a fixed 2s delay.
|
|
211
239
|
- **SIGINT/SIGTERM clears awareness** — monitor posts a final `clearAwareness` before exit so the "Claude is active" indicator doesn't hang in the browser.
|
|
212
240
|
- **Per-route fetch timeouts** — `AbortSignal.timeout` enforces budgets per route (connect 10s, mode 2s, awareness 5s, error report 3s) to prevent hung SSE connects or mode lookups from stalling the monitor.
|
|
213
|
-
- **SSE parse errors don't advance
|
|
241
|
+
- **SSE parse errors don't advance `lastEventId`** — JSON parse failures and schema validation errors are logged with event ID + frame tail but do not advance `lastEventId`, so bad events are re-delivered on reconnect rather than silently dropped.
|
|
214
242
|
- **SKILL.md corrected** — `question` annotation guidance now uses `type === 'comment' && directedAt === 'claude' && author === 'user'`; all 5 highlight colors listed (yellow, red, green, blue, purple).
|
|
215
243
|
|
|
216
244
|
## \[0.5.0] - 2026-04-13
|
|
@@ -277,7 +305,7 @@ This is the last breaking-change window before semver lock. MCP tool count: 31
|
|
|
277
305
|
- **Annotation type unification:** Three semantically identical types (`comment`, `suggestion`, `question`) collapsed into a single `comment` type with optional `suggestedText` and `directedAt` fields. `AnnotationTypeSchema` reduced from 5 values to 3: `highlight`, `comment`, `flag`. (#193, #245, #255)
|
|
278
306
|
- **Toolbar:** Three annotation buttons (Comment, Suggest, Ask Claude) replaced with a single Comment button with "Replace" and "@Claude" toggles (#193)
|
|
279
307
|
- **Side panel filters:** "Suggestions" → "With replacement", "Questions" → "For Claude" (#193)
|
|
280
|
-
-
|
|
308
|
+
- **`sanitizeAnnotation()` moved to `src/shared/sanitize.ts`** — now available to both server and client code. Client-side Y.Map reads are sanitized to handle legacy session data. (#255)
|
|
281
309
|
|
|
282
310
|
### Added
|
|
283
311
|
|
package/README.md
CHANGED
|
@@ -99,7 +99,7 @@ claude
|
|
|
99
99
|
Then pick one of two ways to keep the conversation flowing:
|
|
100
100
|
|
|
101
101
|
1. **Just chat in the terminal (simplest).** Every time you send Claude a message, it has a chance to call `tandem_checkInbox` and pick up your latest selection, any annotations you accepted or dismissed, and any chat messages from the Tandem sidebar. Zero setup — this is how it works out of the box. With Tandem and the terminal snapped side by side, the loop feels surprisingly natural; Claude just reacts when you nudge it rather than spontaneously.
|
|
102
|
-
2. **Background polling with
|
|
102
|
+
2. **Background polling with ****/loop**** (hands-off).** Ask Claude to check in on its own using the `/loop` skill:
|
|
103
103
|
```
|
|
104
104
|
/loop 30s check tandem inbox and respond to any new messages
|
|
105
105
|
```
|
|
@@ -129,10 +129,10 @@ curl http://localhost:3479/health
|
|
|
129
129
|
git clone https://github.com/bloknayrb/tandem.git
|
|
130
130
|
cd tandem
|
|
131
131
|
npm install
|
|
132
|
-
npm run dev:standalone # starts
|
|
132
|
+
npm run dev:standalone # starts backend (:3478/:3479), editor client (:5173), and monitor
|
|
133
133
|
```
|
|
134
134
|
|
|
135
|
-
Open http://localhost:5173 — you'll see `sample/welcome.md` loaded automatically on first run. The `.mcp.json` in the repo configures Claude Code automatically when run from this directory.
|
|
135
|
+
Open <http://localhost:5173> — you'll see `sample/welcome.md` loaded automatically on first run. The `.mcp.json` in the repo configures Claude Code automatically when run from this directory.
|
|
136
136
|
|
|
137
137
|
</details>
|
|
138
138
|
|
|
@@ -197,7 +197,7 @@ See the full [Roadmap](docs/roadmap.md) and [Known Limitations](docs/roadmap.md#
|
|
|
197
197
|
## Documentation
|
|
198
198
|
|
|
199
199
|
- **[User Guide](docs/user-guide.md)** — How to use Tandem: editor UI, annotations, chat, review mode, keyboard shortcuts
|
|
200
|
-
- [MCP Tool Reference](docs/mcp-tools.md) — 28 MCP tools + channel API endpoints
|
|
200
|
+
- [MCP Tool Reference](docs/mcp-tools.md) — 28 MCP tools (25 active, 3 deprecated stubs) + channel API endpoints
|
|
201
201
|
- [Architecture](docs/architecture.md) — System design, data flows, coordinate systems, channel push
|
|
202
202
|
- [Workflows](docs/workflows.md) — Claude Code usage patterns: text iteration, cross-referencing, multi-model
|
|
203
203
|
- [Roadmap](docs/roadmap.md) — Phase 2+ roadmap, known issues, future extensions
|
|
@@ -206,17 +206,17 @@ See the full [Roadmap](docs/roadmap.md) and [Known Limitations](docs/roadmap.md#
|
|
|
206
206
|
|
|
207
207
|
## CLI Commands
|
|
208
208
|
|
|
209
|
-
| Command
|
|
210
|
-
|
|
211
|
-
| `tandem`
|
|
212
|
-
| `tandem setup`
|
|
213
|
-
| `tandem setup --force`
|
|
214
|
-
| `tandem --version`
|
|
215
|
-
| `tandem --help`
|
|
216
|
-
| `tandem setup --with-channel-shim` | Also register the stdio channel shim
|
|
217
|
-
| `tandem rotate-token`
|
|
218
|
-
| `tandem mcp-stdio`
|
|
219
|
-
| `tandem channel`
|
|
209
|
+
| Command | What it does |
|
|
210
|
+
| ---------------------------------- | ------------------------------------------------------------------ |
|
|
211
|
+
| `tandem` | Start server and open editor (global install) |
|
|
212
|
+
| `tandem setup` | Register MCP tools with Claude Code / Claude Desktop |
|
|
213
|
+
| `tandem setup --force` | Register to default paths regardless of auto-detection |
|
|
214
|
+
| `tandem --version` | Show installed version |
|
|
215
|
+
| `tandem --help` | Show usage |
|
|
216
|
+
| `tandem setup --with-channel-shim` | Also register the stdio channel shim |
|
|
217
|
+
| `tandem rotate-token` | Rotate auth token (60-second grace window) |
|
|
218
|
+
| `tandem mcp-stdio` | Run as stdio MCP server (proxy to local HTTP, for plugin bridge) |
|
|
219
|
+
| `tandem channel` | Run the channel shim (stdio MCP for plugin's tandem-channel entry) |
|
|
220
220
|
|
|
221
221
|
## MCP Configuration
|
|
222
222
|
|
|
@@ -248,21 +248,21 @@ Both entries are cross-platform — no platform-specific configuration needed.
|
|
|
248
248
|
|
|
249
249
|
All optional — defaults work out of the box.
|
|
250
250
|
|
|
251
|
-
| Variable
|
|
252
|
-
|
|
253
|
-
| `TANDEM_PORT`
|
|
254
|
-
| `TANDEM_MCP_PORT`
|
|
255
|
-
| `TANDEM_URL`
|
|
256
|
-
| `TANDEM_TRANSPORT`
|
|
257
|
-
| `TANDEM_NO_SAMPLE`
|
|
258
|
-
| `TANDEM_CLAUDE_CMD`
|
|
259
|
-
| `TANDEM_BIND_HOST`
|
|
260
|
-
| `TANDEM_AUTH_TOKEN`
|
|
261
|
-
| `TANDEM_ALLOW_UNAUTHENTICATED_LAN` | unset
|
|
262
|
-
| `TANDEM_LAN_IP`
|
|
263
|
-
| `TANDEM_REQUEST_TIMEOUT_MS`
|
|
264
|
-
| `TANDEM_APP_DATA_DIR`
|
|
265
|
-
| `TANDEM_ANNOTATION_STORE`
|
|
251
|
+
| Variable | Default | Description |
|
|
252
|
+
| ---------------------------------- | ----------------------- | --------------------------------------------------------------- |
|
|
253
|
+
| `TANDEM_PORT` | `3478` | Hocuspocus WebSocket port |
|
|
254
|
+
| `TANDEM_MCP_PORT` | `3479` | MCP HTTP + REST API port |
|
|
255
|
+
| `TANDEM_URL` | `http://localhost:3479` | Channel shim server URL |
|
|
256
|
+
| `TANDEM_TRANSPORT` | `http` | Transport mode (`http` or `stdio`) |
|
|
257
|
+
| `TANDEM_NO_SAMPLE` | unset | Set to `1` to skip auto-opening `sample/welcome.md` |
|
|
258
|
+
| `TANDEM_CLAUDE_CMD` | `claude` | Claude Code executable name (for `tandem setup` auto-detection) |
|
|
259
|
+
| `TANDEM_BIND_HOST` | `127.0.0.1` | Bind address for MCP HTTP (`0.0.0.0` for LAN) |
|
|
260
|
+
| `TANDEM_AUTH_TOKEN` | auto-generated | Override auth token (set by Tauri; manual use rare) |
|
|
261
|
+
| `TANDEM_ALLOW_UNAUTHENTICATED_LAN` | unset | Set to `1` to skip token requirement on LAN bind |
|
|
262
|
+
| `TANDEM_LAN_IP` | auto-detected | Explicit LAN IP for multi-homed machines |
|
|
263
|
+
| `TANDEM_REQUEST_TIMEOUT_MS` | `30000` | Per-request timeout in stdio bridge (ms) |
|
|
264
|
+
| `TANDEM_APP_DATA_DIR` | platform default | Override app-data root (sessions, auth-token, annotations) |
|
|
265
|
+
| `TANDEM_ANNOTATION_STORE` | unset | Set to `off` to disable durable annotation persistence |
|
|
266
266
|
|
|
267
267
|
See `.env.example` for a copy-paste template.
|
|
268
268
|
|
|
@@ -279,6 +279,8 @@ Tandem kills stale processes on :3478/:3479 at startup. If another app uses thos
|
|
|
279
279
|
**Channel shim fails to start**
|
|
280
280
|
The `tandem-channel` entry spawns a subprocess. For global installs, `tandem setup` writes absolute paths to the bundled `dist/channel/index.js` — re-run `tandem setup` after upgrading. For dev setup, if you see `MODULE_NOT_FOUND` with a production config (`node dist/channel/index.js`), run `npm run build`. The default dev config uses `npx tsx` and doesn't require a build step.
|
|
281
281
|
|
|
282
|
+
If the shim starts but logs `/api/events timed out after 10000ms`, `SSE inactivity timeout`, or `/api/channel-reply timed out after 5000ms`, the Tandem server accepted a connection but stopped responding on that path. Restart Tandem; the shim reports the timeout instead of hanging silently.
|
|
283
|
+
|
|
282
284
|
**Editor shows "Cannot reach the Tandem server"**
|
|
283
285
|
The editor connects to the server via WebSocket. For global installs, run `tandem` to start the server. For dev setup, use `npm run dev:standalone` (or `npm run dev:server`). The message appears after 3 seconds of failed connection.
|
|
284
286
|
|
|
@@ -287,17 +289,17 @@ On first run, `sample/welcome.md` auto-opens. If you've cleared sessions or dele
|
|
|
287
289
|
|
|
288
290
|
## Development
|
|
289
291
|
|
|
290
|
-
| Command
|
|
291
|
-
|
|
292
|
-
| `npm run dev:standalone` | **Recommended** —
|
|
293
|
-
| `npm run dev:server`
|
|
294
|
-
| `npm run dev:client`
|
|
295
|
-
| `npm run build`
|
|
296
|
-
| `npm test`
|
|
297
|
-
| `npm run test:e2e`
|
|
298
|
-
| `npm run test:e2e:ui`
|
|
299
|
-
| `cargo tauri dev`
|
|
300
|
-
| `cargo tauri build`
|
|
292
|
+
| Command | What it does |
|
|
293
|
+
| ------------------------ | ---------------------------------------------------------------------------------- |
|
|
294
|
+
| `npm run dev:standalone` | **Recommended** — frontend + backend + monitor |
|
|
295
|
+
| `npm run dev:server` | Backend only: Hocuspocus (:3478) + MCP HTTP (:3479) |
|
|
296
|
+
| `npm run dev:client` | Frontend only: Vite dev server (:5173) |
|
|
297
|
+
| `npm run build` | Production build (`dist/server/` + `dist/channel/` + `dist/cli/` + `dist/client/`) |
|
|
298
|
+
| `npm test` | Run vitest (unit tests) |
|
|
299
|
+
| `npm run test:e2e` | Run Playwright E2E tests |
|
|
300
|
+
| `npm run test:e2e:ui` | Playwright UI mode |
|
|
301
|
+
| `cargo tauri dev` | Tauri desktop app (dev mode with hot-reload) |
|
|
302
|
+
| `cargo tauri build` | Tauri production build (installer output) |
|
|
301
303
|
|
|
302
304
|
**Tauri development** requires the [Rust toolchain](https://www.rust-lang.org/tools/install) and [Tauri CLI](https://v2.tauri.app/start/prerequisites/). Web-only development (`npm run dev:standalone`) does not require Rust.
|
|
303
305
|
|