S17: spike before editors in the swarm (about a day) #41

Closed
opened 2026-10-02 05:20:26 +00:00 by jhgaylor · 1 comment
Owner

Depends on: #36 (only its connection and preview numbers; it can start now)
Blocks: #42, #43

Swarm track: editors. Zoom into the swarm and land in someone's editor: a VS Code started on the pane's machine (M27), or the editor they already have open, followed from the browser (M28). This spike answers what those need first.


  • Claude Code's IDE protocol:
    • how Claude Code finds an IDE (lockfiles in ~/.claude/ide/), how it connects (MCP over a WebSocket, and its auth token), and which tools it calls (openDiff, diagnostics, selection, open editors);
    • can illogicald register as an IDE itself, so that Claude Code's diff approvals and questions arrive as attention reasons (#38) with no editor open?
    • what happens when a real IDE and illogicald are registered at once.
  • Extensions on remote machines: with VS Code and Cursor over Remote-SSH and in dev containers, does a workspace extension run on the remote host and reach the local illogicald socket there? Check the same for Zed's remote development and for nvim on the machine.
  • What an editor can report cheaply: active file, cursor and selection, visible range, diagnostics counts, debugger state and unsaved buffers, from the VS Code API and from nvim's autocmds.
    • Measure event rates while typing, and the debouncing needed to stay under M23's summary budget.
  • openvscode-server or code-server:
    • licence and extension marketplace (Open VSX) for each;
    • memory per instance and cold start on geek and in a wisp sandbox;
    • does it run inside a browser block (M6a) with no auth of its own, behind the daemon's access checks?
  • Follow-mode rendering: Monaco in the page (bundle size, theming next to the terminal), or a lighter read-only code view?

Output: a short write-up in spikes/s17-editors/, with a go/no-go on illogicald as a Claude Code IDE, which server goes in M27, and the editor event schema for M28.

**Depends on:** #36 (only its connection and preview numbers; it can start now) **Blocks:** #42, #43 *Swarm track: editors. Zoom into the swarm and land in someone's editor: a VS Code started on the pane's machine (M27), or the editor they already have open, followed from the browser (M28). This spike answers what those need first.* -------- - **Claude Code's IDE protocol:** - how Claude Code finds an IDE (lockfiles in `~/.claude/ide/`), how it connects (MCP over a WebSocket, and its auth token), and which tools it calls (`openDiff`, diagnostics, selection, open editors); - can illogicald register as an IDE itself, so that Claude Code's diff approvals and questions arrive as attention reasons (#38) with no editor open? - what happens when a real IDE and illogicald are registered at once. - **Extensions on remote machines:** with VS Code and Cursor over Remote-SSH and in dev containers, does a workspace extension run on the remote host and reach the local `illogicald` socket there? Check the same for Zed's remote development and for nvim on the machine. - **What an editor can report cheaply:** active file, cursor and selection, visible range, diagnostics counts, debugger state and unsaved buffers, from the VS Code API and from nvim's autocmds. - Measure event rates while typing, and the debouncing needed to stay under M23's summary budget. - **openvscode-server or code-server:** - licence and extension marketplace (Open VSX) for each; - memory per instance and cold start on geek and in a wisp sandbox; - does it run inside a browser block (M6a) with no auth of its own, behind the daemon's access checks? - **Follow-mode rendering:** Monaco in the page (bundle size, theming next to the terminal), or a lighter read-only code view? **Output:** a short write-up in `spikes/s17-editors/`, with a go/no-go on illogicald as a Claude Code IDE, which server goes in M27, and the editor event schema for M28.
Author
Owner

Done: merged in 4bd0719 (spike c414cec). See spikes/s17-editors/README.md; PLAN.md has M27/M28 notes.

  • illogicald as a Claude Code IDE: go, alongside M29's permission hook. Every Edit/Write in default mode reached a fake IDE; accept, reject and accept-with-changes all worked. Only Edit/Write go to the IDE (Bash and questions stay with the hook / M6c); acceptEdits sends nothing. Claude Code doesn't reconnect after the IDE goes away until /ide, so connections must survive daemon restarts. Register with no workspace folders and set CLAUDE_CODE_SSE_PORT in panes: Claude in a pane picks illogicald, elsewhere never sees it (two IDEs on one folder make --ide connect to neither).
  • M27: code-server (current VS Code 1.140, MIT, Open VSX, compressed, no-auth/no-trust/unix-socket/idle flags; 135/417 MB idle/attached with chat off; 5.4 s cold in wisp). Serve it on a 0600 unix socket; the daemon's port proxy needs a unix-socket target. Pass explicit config paths (it writes to ~ even for --help).
  • M28 schema in the README: an editor presence entry in M23's summary at the 1 s tick, plus a follow stream throttled at 100 ms only while followed. Throttle, don't debounce. Zed dropped (extensions can't see the cursor or open a socket).
  • Remote extensions reach a socket on the server's machine (VS Code Server, code-server, openvscode-server); in Docker only with the socket's directory mounted; nvim with built-in Lua.
  • Follow view: CodeMirror 6 (182 KB gz) over Monaco (780 KB).
  • Unverified: Remote-SSH end to end, Cursor, Dev Containers, JetBrains, debugger events, phones, code-server through the daemon's unix-socket proxy.
Done: merged in 4bd0719 (spike c414cec). See spikes/s17-editors/README.md; PLAN.md has M27/M28 notes. - **illogicald as a Claude Code IDE: go, alongside M29's permission hook.** Every Edit/Write in default mode reached a fake IDE; accept, reject and accept-with-changes all worked. Only Edit/Write go to the IDE (Bash and questions stay with the hook / M6c); acceptEdits sends nothing. Claude Code doesn't reconnect after the IDE goes away until `/ide`, so connections must survive daemon restarts. Register with no workspace folders and set CLAUDE_CODE_SSE_PORT in panes: Claude in a pane picks illogicald, elsewhere never sees it (two IDEs on one folder make --ide connect to neither). - **M27: code-server** (current VS Code 1.140, MIT, Open VSX, compressed, no-auth/no-trust/unix-socket/idle flags; 135/417 MB idle/attached with chat off; 5.4 s cold in wisp). Serve it on a 0600 unix socket; the daemon's port proxy needs a unix-socket target. Pass explicit config paths (it writes to ~ even for --help). - **M28 schema** in the README: an editor presence entry in M23's summary at the 1 s tick, plus a follow stream throttled at 100 ms only while followed. Throttle, don't debounce. Zed dropped (extensions can't see the cursor or open a socket). - Remote extensions reach a socket on the server's machine (VS Code Server, code-server, openvscode-server); in Docker only with the socket's directory mounted; nvim with built-in Lua. - Follow view: CodeMirror 6 (182 KB gz) over Monaco (780 KB). - Unverified: Remote-SSH end to end, Cursor, Dev Containers, JetBrains, debugger events, phones, code-server through the daemon's unix-socket proxy.
Commenting is not possible because the repository is archived.
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jhgaylor/illogical#41
No description provided.