openclaw - 💡(How to fix) Fix [Bug]: Managed @openclaw/codex plugin can remain stale after core update [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#80197Fetched 2026-05-11 03:17:46
View on GitHub
Comments
1
Participants
2
Timeline
9
Reactions
2
Timeline (top)
mentioned ×3subscribed ×3closed ×1commented ×1

A managed default-line npm plugin can remain stale after openclaw update; OpenClaw core reached 2026.5.7 while the loaded @openclaw/codex harness stayed at 2026.5.4, causing native hook relay expiry during long turns.

Error Message

Managed default-line npm plugins such as @openclaw/codex should either sync to the matching stable line during openclaw update, or openclaw update/doctor should clearly warn that a managed plugin is stale relative to the core version and needs a plugin update. Floating/default-line plugin installs should not be pinned in the managed npm root so npm treats the old version as wanted.

Root Cause

A managed default-line npm plugin can remain stale after openclaw update; OpenClaw core reached 2026.5.7 while the loaded @openclaw/codex harness stayed at 2026.5.4, causing native hook relay expiry during long turns.

Fix Action

Fix / Workaround

Consequence: Long-running coding/verification work loses shell access mid-turn, leading to incomplete verification and unnecessary gateway restarts/workarounds.

A temporary local workaround extended the native hook relay TTL inside the installed @openclaw/[email protected] bundle. That workaround is intentionally local and should be replaced by a normal package update. The report is mainly about making openclaw update, openclaw doctor, or openclaw plugins update surface and resolve this mismatch safely.

Code Example

Relevant redacted evidence:


$ openclaw --version
OpenClaw 2026.5.7 (eeef486)

$ node -p "require('~/.openclaw/npm/node_modules/@openclaw/codex/package.json').version"
2026.5.4

$ npm outdated --prefix ~/.openclaw/npm --json
@openclaw/codex: current 2026.5.4, wanted 2026.5.4, latest 2026.5.7

PreToolUse failure:
Command blocked by PreToolUse hook: Native hook relay unavailable.

Gateway logs:
native hook relay expired
native hook relay not found


Stale `@openclaw/[email protected]` registers the native hook relay without a longer TTL, so it falls back to the OpenClaw default 30-minute relay TTL. `@openclaw/[email protected]` appears to include the intended fix pattern via `resolveCodexNativeHookRelayTtlMs(...)`.
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

A managed default-line npm plugin can remain stale after openclaw update; OpenClaw core reached 2026.5.7 while the loaded @openclaw/codex harness stayed at 2026.5.4, causing native hook relay expiry during long turns.

Steps to reproduce

  1. Use a package/global OpenClaw install with the Codex plugin installed as a managed npm plugin (openclaw plugins inspect codex shows source under ~/.openclaw/npm/node_modules/@openclaw/codex).
  2. Update OpenClaw core to 2026.5.7 on the stable channel.
  3. Run openclaw --version and openclaw plugins inspect codex.
  4. Check ~/.openclaw/npm/package.json, npm outdated --prefix ~/.openclaw/npm --json, and openclaw plugins update codex --dry-run.
  5. Start a long Codex-backed OpenClaw turn that continues using native shell tools after roughly 30 minutes.

Expected behavior

Managed default-line npm plugins such as @openclaw/codex should either sync to the matching stable line during openclaw update, or openclaw update/doctor should clearly warn that a managed plugin is stale relative to the core version and needs a plugin update. Floating/default-line plugin installs should not be pinned in the managed npm root so npm treats the old version as wanted.

Actual behavior

OpenClaw core was 2026.5.7, but the loaded Codex harness remained @openclaw/[email protected] from ~/.openclaw/npm/node_modules/@openclaw/codex/dist/index.js. The managed npm root pinned "@openclaw/codex": "2026.5.4", so npm outdated --prefix ~/.openclaw/npm --json reported current: 2026.5.4, wanted: 2026.5.4, latest: 2026.5.7. Long Codex turns then failed with Command blocked by PreToolUse hook: Native hook relay unavailable; gateway logs first showed native hook relay expired and then native hook relay not found.

OpenClaw version

2026.5.7 (eeef486)

Operating system

macOS 26.4.1

Install method

npm global / package install

Model

openai/gpt-5.5

Provider / routing chain

OpenClaw agentRuntime=codex -> @openclaw/codex app-server harness -> OpenAI/Codex

Additional provider/model setup details

Observed managed plugin state:

  • openclaw plugins inspect codex reports Version 2026.5.4, Source ~/.openclaw/npm/node_modules/@openclaw/codex/dist/index.js, Spec @openclaw/codex, Recorded version 2026.5.4.
  • Managed npm root has dependency "@openclaw/codex": "2026.5.4".
  • plugins/installs.json records the install as floating/default-line: spec: @openclaw/codex, exactVersion: false, pinState: floating-without-integrity.

Logs, screenshots, and evidence

Relevant redacted evidence:


$ openclaw --version
OpenClaw 2026.5.7 (eeef486)

$ node -p "require('~/.openclaw/npm/node_modules/@openclaw/codex/package.json').version"
2026.5.4

$ npm outdated --prefix ~/.openclaw/npm --json
@openclaw/codex: current 2026.5.4, wanted 2026.5.4, latest 2026.5.7

PreToolUse failure:
Command blocked by PreToolUse hook: Native hook relay unavailable.

Gateway logs:
native hook relay expired
native hook relay not found


Stale `@openclaw/[email protected]` registers the native hook relay without a longer TTL, so it falls back to the OpenClaw default 30-minute relay TTL. `@openclaw/[email protected]` appears to include the intended fix pattern via `resolveCodexNativeHookRelayTtlMs(...)`.

Impact and severity

Affected: OpenClaw users running the managed Codex plugin when the managed npm plugin remains behind the updated OpenClaw core.

Severity: High for long Codex-backed turns; once the relay expires, every native shell/tool call is blocked until recovery.

Frequency observed: Reproduced in multiple long turns that crossed the default relay TTL.

Consequence: Long-running coding/verification work loses shell access mid-turn, leading to incomplete verification and unnecessary gateway restarts/workarounds.

Additional information

This looks like managed plugin update metadata drift / stale plugin sync after core updates, with a concrete runtime consequence in Codex native hook relay TTL handling.

A temporary local workaround extended the native hook relay TTL inside the installed @openclaw/[email protected] bundle. That workaround is intentionally local and should be replaced by a normal package update. The report is mainly about making openclaw update, openclaw doctor, or openclaw plugins update surface and resolve this mismatch safely.

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

Managed default-line npm plugins such as @openclaw/codex should either sync to the matching stable line during openclaw update, or openclaw update/doctor should clearly warn that a managed plugin is stale relative to the core version and needs a plugin update. Floating/default-line plugin installs should not be pinned in the managed npm root so npm treats the old version as wanted.

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]: Managed @openclaw/codex plugin can remain stale after core update [1 comments, 2 participants]