{"version":"2.1.292","anchor":"scheduled-task-scheduler-leases-and-watcher-recreation","canonical_anchor":"scheduled-task-scheduler-leases-and-watcher-recreation","heading":"Scheduled tasks stored in files are handed between sessions more carefully","tier":"internal","area":"Elsewhere","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.292\/e\/scheduled-task-scheduler-leases-and-watcher-recreation","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.292","markdown":"### Scheduled tasks stored in files are handed between sessions more carefully\n\nThe scheduler for file-based scheduled tasks can now give up its lock, rewatches files when they change, and recognises a session's own tasks\n\n**What**\n\nScheduled tasks can be stored in files, and one Claude Code session at a time holds a lock that makes it the one that runs them. The scheduler has changed in three ways:\n\n- It can now be told to stop holding the lock. When that happens it releases the lock and does not take it back. By default it keeps holding it.\n\n- The watcher that notices changes to task files is now recreated whenever a file is added, changed or removed. Before, it was created once.\n\n- Sessions now keep track of their own session ids, so tasks a session created are recognised as its own.\n\n**Why**\n\nThis affects which session runs your file-based scheduled tasks.\n\n- Area: Elsewhere\n- Tier: Under the hood\n- Useful: 2\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: no"}