Skip to content

Desktop: no session event when a tracked PR is merged/closed (only comment & CI events arrive) #70389

Description

@tecclaudius

What I'm trying to do

When Claude Code is watching a pull request in a Desktop session, I want it to learn when that PR is merged (or closed), the same way it already learns about new review comments and CI status changes.

What happens today

The session receives ci-monitor-event notifications for new review comments and CI results on a watched PR, but there is no event when the PR's state changes to MERGED (or CLOSED). The "Merged" badge that appears in the UI is presentation chrome — it is not delivered into the agent's context.

Consequently the agent has no reliable signal that a PR has landed. It will keep treating the branch as open, may try to keep working it, and has to be told "I merged it" or run gh pr view defensively before asserting state. A user described it as "a real gap in your core logic."

Reproduction

  1. In a Desktop session, open/track a PR (so ci-monitor-events start arriving for comments/CI).
  2. Merge the PR on GitHub.
  3. Observe: no event is delivered to the session announcing the merge; the agent's view of the PR stays "open" until it independently queries gh.

Requested behavior

Emit a ci-monitor-event (or equivalent notification) into the session when a tracked PR transitions to MERGED or CLOSED, including the new state and merge commit. This closes the loop with the existing comment/CI events and lets the agent stop work, clean up the branch/worktree, and avoid acting on stale assumptions.

Environment

  • Claude Code Desktop (macOS)
  • CLI version reference: 2.1.37 (desktop app build may differ)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions