#update is causing error
1 messages · Page 1 of 1 (latest)
That error usually means your config is forcing the embedded harness to codex, but the bundled codex plugin did not load/register after the update.
First, can you paste:
openclaw --version
openclaw plugins list --json
openclaw config get agents.defaults.embeddedHarness --json
openclaw config get plugins --json
Quick unblock if you did not intentionally switch to the native Codex harness:
openclaw config set agents.defaults.embeddedHarness.runtime '"auto"' --strict-json
openclaw gateway restart
If you did intend to use the Codex harness, make sure the bundled plugin is enabled and not excluded by plugins.allow:
openclaw config set plugins.entries.codex.enabled true --strict-json
openclaw gateway restart
Docs: https://docs.openclaw.ai/plugins/codex-harness and https://docs.openclaw.ai/gateway/configuration-reference#agentsdefaultsembeddedharness
what is the differences between codex harness? we had to use our codex subscription initially to use gpt at one time, could it have been from that configuration?
Yes, very likely.
There are two different “Codex” paths that sound similar:
-
Codex subscription / OAuth as a model provider
- Config uses model refs like
openai-codex/... - OpenClaw still runs the normal embedded agent runner
- This was the path people used when they wanted GPT access through their Codex/ChatGPT subscription auth
- Config uses model refs like
-
Codex harness
- Config forces
agents.defaults.embeddedHarness.runtime = "codex" - OpenClaw hands the low-level agent turn to the Codex app-server harness
- This requires the bundled
codexplugin to load and register the harness
- Config forces
Your error specifically says the harness named codex is requested but not registered, so it points at path #2, not just “using Codex OAuth”.
So yes: an older config from when you were trying to use GPT via Codex could have left behind one of these:
agents: {
defaults: {
embeddedHarness: {
runtime: "codex"
}
}
}
or an env var like:
OPENCLAW_AGENT_RUNTIME=codex
If you only need the subscription/OAuth provider path, set the harness back to auto:
openclaw config set agents.defaults.embeddedHarness.runtime '"auto"' --strict-json
openclaw gateway restart
Docs for the split: https://docs.openclaw.ai/plugins/codex-harness
i tried those commands, still having same error
Two likely reasons it can persist after that:
- The existing thread/session is pinned to the old harness. Harness choice is sticky per session. Try starting a fresh session in this thread:
/reset
or /new, then send a normal test message.
- Something else is still forcing
codex, usually an env var or per-agent override. Please paste these outputs:
openclaw --version
openclaw config get agents.defaults.embeddedHarness --json
openclaw config get agents.list --json
openclaw config get plugins --json
printenv | grep OPENCLAW_AGENT
openclaw logs --tail 120
Also check whether you set this in your service env, shell profile, Docker compose, systemd unit, or launchd plist:
OPENCLAW_AGENT_RUNTIME=codex
If that env var exists, it overrides config. Remove it or set it to auto, then restart the gateway/service.
openclaw logs --tail 120
{
"entries": {
"telegram": {
"enabled": true,
"config": {}
},
"discord": {
"enabled": true,
"config": {}
},
"brave": {
"enabled": true,
"config": {
"webSearch": {
"apiKey": "OPENCLAW_REDACTED"
}
}
},
"openai": {
"enabled": true,
"config": {
"personality": "friendly"
}
},
"anthropic": {
"enabled": true,
"config": {}
},
"github-copilot": {
"enabled": true,
"config": {}
},
"memory-core": {
"enabled": true,
"config": {
"dreaming": {
"enabled": true
}
}
}
}
}
OpenClaw does not recognize option "--tail".
Try: openclaw logs 120 --help
My bad on the logs flag. Current docs say it is:
openclaw logs --limit 120
That plugin output is useful: I do not see codex enabled there. So if OpenClaw is still asking for harness codex, it’s almost certainly being forced by either:
agents.defaults.embeddedHarness.runtime- an
agents.list[*].embeddedHarness.runtimeper-agent override OPENCLAW_AGENT_RUNTIME=codex- or the existing session is still pinned and needs
/reset
Try the stronger config cleanup:
openclaw config unset agents.defaults.embeddedHarness
openclaw gateway restart
Then in this Discord thread run:
/reset
If it still fails, please paste these exact outputs:
openclaw --version
openclaw config get agents.defaults.embeddedHarness --json
openclaw config get agents.list --json
printenv | grep OPENCLAW_AGENT
openclaw logs --limit 120
If agents.list shows an agent with "embeddedHarness": { "runtime": "codex" }, that override needs to be removed too. Docs: https://docs.openclaw.ai/plugins/codex-harness and https://docs.openclaw.ai/cli/logs
first part gave me this, and still having the same initial error...
bash openclaw config unset agents.defaults.embeddedHarness
openclaw gateway restart
/opt/homebrew/bin/openclaw: line 3: import: command not found
/opt/homebrew/bin/openclaw: line 4: import: command not found
/opt/homebrew/bin/openclaw: line 5: import: command not found
/opt/homebrew/bin/openclaw: line 6: import: command not found
/opt/homebrew/bin/openclaw: line 7: import: command not found
/opt/homebrew/bin/openclaw: line 8: import: command not found
/opt/homebrew/bin/openclaw: line 9: import: command not found
/opt/homebrew/bin/openclaw: line 11: const: command not found
/opt/homebrew/bin/openclaw: line 12: const: command not found
/opt/homebrew/bin/openclaw: line 13: .: filename argument required
.: usage: . filename [arguments]
/opt/homebrew/bin/openclaw: line 13: const: command not found
/opt/homebrew/bin/openclaw: openclaw: line 15: syntax error near unexpected token (' /opt/homebrew/bin/openclaw: openclaw: line 15: const parseNodeVersion = (rawVersion) => {'
Config warnings:
- plugins.entries.discord: plugin not installed: discord — install the official external plugin with: openclaw plugins install @openclaw/discord
- plugins.entries.brave: plugin not installed: brave — install the official external plugin with: openclaw plugins install @openclaw/brave-plugin
The second part command returned alot of text, i may have to paste multiple posts for you to see it all
Ah, I see the issue: you accidentally ran the OpenClaw CLI through bash.
This part:
bash openclaw config unset agents.defaults.embeddedHarness
makes bash try to interpret the OpenClaw JavaScript file, which is why you got import: command not found and const: command not found. The config unset probably did not happen.
Run it exactly like this, no bash in front:
openclaw config unset agents.defaults.embeddedHarness
openclaw config get agents.defaults.embeddedHarness --json
openclaw gateway restart
Then in this Discord thread run:
/reset
If config get agents.defaults.embeddedHarness still shows anything with "runtime": "codex", paste that small output.
The plugin warnings are a separate clue too:
plugins.entries.discord: plugin not installed
plugins.entries.brave: plugin not installed
That means your config references external plugins that are no longer installed after the update. You’ll probably want to reinstall those after this harness issue is fixed:
openclaw plugins install @openclaw/discord
openclaw plugins install @openclaw/brave-plugin
openclaw gateway restart
But first fix the stuck harness config/session, because that matches the original Requested agent harness "codex" is not registered error.
/reset
ok i typed the reset command in this chat then did config get agents.defaults.embeddedHarness and got this:
Config warnings:
- plugins.entries.discord: plugin not installed: discord — install the official external plugin with: openclaw plugins install @openclaw/discord
- plugins.entries.brave: plugin not installed: brave — install the official external plugin with: openclaw plugins install @openclaw/brave-plugin
🦞 OpenClaw 2026.5.12 (f066dd2) — iMessage green bubble energy, but for everyone.
Config path not found: agents.defaults.embeddedHarness. Run openclaw config validate to inspect config shape.
Good, Config path not found: agents.defaults.embeddedHarness means the default harness override is gone. So the remaining source is probably one of these:
- per-agent override in
agents.list - service/env override like
OPENCLAW_AGENT_RUNTIME=codex - plugin install state after the update
Next, run these smaller checks:
openclaw config get agents.list --json | grep -n -C 3 'embeddedHarness\|codex'
printenv | grep OPENCLAW_AGENT
launchctl getenv OPENCLAW_AGENT_RUNTIME
openclaw config validate
On macOS, printenv only checks your current shell. If the gateway is running under launchd, launchctl getenv OPENCLAW_AGENT_RUNTIME matters more.
Also, those plugin warnings are real. Your config says Discord and Brave are enabled, but they are not installed in this OpenClaw install. Reinstall them, then restart:
openclaw plugins install @openclaw/discord
openclaw plugins install @openclaw/brave-plugin
openclaw gateway restart
After restart, run /reset again in the Discord thread and test. If the harness error still appears, paste just the output of the agents.list ... grep and the two env checks above.
first command:
max@12:74:81:ad:54:8b ~ % openclaw config get agents.list --json | grep -n -C 3 'embeddedHarness|codex'
printenv | grep OPENCLAW_AGENT
launchctl getenv OPENCLAW_AGENT_RUNTIME
openclaw config validate
7- "name": "bdcbot",
8- "workspace": "/Users/max/.openclaw/workspace",
9- "agentDir": "/Users/max/.openclaw/agents/bdcbot/agent",
10: "model": "openai-codex/gpt-5.4"
11- }
12-]
Config warnings:
- plugins.entries.discord: plugin not installed: discord — install the official external plugin with: openclaw plugins install @openclaw/discord
- plugins.entries.brave: plugin not installed: brave — install the official external plugin with: openclaw plugins install @openclaw/brave-plugin
🦞 OpenClaw 2026.5.12 (f066dd2) — Gateway online—please keep hands, feet, and appendages inside the shell at all times.
Config valid: ~/.openclaw/openclaw.json
That output narrows it down nicely.
openai-codex/gpt-5.4 is your old Codex subscription/OAuth model route. By itself, that should be the PI/OpenClaw provider path, not the native codex harness. Since there’s no default embeddedHarness and no env output, I’d fix the install/plugin state next.
Your config says Discord and Brave are enabled, but this install says those plugins are missing. Run:
openclaw plugins install @openclaw/discord
openclaw plugins install @openclaw/brave-plugin
openclaw gateway restart
Then in this Discord thread:
/reset
If it still throws the same harness error, don’t paste the huge full logs yet. Paste this filtered output instead:
openclaw logs --limit 300 --plain | grep -i -C 4 'harness\|codex\|plugin'
openclaw sessions --all-agents --json | grep -n -C 4 'harness\|codex'
At this point the remaining suspicious thing is a stale session/harness pin or a plugin load failure during startup, and those two filtered commands should show which one it is.
im over the limits of this message by 63000 if i paste the response to that command. anything more specific?
Yep, let’s make it tiny. Run these and paste only the output:
openclaw logs --limit 80 --plain | grep -i 'Requested agent harness\|not registered\|agent harness selected\|loaded plugin\|failed.*plugin'
And this config/session search:
grep -RIn '"runtime": "codex"\|"runtime":"codex"\|embeddedHarness\|selectedHarnessId\|harness' ~/.openclaw/openclaw.json ~/.openclaw/agents 2>/dev/null | head -80
If that second one is still too big, split it:
grep -RIn '"runtime": "codex"\|"runtime":"codex"\|embeddedHarness' ~/.openclaw/openclaw.json ~/.openclaw/agents 2>/dev/null | head -40
grep -RIn 'selectedHarnessId\|harness' ~/.openclaw/agents/*/sessions* ~/.openclaw/agents/*/agent 2>/dev/null | head -40
I’m specifically looking for either:
- a leftover config/session pin saying
runtime: codexorselectedHarnessId: codex - a startup/plugin line explaining why the codex harness/plugin didn’t register
'Requested agent harness|not registered|agent harness selected|loaded plugin|failed.*plugin'
2026-05-15T19:38:46.515Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=main durationMs=82 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:38:46.516Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=session:agent:main:main durationMs=83 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:38:46.526Z warn model-fallback/decision {"subsystem":"model-fallback/decision"} {"event":"model_fallback_decision","tags":["error_handling","model_fallback","candidate_failed"],"runId":"1a0066eb-6ba5-4e91-a0a0-7be8a7827828","sessionId":"531cee5b-b047-4ae4-88c4-244a607a184f","lane":"main","decision":"candidate_failed","requestedProvider":"openai-codex","requestedModel":"gpt-5.5","candidateProvider":"openai-codex","candidateModel":"gpt-5.5","attempt":1,"total":2,"errorPreview":"Requested agent harness "codex" is not registered.","errorHash":"sha256:7e02b9d21701","fallbackStepType":"fallback_step","fallbackStepFromModel":"openai-codex/gpt-5.5","fallbackStepToModel":"openai-codex/gpt-5.4","fallbackStepFromFailureDetail":"Requested agent harness "codex" is not registered.","fallbackStepChainPosition":1,"fallbackStepFinalOutcome":"next_fallback","nextCandidateProvider":"openai-codex","nextCandidateModel":"gpt-5.4","isPrimary":true,"requestedModelMatched":true,"fallbackConfigured":true} model fallback decision
2026-05-15T19:38:46.599Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=main durationMs=63 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:38:46.600Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=session:agent:main:main durationMs=64 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:38:46.610Z error Embedded agent failed before reply: Requested agent harness "codex" is not registered.
2026-05-15T19:44:26.766Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=main durationMs=93 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:44:26.767Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=session:agent:main:main durationMs=95 error="Error: Requested agent harness "codex" is not registered."
Log tail truncated (increase --max-bytes).
2026-05-15T19:44:26.778Z warn model-fallback/decision {"subsystem":"model-fallback/decision"} {"event":"model_fallback_decision","tags":["error_handling","model_fallback","candidate_failed"],"runId":"a1cd08b4-c09f-401d-9c21-3e908aabdb47","sessionId":"531cee5b-b047-4ae4-88c4-244a607a184f","lane":"main","decision":"candidate_failed","requestedProvider":"openai-codex","requestedModel":"gpt-5.5","candidateProvider":"openai-codex","candidateModel":"gpt-5.5","attempt":1,"total":2,"errorPreview":"Requested agent harness "codex" is not registered.","errorHash":"sha256:7e02b9d21701","fallbackStepType":"fallback_step","fallbackStepFromModel":"openai-codex/gpt-5.5","fallbackStepToModel":"openai-codex/gpt-5.4","fallbackStepFromFailureDetail":"Requested agent harness "codex" is not registered.","fallbackStepChainPosition":1,"fallbackStepFinalOutcome":"next_fallback","nextCandidateProvider":"openai-codex","nextCandidateModel":"gpt-5.4","isPrimary":true,"requestedModelMatched":true,"fallbackConfigured":true} model fallback decision
2026-05-15T19:44:26.867Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=main durationMs=80 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:44:26.868Z error diagnostic {"subsystem":"diagnostic"} lane task error: lane=session:agent:main:main durationMs=81 error="Error: Requested agent harness "codex" is not registered."
2026-05-15T19:44:26.876Z error Embedded agent failed before reply: Requested agent harness "codex" is not registered.
max@12:74:81:ad:54:8b ~ %
That log is enough. The failure is happening while trying openai-codex/gpt-5.5, then falling back to openai-codex/gpt-5.4. So your Codex OAuth model config is the trigger.
Since you want the Codex OAuth provider path, force the embedded runner to PI explicitly instead of auto:
openclaw config set agents.defaults.embeddedHarness '{"runtime":"pi","fallback":"pi"}' --strict-json
openclaw gateway restart
Then in this thread:
/reset
That should make openai-codex/gpt-5.4 run through the normal PI/OpenClaw route instead of trying to resolve a native codex harness.
If it still fails after that, paste only:
openclaw config get agents.defaults.model --json
openclaw config get agents.list --json | grep -n -C 4 'model\|embeddedHarness'
openclaw config get agents.defaults.embeddedHarness --json
The plugin warnings for Discord/Brave still need cleanup, but they’re separate from this harness error.
Yep, same signature. Those timestamps are before the PI-forcing command I just sent, so the next useful test is:
openclaw config set agents.defaults.embeddedHarness '{"runtime":"pi","fallback":"pi"}' --strict-json
openclaw gateway restart
Then run /reset here and send a test message.
If it still errors after that, grab the new lines only:
openclaw config get agents.defaults.embeddedHarness --json
openclaw logs --limit 80 --plain | grep -i 'Requested agent harness\|agent harness selected\|embedded agent failed'
I’m expecting the config output to show "runtime": "pi". If it does and the error still asks for codex, that’s a bug or a stale session store entry rather than normal config behavior.
That last line is still from 19:44:26, so it’s the same pre-fix failure.
Please run the PI-forcing command now, then restart and test:
openclaw config set agents.defaults.embeddedHarness '{"runtime":"pi","fallback":"pi"}' --strict-json
openclaw config get agents.defaults.embeddedHarness --json
openclaw gateway restart
Then run /reset here and send a test message.
If it fails again, paste only the fresh output from:
openclaw logs --limit 40 --plain | grep -i 'Requested agent harness\|embedded agent failed\|agent harness selected'
here are responses for both:
OpenClaw 2026.5.12 (f066dd2) — It's not "failing," it's "discovering new ways to configure the same thing wrong."
Error: Config validation failed: agents.defaults.embeddedHarness: Unrecognized key: "fallback"
🦞 OpenClaw 2026.5.12 (f066dd2) — Your task has been queued; your dignity has been deprecated.
openclaw config get agents.defaults.model --json
openclaw config get agents.list --json | grep -n -C 4 'model|embeddedHarness'
openclaw config get agents.defaults.embeddedHarness --json
{
"primary": "openai-codex/gpt-5.5",
"fallbacks": [
"openai-codex/gpt-5.4"
]
}
6- "id": "bdcbot",
7- "name": "bdcbot",
8- "workspace": "/Users/max/.openclaw/workspace",
9- "agentDir": "/Users/max/.openclaw/agents/bdcbot/agent",
10: "model": "openai-codex/gpt-5.4"
11- }
12-]
Config path not found: agents.defaults.embeddedHarness. Run openclaw config validate to inspect config shape.
max@12:74:81:ad:54:8b ~ %
Good catch. I gave you a config shape from newer docs; your 2026.5.12 schema only accepts embeddedHarness.runtime, not fallback. More importantly, in this version openai-codex/... model refs default to the codex runtime unless you override the model runtime policy.
For the immediate unblock, don’t use embeddedHarness. Force those legacy openai-codex refs through PI at the model-entry level:
openclaw config unset agents.defaults.embeddedHarness
openclaw config set agents.defaults.models '{"openai-codex/gpt-5.5":{"agentRuntime":{"id":"pi"}},"openai-codex/gpt-5.4":{"agentRuntime":{"id":"pi"}}}' --strict-json --merge
openclaw config get agents.defaults.models --json | grep -n -C 4 'openai-codex\|agentRuntime'
openclaw gateway restart
Then run /reset here and test again.
Why this should work: your logs show the run is selecting openai-codex/gpt-5.5 and openai-codex/gpt-5.4, and 2026.5.12 treats that provider as Codex-runtime by default. Adding agentRuntime.id: "pi" tells OpenClaw to use the old PI/OpenClaw route for those model refs instead of looking for the native codex harness.
Longer-term, the newer/current config direction is different: use openai/gpt-* model refs plus the Codex plugin for subscription-backed Codex runtime. But let’s get you unstuck first.
🦞 OpenClaw 2026.5.12 (f066dd2) — I'm the reason your shell history looks like a hacker-movie montage.
Config path not found: agents.defaults.embeddedHarness. Nothing was changed. Run openclaw config get <path> first if you are unsure of the path.
🦞 OpenClaw 2026.5.12 (f066dd2) — I'm not AI-powered, I'm AI-possessed. Big difference.
Config overwrite: /Users/max/.openclaw/openclaw.json (sha256 e640ced47ce8beb5b618ec100c4d78b50080c2aa6dd88ce10cbb9c6f45e89a5f -> a25347b5f9e63fbe699781ab63593e08a54d345d3614674dd5fcc5757c005981, backup=/Users/max/.openclaw/openclaw.json.bak)
Updated agents.defaults.models. Restart the gateway to apply.
1-{
2: "openai-codex/gpt-5.4": {
3: "agentRuntime": {
4- "id": "pi"
5- }
6- },
7: "openai-codex/gpt-5.5": {
8: "agentRuntime": {
9- "id": "pi"
10- }
11- },
12: "openai-codex/gpt-5.5-pro": {},
13- "openai/gpt-5.5": {}
14-}
🦞 OpenClaw 2026.5.12 (f066dd2) — We ship features faster than Apple ships calculator updates.
That part worked. The embeddedHarness unset warning is fine because it was already gone.
One more thing in your allowlist: openai-codex/gpt-5.5-pro still has no PI override. If it ever gets selected, it can trigger the same problem. Add the same override there too:
openclaw config set agents.defaults.models '{"openai-codex/gpt-5.5-pro":{"agentRuntime":{"id":"pi"}}}' --strict-json --merge
openclaw gateway restart
Then run /reset here and test.
If it still fails, paste the fresh lines from:
openclaw logs --limit 60 --plain | grep -i 'Requested agent harness\|model_fallback_decision\|embedded agent failed'