Urgent.News

What's breaking now, across thousands of outlets.

AI

enabled: false Silently Disabled Claude Code Scheduled Tasks

Conclusion Running Claude Code's scheduled tasks unattended, we found they stop three different ways . How it stops What happened Fix needed ① Never starts Mac was asleep, or the app was closed None — it runs automatically on the next launch ② Starts, then dies mid-run A dropped connection, so the API was never reached No retry exists. The next slot has to catch up ③ The slot itself gets disabled…

We examined the Claude Code desktop app's scheduled tasks to understand why they sometimes fail silently. There are three ways a task can stop without anyone noticing.

Firstly, the task never starts. This happens if the Mac is asleep or the app is closed. However, the task automatically retries when the app is launched again.

Secondly, the task starts but fails mid-run due to an API connection error. There is no retry mechanism in place, so the task stops without completing. For example, on August 17th at 8:02 PM, the 8:06 writing slot failed mid-run with an "API Error: Can't reach the API server (ENOTFOUND)".

The third way a slot can disappear is if it is deliberately disabled. This happens when the "enabled" flag is set to false. We didn't notice this was happening for three weeks, from September 27th to October 4th. During that time, three out of four writing slots were disabled, causing our daily output to drop significantly. We now check every daily run to ensure disabled slots are re-enabled automatically.

To judge if a task actually ran, we look for an artifact file in Git. If the file appears, we consider the task successful. This approach helps differentiate between a task that died and a task that was simply disabled.

We also measured the time it takes for tasks to complete and for artifacts to appear. Initially, we guessed 120 minutes, but after measuring from August 17th to August 30th, we found the median time ranged from 13 to 169 minutes, with some tasks taking much longer. We adjusted the wait time to 180 minutes to avoid false alarms from tasks that were merely disabled.

Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.

Read the original at dev.to →

More in AI

More from Tuesday 27 October →