Skip to content

CCB daemon routes async asks to wrong pane across multiple windows/workspaces #137

@M-Marbouh

Description

@M-Marbouh

When using multiple Claude Code windows (different projects) open simultaneously, the CCB daemon incorrectly routes async ask responses to panes belonging to different projects instead of the originating project's pane.

Environment:

  • OS: Linux Mint 22.3
  • CCB Version: v5.2.8 (commit 5077c6c, built 2026-03-11)
  • Terminal emulators tested: Tmux, WezTerm (same behavior on both)
  • Setup: Multiple Claude Code windows open simultaneously across different workspaces

Steps to Reproduce:

  1. Open Claude Code in Window A (Project A)
  2. Open Claude Code in Window B (Project B)
  3. From Window A, send an async ask: CCB_CALLER=claude ask codex "test message"
  4. Task is submitted with [CCB_ASYNC_SUBMITTED provider=codex]
  5. Run /pend codex in Window A
  6. Actual: Response appears in Window B's pane, not Window A
  7. Subsequent asks route inconsistently; stale responses sometimes reappear

Expected Behavior:

  • Async ask from Window A routes exclusively to Window A's pane
  • Each window maintains isolated session and pane routing context
  • /pend provider returns the response to the correct originating window

Likely Root Cause:
Multiple CCB daemon instances run concurrently (multiple askd-.lock and ccb-.lock files observed in the run directory). Pane IDs appear to be terminal-local integers (e.g., 2, 3) that collide across different windows, causing the daemon to dispatch to whichever pane matches the ID regardless of which project context originated the request.

Additional Notes:

  • Issue is 100% reproducible with 2+ windows open
  • Occurs across multiple X11 workspaces
  • Makes async delegation unreliable when working across multiple projects simultaneously

Thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions