Skip to content

[Bug]: using codex harness with gpt-5.4-nano causes errors #85806

@garyd9

Description

@garyd9

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

(Not sure if this is actually a "regression" or not as I'm comparing to a version of openclaw that didn't include codex)
OC 2026.5.20 using codex and openai's gpt-5.4-nano results in errors and fallbacks

Steps to reproduce

start with 4.23 configured to use API and gpt-5.4-nano (Default) and gpt-5.4-mini (fallback)

Chat works fine.

Upgrade to 2026.5.20 and run "doctor --fix" a couple times to get the codex plugin going.

Ensure codex harness is in use and type anything in webchat while the model is gpt-5.4-nano.

Expected behavior

It should just work.

Actual behavior

OC falls back to gpt-5.4-mini and errors are written to the log (see below)

OpenClaw version

2026.5.20

Operating system

linux (debian/trixie)

Install method

install.sh followed by "openclaw update" (npm, I think)

Model

openai/gpt-5.4-nano

Provider / routing chain

direct to openai

Additional provider/model setup details

No response

Logs, screenshots, and evidence

Log snippet from the fallback:

May 23 13:42:23 openclaw node[3091]: 2026-05-23T13:42:23.628-04:00 [agent/embedded] unsupported thinking level for openai/gpt-5.4-nano; retrying with off
May 23 13:42:24 openclaw node[3091]: 2026-05-23T13:42:24.054-04:00 [agent/embedded] codex plugin thread config eligibility
May 23 13:42:24 openclaw node[3091]: 2026-05-23T13:42:24.952-04:00 [agent/embedded] embedded run failover decision: runId=acf78b00-489f-4249-9e91-e016bf24322c stage=prompt decision=surface_error reason=none from=openai/gpt-5.4-nano profile=sha256:a0ebe3f799a6 rawError={ "type": "error", "error": { "type": "invalid_request_error", "message": "Tool 'tool_search' is not supported with gpt-5.4-nano.", "param": "tools" }, "status": 400 }
May 23 13:42:24 openclaw node[3091]: 2026-05-23T13:42:24.953-04:00 [diagnostic] lane task error: lane=main durationMs=4597 error="{
May 23 13:42:24 openclaw node[3091]:   "type": "error",
May 23 13:42:24 openclaw node[3091]:   "error": {
May 23 13:42:24 openclaw node[3091]:     "type": "invalid_request_error",
May 23 13:42:24 openclaw node[3091]:     "message": "Tool 'tool_search' is not supported with gpt-5.4-nano.",
May 23 13:42:24 openclaw node[3091]:     "param": "tools"
May 23 13:42:24 openclaw node[3091]:   },
May 23 13:42:24 openclaw node[3091]:   "status": 400
May 23 13:42:24 openclaw node[3091]: }"
May 23 13:42:24 openclaw node[3091]: 2026-05-23T13:42:24.954-04:00 [diagnostic] lane task error: lane=session:agent:main:main durationMs=4599 error="{
May 23 13:42:24 openclaw node[3091]:   "type": "error",
May 23 13:42:24 openclaw node[3091]:   "error": {
May 23 13:42:24 openclaw node[3091]:     "type": "invalid_request_error",
May 23 13:42:24 openclaw node[3091]:     "message": "Tool 'tool_search' is not supported with gpt-5.4-nano.",
May 23 13:42:24 openclaw node[3091]:     "param": "tools"
May 23 13:42:24 openclaw node[3091]:   },
May 23 13:42:24 openclaw node[3091]:   "status": 400
May 23 13:42:24 openclaw node[3091]: }"
May 23 13:42:24 openclaw node[3091]: 2026-05-23T13:42:24.958-04:00 [model-fallback/decision] model fallback decision: decision=candidate_failed requested=openai/gpt-5.4-nano candidate=openai/gpt-5.4-nano reason=unknown providerErrorType=invalid_request_error next=openai/gpt-5.4-mini detail=Tool 'tool_search' is not supported with gpt-5.4-nano.

Impact and severity

Affected: unknown

Severity: For those using nano to save money, the constant fallback to a more expensive model is severe, though changing to the pi harness works around the issue.

Frequency: 100% reproducible

Consequence: It really makes openAI's codex harness look bad.

Additional information

It is possible to switch to the pi model to work around the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Normal backlog priority with limited blast radius.bugSomething isn't workingclawsweeper:fix-shape-clearClawSweeper found a clear likely implementation shape for this issue.clawsweeper:queueable-fixClawSweeper marked this issue as an existing queue_fix_pr work candidate.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.impact:auth-providerAuth, provider routing, model choice, or SecretRef resolution may break.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions