claude-code - 💡(How to fix) Fix Allow plugin monitors to opt out of the exit confirmation prompt [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#58852Fetched 2026-05-14 03:37:52
View on GitHub
Comments
0
Participants
1
Timeline
3
Reactions
0
Author
Participants
Timeline (top)
labeled ×3

Plugin monitors (monitors/monitors.json) are session-scoped: they start with the session and stop when it ends. Exiting a session with an active monitor currently triggers a confirmation prompt:

  Background work is running
  The following will stop when you exit:

  shell · <monitor description>

  ❯ 1. Exit anyway
    2. Stay

For monitors, the monitor stopping is the expected behavior on exit. The prompt adds a friction step on every session exit when a plugin includes an always-on monitor.

Root Cause

  1. Per-monitor silentExit: true field on entries in monitors/monitors.json — opts that monitor out of the prompt.
  2. Global suppressBackgroundExitConfirmation setting — less ideal because it would also affect Bash background tasks.

Code Example

Background work is running
  The following will stop when you exit:

  shell · <monitor description>

1. Exit anyway
    2. Stay
RAW_BUFFERClick to expand / collapse

Summary

Plugin monitors (monitors/monitors.json) are session-scoped: they start with the session and stop when it ends. Exiting a session with an active monitor currently triggers a confirmation prompt:

  Background work is running
  The following will stop when you exit:

  shell · <monitor description>

  ❯ 1. Exit anyway
    2. Stay

For monitors, the monitor stopping is the expected behavior on exit. The prompt adds a friction step on every session exit when a plugin includes an always-on monitor.

Proposal

One of:

  1. Per-monitor silentExit: true field on entries in monitors/monitors.json — opts that monitor out of the prompt.
  2. Global suppressBackgroundExitConfirmation setting — less ideal because it would also affect Bash background tasks.

Option 1 is preferred: the plugin author declares intent at config time. Other long-running work keeps the existing prompt.

Context

Use case: a plugin runs a mailbox-watcher monitor that delivers cross-agent messages to Claude as monitor lines. The monitor's lifetime is exactly the session's lifetime — nothing to preserve on exit. The confirmation is the only friction point.

Related

  • #18544 — different problem (completion-notification token waste) but in the same area.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix Allow plugin monitors to opt out of the exit confirmation prompt [1 participants]