claude-code - 💡(How to fix) Fix [Bug] CronCreate registration silently dropped after agent /compact in agent-mode session [2 comments, 3 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#55033Fetched 2026-05-01 05:48:00
View on GitHub
Comments
2
Participants
3
Timeline
5
Reactions
0
Timeline (top)
labeled ×3commented ×2

Error Message

Actual: Cron schedule is silently dropped. Agent no longer receives timed ticks. No error, no warning. The only recovery paths are: (a) operator manually restarts the agent window, or (b) parent session re-dispatches inline.

Fix Action

Fix / Workaround

Summary: A Claude Code agent running in agent-mode (dispatched by a parent session) loses its CronCreate registration when it compacts. After compaction, cron ticks do not resume — the agent goes dark with no warning.

Steps to reproduce:

  1. Parent session (e.g., Opus, non-agent mode) dispatches a child agent in agent mode
  2. Child agent registers a recurring schedule via CronCreate (e.g., every 15 minutes for polling work)
  3. Child agent accumulates context and compacts
  4. Observe: cron ticks do not fire after compaction completes

Actual: Cron schedule is silently dropped. Agent no longer receives timed ticks. No error, no warning. The only recovery paths are: (a) operator manually restarts the agent window, or (b) parent session re-dispatches inline.

RAW_BUFFERClick to expand / collapse

Summary: A Claude Code agent running in agent-mode (dispatched by a parent session) loses its CronCreate registration when it compacts. After compaction, cron ticks do not resume — the agent goes dark with no warning.

Version: v2.1.121 (not yet tested on v2.1.123)

Steps to reproduce:

  1. Parent session (e.g., Opus, non-agent mode) dispatches a child agent in agent mode
  2. Child agent registers a recurring schedule via CronCreate (e.g., every 15 minutes for polling work)
  3. Child agent accumulates context and compacts
  4. Observe: cron ticks do not fire after compaction completes

Expected: CronCreate registrations persist through compaction — agent resumes receiving scheduled ticks after compact.

Actual: Cron schedule is silently dropped. Agent no longer receives timed ticks. No error, no warning. The only recovery paths are: (a) operator manually restarts the agent window, or (b) parent session re-dispatches inline.

Impact:

  • Autonomous sessions that cross a compaction boundary lose their scheduling silently
  • Parent session waiting for filesystem check-ins from the cron-driven child gets indefinite silence — indistinguishable from the child being alive but idle vs. cron-dead
  • Compounds with the model-downgrade bug (#54426): both result in autonomous agent sessions going dark at the context-limit boundary, both fail silently

Platform: Windows, observed in agent-mode child dispatched by non-agent-mode parent

Workaround: Keep the parent/dispatcher window in non-agent mode so it accumulates less context, compacts less often, and can re-dispatch workers on natural wakes. Reduces exposure but does not fix the underlying cron-state persistence gap through compaction.

extent analysis

TL;DR

The issue can be mitigated by keeping the parent/dispatcher window in non-agent mode to reduce compaction frequency and allow for re-dispatching of workers.

Guidance

  • Investigate the CronCreate registration process to understand why it does not persist through compaction.
  • Verify that the issue is specific to agent-mode and compaction by testing different scenarios, such as non-agent mode or manual cron registration.
  • Consider implementing a fallback mechanism for the parent session to detect and re-dispatch the child agent if it goes dark after compaction.
  • Review the code changes between versions v2.1.121 and v2.1.123 to see if the issue has been addressed.

Example

No code snippet is provided as the issue does not contain sufficient information to create a specific example.

Notes

The provided workaround reduces exposure to the issue but does not fix the underlying problem. The root cause of the CronCreate registration loss during compaction needs to be identified and addressed.

Recommendation

Apply the workaround of keeping the parent/dispatcher window in non-agent mode, as it reduces the frequency of compaction and allows for re-dispatching of workers, thereby mitigating the issue.

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 [Bug] CronCreate registration silently dropped after agent /compact in agent-mode session [2 comments, 3 participants]