openclaw - 💡(How to fix) Fix [Bug]: cron payload.model 'anthropic/claude-sonnet-4-20250514' still rejected by agents.defaults.models allowlist on 2026.5.7 [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#84101Fetched 2026-05-20 03:44:04
View on GitHub
Comments
1
Participants
2
Timeline
5
Reactions
1
Author
Timeline (top)
labeled ×3closed ×1commented ×1

A cron job still fails model validation with:

⚠️ Cron job "Hourly Email Check" failed: cron payload.model 'anthropic/claude-sonnet-4-20250514' rejected by agents.defaults.models allowlist: anthropic/claude-sonnet-4-20250514

This is happening on OpenClaw 2026.5.7.

Error Message

There have already been several cron/model-allowlist fixes in this area, but I'm still seeing the failure in production with an Anthropic model id. The error is also hard to reason about because it echoes the rejected model after allowlist: instead of showing what the actual allowed set was.

  1. Clear validation error: show the real allowlist contents / effective allowed models so the operator can fix config quickly.
  • the operator-facing error message is still confusing

Root Cause

Why I'm filing this

There have already been several cron/model-allowlist fixes in this area, but I'm still seeing the failure in production with an Anthropic model id. The error is also hard to reason about because it echoes the rejected model after allowlist: instead of showing what the actual allowed set was.

Code Example

⚠️ Cron job "Hourly Email Check" failed: cron payload.model 'anthropic/claude-sonnet-4-20250514' rejected by agents.defaults.models allowlist: anthropic/claude-sonnet-4-20250514

---

{
  "models": {
    "openai-codex/gpt-5.4-pro": {}
  },
  "model": {
    "primary": "openai-codex/gpt-5.4",
    "fallbacks": [
      "openai-codex/gpt-5.3-codex",
      "openai-codex/gpt-5.3-codex",
      "openai/o4-mini-deep-research",
      "openai/o3-deep-research"
    ]
  }
}

---

{
  "kind": "agentTurn",
  "model": "anthropic/claude-sonnet-4-20250514"
}

---

cron payload.model 'anthropic/claude-sonnet-4-20250514' rejected by agents.defaults.models allowlist: anthropic/claude-sonnet-4-20250514
RAW_BUFFERClick to expand / collapse

Summary

A cron job still fails model validation with:

⚠️ Cron job "Hourly Email Check" failed: cron payload.model 'anthropic/claude-sonnet-4-20250514' rejected by agents.defaults.models allowlist: anthropic/claude-sonnet-4-20250514

This is happening on OpenClaw 2026.5.7.

Why I'm filing this

There have already been several cron/model-allowlist fixes in this area, but I'm still seeing the failure in production with an Anthropic model id. The error is also hard to reason about because it echoes the rejected model after allowlist: instead of showing what the actual allowed set was.

Environment

  • OpenClaw version: 2026.5.7
  • Current main-session model: openai-codex/gpt-5.4
  • Cron job target: isolated session
  • Channel: Telegram (not likely relevant, but included for completeness)

Relevant config shape

My agents.defaults config currently looks like this:

{
  "models": {
    "openai-codex/gpt-5.4-pro": {}
  },
  "model": {
    "primary": "openai-codex/gpt-5.4",
    "fallbacks": [
      "openai-codex/gpt-5.3-codex",
      "openai-codex/gpt-5.3-codex",
      "openai/o4-mini-deep-research",
      "openai/o3-deep-research"
    ]
  }
}

The failing notification was for a cron payload with:

{
  "kind": "agentTurn",
  "model": "anthropic/claude-sonnet-4-20250514"
}

Steps to reproduce

  1. Configure agents.defaults.model.primary to a Codex model.
  2. Leave agents.defaults.models present as an object allowlist that does not include the Anthropic model above.
  3. Create an isolated cron job with payload.model: "anthropic/claude-sonnet-4-20250514".
  4. Wait for the cron run.

Actual behavior

Cron fails preflight/model validation and emits:

cron payload.model 'anthropic/claude-sonnet-4-20250514' rejected by agents.defaults.models allowlist: anthropic/claude-sonnet-4-20250514

Expected behavior

At minimum, one of these should happen clearly and consistently:

  1. Clear validation error: show the real allowlist contents / effective allowed models so the operator can fix config quickly.
  2. Better docs or migration behavior: if agents.defaults.models is now a strict allowlist for cron overrides, that needs to be obvious because it's easy to assume agents.defaults.model.primary/fallbacks are sufficient.
  3. No misleading echo: allowlist: should not print the rejected value again if that is not actually the configured allowlist.

Notes

This may be related to prior cron/model-routing or allowlist regressions, but I'm filing separately because:

  • it's still reproducible on 2026.5.7
  • the failing model is an Anthropic id
  • the operator-facing error message is still confusing

Possibly related:

  • #83617
  • #79058
  • #78297
  • #75854

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

At minimum, one of these should happen clearly and consistently:

  1. Clear validation error: show the real allowlist contents / effective allowed models so the operator can fix config quickly.
  2. Better docs or migration behavior: if agents.defaults.models is now a strict allowlist for cron overrides, that needs to be obvious because it's easy to assume agents.defaults.model.primary/fallbacks are sufficient.
  3. No misleading echo: allowlist: should not print the rejected value again if that is not actually the configured allowlist.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - 💡(How to fix) Fix [Bug]: cron payload.model 'anthropic/claude-sonnet-4-20250514' still rejected by agents.defaults.models allowlist on 2026.5.7 [1 comments, 2 participants]