Skip to content

provider-claude-code: unknown custom entry type agent-session-bridge-state floods sdk/unknown log #2319

Open

Description

@burningportra

Summary

visibility.ts in provider-claude-code parses every sdk/message entry. When the entry has type: "custom" with an unrecognized customType, the switch has no case and falls through to { kind: "sdk/unknown" }, which is logged heavily.

Symptom

High-frequency "SDK Unknown / Raw event: sdk/unknown" noise that looks alarming but is harmless. The parsed switch in parseClaudeRawEvent fails on entries like:

{
  "jsonrpc": "2.0",
  "method": "sdk/message",
  "params": { "message": { "type": "custom", "customType": "agent-session-bridge-state", ... } }
}

Cause

agent-session-bridge-state is a custom entry emitted by the session-bridge extension running inside Claude Code threads (it mirrors tracked sessions to local JSONL — see the mirrorPath field in the payload). It fires frequently on thread/agent state changes, so any active session with the bridge installed generates constant unknown logs.

Suggested

Add a known, inert case for this customType (or treat unrecognized custom entries as non-repeating/noise) so they don't surface as sdk/unknown — similar to how command_lifecycle and assistant are handled. These custom bridge-state entries carry no assistant content, so a dedicated case that ignores content solves the noise.

No changes were needed in the consuming plugin (bb-plugin-prompt-suggester) — root cause is entirely in the provider parser.

Activity

  1. added theissue type on Aug 24, 2026
  2. added
    providers
    provider-claude-code
    on Aug 24, 2026
  3. SawyerHood commented on Aug 24, 2026

    @SawyerHood
    Collaborator

    ---Auto-Generated---

    Reproduction & root-cause report: https://get-bb.github.io/reports/issues/2319.html

    • Verdict: REPRODUCED · root-cause confidence: high
    • Root cause (short): Misattributed to provider-claude-code: Pi 0.84 emits an entry_appended session event for every pi.appendEntry("agent-session-bridge-state", …) call by the agent-session-bridge Pi extension; bb's Pi bridge forwards it as sdk/message and plugins/provider-pi/src/visibility.ts has no case for entry_appended, so it is classified {kind:"sdk/unknown", coverage:"unknown"} and persisted as a provider/unhandled row ("SDK Unknown / Raw event: sdk/unknown") on every message_end/turn_end.
    • Proposed fix: In plugins/provider-pi/src/visibility.ts add entry_appended to PiSdkEventType, toPiSdkEventType, the sdk/simple branch of parsePiRawEvent, and the noise group of describeParsedPiRawEvent (4-line diff saved at 2319/repro/proposed-fix-visibility.diff; verified: repro test flips, existing 57 Pi tests pass, no wire change so no protocol bump). Do the same for the other Pi 0.84 session events (session_info_changed, thinking_level_changed, queue_update, summarization_retry_*, bash_execution_update) and add a test that runs every member of the vendored SDK's AgentSessionEvent["type"] union through …
    • Caveats: The issue's quoted payload shows the custom entry directly as params.message; Pi 0.84.x actually nests it under {type:"entry_appended", entry:{...}} — both shapes hit sdk/unknown today, but the proposed fix only covers the real entry_appended shape. Live bb repro used a stand-in extension (same appendEntry calls as agent-session-bridge) injected via BB_PI_BRIDGE_COMMAND/ARGS rather than the real e…

    The report is self-contained: copy-paste repro steps with the test or script inline, expected vs actual output, screenshots where the bug is visual, and code permalinks at the base commit. It was independently re-executed by a second agent (see its Verification section).

    AGENT GENERATED: by Claude Code

  4. added
    confirmed-repro
    on Aug 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmed-reproprovider-claude-codeproviders

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions