週日準備:10 分鐘超時檢查(一次緩慢的夜間跑步讓我錯失了一篇部落格文章,而日誌卻隻字未提)

AI代理調度:一排磨砂玻璃磚,如同時間軸,一塊長長的青色磚滑過下一塊磚,下一塊磚下方發出琥珀色的光芒。

This week’s setup check takes ten minutes and one sheet of paper: for every agent you schedule, compare its timeout with the gap before the next agent starts. If the timeout is longer, one slow run can quietly cost you the next job.

AI agent scheduling usually gets planned as a list of start times. The part people skip is the end times. I skipped it too, and on 7 October it cost me a blog post.

What happened on 7 October

My fleet runs on one schedule file: 12 daily slots plus a handful of weekly ones, 94 runs a week. A small Python loop reads the file and launches each job. It runs 一次只做一份工作, so it waits for the current job to finish before it looks at the clock again. A slot only fires if the loop sees it within 2 minutes of its start time.

On 6 October at 23:35, my nightly watchdog started. It found a failed outreach job and retried it on the spot, which took 25 minutes. The watchdog finished at 00:11:55. The blog writer’s slot is 00:07, and its window closed at 00:09:59.

So the blog writer never ran. And nothing complained. The scheduler log goes straight from “task completed” at 00:11:55 to “new day, resetting slots” at 00:12:25. There’s no line for 00:07 at all. 7 October is the only day since 15 June without a blog-writer log.

No error and no crash, just a gap. That’s the worst kind of failure, because you only find it if you go looking.

The fix was one rule, not new code

I didn’t rewrite the scheduler. I added a rule to the watchdog’s instructions: before retrying anything late at night, estimate how long the retry will take from that job’s recent runs. If it would still be running at 00:09:59, don’t run it. Flag it for me in the morning report instead.

喬恩瓊斯

⚡ 取得人工智慧優勢

每週提供真正省時省錢的AI小技巧。沒有廢話,沒有誇大其詞——只有切實有效的方法。.

訂閱電子報 - 部落格行動號召

Since then the blog writer has run every single day, 46 days in a row (8 October to today). The watchdog’s longest run in the last 30 days was 1.6 minutes.

What today’s check found

This morning (22 November 2026) I did the full version of the check. I listed every active slot for each day of the week, wrote the timeout next to it, and wrote the gap to the next slot next to that.

  • 94 runs a week. 9 have a timeout longer than the gap after them.
  • 7 of those 9 are the nightly watchdog: a 60-minute timeout, and 30 minutes until the blog writer. That’s the 7 October trap, now covered by the rule above.
  • The other 2 are on Mondays: the 09:07 social poster and the 10:37 outreach query researcher. Both have 60-minute timeouts and only 30 minutes before the next job.

Neither Monday job has come close. Their longest runs in the last 30 days were 11.7 and 7.7 minutes. So this is risk on paper, not a live problem. Fixing it means shortening those two timeouts or moving a slot, and that’s on my list, not done.

One more surprise: the job writing this post. It has a 60-minute timeout, and on five days of the week, today included, the next job starts exactly 60 minutes later. On 19 November, with WordPress crawling, it ran 49 minutes and finished 10.9 minutes before the next slot. That was the tightest gap in the whole fleet last month.

Run the check yourself (10 minutes)

  1. Write down every scheduled automation in start-time order, per day if your weekly jobs differ.
  2. Next to each one, write its timeout, or “none” if it can run forever. “None” is your first fix.
  3. Write the gap until the next job starts. Circle every row where the timeout is longer than the gap.
  4. For each circled row, look up the longest real run. Most of the time it’s fine, and you’ll know by how much.
  5. Decide what a skipped job looks like. If your scheduler drops a late slot silently, like mine does, something else has to compare “should have run” against “did run.” My watchdog does that every night.

If you use n8n, Zapier or cron, the same logic applies. Anything that runs one job at a time, or locks a shared file, can lose a slot to a slow neighbor.

要點: schedule the end of every job, not just the start.

If you’re tidying your schedule anyway, here’s how I switch an agent off without deleting it, and what the boring scheduler at the center of my agentic OS looks like. If you’d like a second pair of eyes on your own fleet’s timing, 預約自動化策略會議.

人工智慧行動指南-免費下載

📥 免費:《人工智慧劇本》

我用來經營一人代理公司的所有工具和工作流程。 25 年的行銷經驗濃縮成一份實用指南。免費贈送。.

引流工具 - AI 策略手冊

相關文章

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *