Skip to content

fix(daemon): preserve ACP startup exit diagnostics #6266

Description

@Siri-Ray

Problem

When an ACP child exits during initialize or session setup without returning a JSON-RPC error, the bridge emits only a generic exit message. Stderr is retained only for an AMR-specific classifier, so startup failures from adapters such as Hermes and Kimi lose the actionable provider/configuration diagnostic.

Expected behavior

Attach a bounded, redacted stderr tail and the active ACP phase to a structured child-exit error. Keep the user-facing message concise and never expose raw secrets or terminal control sequences.

Verification

Add regression coverage for startup-phase classification, ANSI removal, and secret redaction.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions