Scheduled tasks: run sessions pile up in Recents and sync across devices, with no automatable cleanup
Status Open
Maintainer reply None cached
Workaround ✓ Mentioned in description ↑
Activity 0 comments · opened Jul 31, 2026
Environment: Claude Code desktop app on macOS (CLI 2.1.x, current as of 2026-07-31), session mirroring enabled.
Problem
Every scheduled-task run creates a session. With mirroring on, each run session appears in Recents on every device. A task on a twice-hourly cron produces 30+ such sessions per day; there is no way to prevent them being surfaced, and no automatable way to clean them up. Users of frequent routines end up with a session list dominated by run artifacts.
Workarounds attempted, all blocked (each verified on a live machine)
- Archiving from within the scheduled run (instructing the task to archive its own prior runs, or itself): the archive tool raises "This tool requires explicit approval regardless of permission mode" on every call in scheduled contexts - for the current session and for others - so an unattended run just stalls on a prompt.
- Archiving from an interactive session: works, but prompts for confirmation on every single call even with a
permissions.allowrule for the tool. Clearing a day of run sessions is 30+ manual clicks. - Editing
isArchivedin the session store files directly: ignored while the app is running; session state appears to live in the daemon's memory. - Per-task or per-session opt-out of mirroring: none found; upload behavior appears to be a single global setting.
Requests (any one of these would resolve it)
- A per-scheduled-task option to keep run sessions out of Recents / mirroring (they are operational artifacts, not user work).
- Opt-in auto-archive of a scheduled task's completed run sessions.
- Let
permissions.allowrules actually cover the archive tool (or provide a bulk-archive affordance) so cleanup can be automated or done in one action.
Reproduction
- Create a scheduled task with any cron (e.g.
2,32 * * * *) and a trivial prompt. - Let it run for a day with mirroring on.
- Observe Recents on any synced device; attempt each workaround above.