Summary
In a single Claude Code session on Windows, two different wire identities coexist and the CLI vs MCP halves of the same session bind to different ones. A peer paired via the MCP server is therefore invisible to every CLI command (monitor, pull, tail) — including the persistent wire monitor --json stream-watcher the MCP instructions tell you to arm on session start. The watcher silently tails the wrong inbox forever.
This is adjacent to #284 item 4 ("CLI commands hang when WIRE_HOME is not inherited"), but worse: it is not just a different home pointer, it is a different identity (different DID, different keypair, different inbox).
Environment:
- OS: Windows 10 Pro (19045)
- Binary:
C:\Users\Willard\.local\bin\wire.exe, wire 0.16.0 (clean)
- Host: Claude Code MCP integration, session-keyed
WIRE_HOME under ...\sessions\by-key\<id>
Repro / evidence
Same session, two whoami:
wire_whoami via MCP server → did:wire:outback-kingfisher-91a7a643, session_source: claude-code, home ...\by-key\ed93d6bd22575a99
wire whoami via SessionStart hook / env WIRE_HOME → did:wire:cedar-cricket-a3d9db39, session_source: env:WIRE_HOME, home ...\by-key\86ffbec7235beba7
Consequence chain:
- Operator accepts an inbound pair from peer
velvet-ember via MCP → it pins under outback-kingfisher (...\ed93d6bd...\state\wire\inbox\velvet-ember.jsonl).
- The armed
wire monitor --json (a Bash tool process) inherits the hook WIRE_HOME = cedar-cricket → it tails the wrong inbox and never emits velvet-ember's replies.
wire pull / wire tail from the shell likewise return cedar-cricket's history (old peers), not the MCP-paired peer. Looks like "peer went silent" when the messages are sitting in the other identity's inbox.
Workaround that fixed it: locate the MCP identity's home by grepping by-key/*/config/wire/agent-card.json for the handle, then re-arm the monitor with WIRE_HOME explicitly pointed at it.
Contributing factor: session→identity proliferation
ls ...\sessions\by-key\ shows hundreds of keyed homes — each session/resume appears to mint a new keyed identity rather than reuse a stable one. So the MCP identity and the hook identity drift apart, and old identities accumulate (each a distinct DID a peer might have paired with historically).
Expectation
- A session should resolve to one identity across MCP and CLI/hook, OR
WIRE_HOME resolution must be deterministic and shared (the SessionStart hook and the MCP server must agree on the same by-key home), and
wire monitor / pull / tail should warn loudly when the active identity has zero pinned peers but other by-key homes have pinned peers (the "you're watching the wrong inbox" case), and
- consider a stable per-host (or per-project) identity instead of per-session keyed homes, to stop DID churn and home proliferation.
Summary
In a single Claude Code session on Windows, two different wire identities coexist and the CLI vs MCP halves of the same session bind to different ones. A peer paired via the MCP server is therefore invisible to every CLI command (
monitor,pull,tail) — including the persistentwire monitor --jsonstream-watcher the MCP instructions tell you to arm on session start. The watcher silently tails the wrong inbox forever.This is adjacent to #284 item 4 ("CLI commands hang when
WIRE_HOMEis not inherited"), but worse: it is not just a different home pointer, it is a different identity (different DID, different keypair, different inbox).Environment:
C:\Users\Willard\.local\bin\wire.exe, wire 0.16.0 (clean)WIRE_HOMEunder...\sessions\by-key\<id>Repro / evidence
Same session, two
whoami:wire_whoamivia MCP server →did:wire:outback-kingfisher-91a7a643,session_source: claude-code, home...\by-key\ed93d6bd22575a99wire whoamivia SessionStart hook / env WIRE_HOME →did:wire:cedar-cricket-a3d9db39,session_source: env:WIRE_HOME, home...\by-key\86ffbec7235beba7Consequence chain:
velvet-embervia MCP → it pins underoutback-kingfisher(...\ed93d6bd...\state\wire\inbox\velvet-ember.jsonl).wire monitor --json(a Bash tool process) inherits the hookWIRE_HOME=cedar-cricket→ it tails the wrong inbox and never emits velvet-ember's replies.wire pull/wire tailfrom the shell likewise returncedar-cricket's history (old peers), not the MCP-paired peer. Looks like "peer went silent" when the messages are sitting in the other identity's inbox.Workaround that fixed it: locate the MCP identity's home by grepping
by-key/*/config/wire/agent-card.jsonfor the handle, then re-arm the monitor withWIRE_HOMEexplicitly pointed at it.Contributing factor: session→identity proliferation
ls ...\sessions\by-key\shows hundreds of keyed homes — each session/resume appears to mint a new keyed identity rather than reuse a stable one. So the MCP identity and the hook identity drift apart, and old identities accumulate (each a distinct DID a peer might have paired with historically).Expectation
WIRE_HOMEresolution must be deterministic and shared (the SessionStart hook and the MCP server must agree on the same by-key home), andwire monitor/pull/tailshould warn loudly when the active identity has zero pinned peers but other by-key homes have pinned peers (the "you're watching the wrong inbox" case), and