Skip to content

Cron scheduler initializes but jobs never fire #10522

@glados-wheatley-bot

Description

@glados-wheatley-bot

Description

The cron scheduler initializes correctly (logs cron: started with correct state) but jobs never actually execute. The internal timer that should fire at nextWakeAtMs doesn't trigger.

Environment

  • OpenClaw version: 2026.2.3-1
  • OS: macOS 15.3 (Darwin 25.2.0 arm64)
  • Node: 25.5.0
  • Install method: pnpm

Symptoms

  1. Gateway starts, cron scheduler logs:

    cron: started {"enabled":true,"jobs":23,"nextWakeAtMs":1770394680000}
    
  2. When nextWakeAtMs time arrives, nothing happens. No lane enqueue: session:agent:*:cron:* entries appear.

  3. The jobs.json file IS updated with new nextRunAtMs values, but jobs don't execute.

  4. Agents work fine when triggered via webchat/Telegram - only cron scheduler is broken.

  5. Issue persists after:

    • Gateway restart (SIGUSR1)
    • Full reinstall (pnpm install -g openclaw)
    • Fresh gateway start

Evidence

Working (Feb 5, ~6:50 UTC):

06:49:02 - cron: started (nextWakeAtMs = 10:50)
06:50:00 - lane enqueue: session:agent:forge:cron:... ✅
06:50:16 - lane task done ✅

Broken (Feb 6, after restart):

16:17:27 - cron: started (nextWakeAtMs = 16:18)
16:18:00 - [silence - no lane enqueue] ❌
16:22:00 - [still nothing at pixel's scheduled time] ❌

Workaround Attempted

  • cron.wake action with mode: "now" - no effect
  • cron.run with specific jobId - returns "ran": false, "reason": "not-due"

Expected Behavior

Jobs should fire at their scheduled times, creating lane enqueue: session:agent:*:cron:* entries and executing the agent sessions.

Additional Context

The scheduler appears to be in a state where it tracks time and updates state, but the setTimeout/setInterval callback that should trigger job execution is either not set up or not firing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions