Repository navigation
fix: subscribe before ACP session attach - #781
Conversation
Greptile SummaryThis PR updates ACP session attach to use the daemon subscribe flow. The main changes are:
Confidence Score: 5/5Safe to merge with minimal risk. The change is narrowly scoped to the ACP attach handshake and matches the daemon requirement that stateful clients subscribe before other session requests. Files Needing Attention: No files require special attention.
What T-Rex did
|
| Filename | Overview |
|---|---|
| src/cli/acp.rs | Updates ACP session attach to open the daemon connection with a target-aware Subscribe, forwarding the caller cwd while preserving history replay. |
Sequence Diagram
sequenceDiagram
participant ACP as ACP runtime
participant Daemon as Jcode daemon
participant Session as Target session
ACP->>Daemon: "Subscribe(id=1, working_dir=cwd, target_session_id)"
Daemon->>Session: Attach or restore target session
Session-->>Daemon: History(session_id, messages)
Daemon-->>ACP: History
ACP->>ACP: Replay history when requested
Daemon-->>ACP: "Done(id=1)"
ACP->>ACP: Store DaemonSession with attached session_id
Reviews (1): Last reviewed commit: "fix: subscribe before ACP session attach..." | Re-trigger Greptile
|
CI follow-up: Format, linked-issue, release automation, installer, TypeScript, PowerShell, Windows cross-target, and Greptile checks pass. The failing macOS and Quality Guardrails jobs reproduce the existing master compile mismatch tracked in #768 ( --- — Jcode agent (automated triage), on behalf of @1jehuang |
|
Final CI follow-up: Ubuntu has now completed and failed on the same seven pre-existing --- — Jcode agent (automated triage), on behalf of @1jehuang |
…e-subscribe fix: subscribe before ACP session attach
…e-subscribe fix: subscribe before ACP session attach
…e-subscribe fix: subscribe before ACP session attach
…e-subscribe fix: subscribe before ACP session attach
…e-subscribe fix: subscribe before ACP session attach
…e-subscribe fix: subscribe before ACP session attach
Summary
SubscribeThis fixes both #779 and #764, which share the same
attach_existing_sessionroot cause.Verification
cargo test --profile selfdev -p jcode cli::acp --no-default-features--- — Jcode agent (automated triage), on behalf of @1jehuang