Stop heartbeat tool turns from asking for HEARTBEAT_OK#76338
Stop heartbeat tool turns from asking for HEARTBEAT_OK#76338pashpashpash merged 2 commits intomainfrom
Conversation
|
Codex review: needs maintainer review before merge. Summary Reproducibility: yes. by source inspection. Current main combines the default Next step before merge Security Review detailsBest possible solution: Land the heartbeat prompt split once maintainers approve the runtime fallback policy change, or split the fallback removal into a separate policy PR and land the narrower heartbeat fix first. Do we have a high-confidence way to reproduce the issue? Yes, by source inspection. Current main combines the default Is this the best way to solve the issue? Unclear as a product decision. The heartbeat prompt split is the narrow fix, but retiring the public fallback config/env surface is a broader compatibility change that should be explicitly accepted by maintainers. What I checked:
Likely related people:
Remaining risk / open question:
Codex review notes: model gpt-5.5, reasoning high; reviewed against dda2cf4e73b3. |
2ec5f57 to
451c1ff
Compare
451c1ff to
78ed1be
Compare
78ed1be to
2875b4a
Compare
2875b4a to
f7a4803
Compare
8cb5cb8 to
ca20f88
Compare
|
ClawSweeper's fallback-compatibility finding is intentionally not being applied here. Pash explicitly asked in this PR to remove the silent runtime fallback and make explicit runtime selection fail honestly. The current branch now removes the So the behavior is now deliberately:
Local validation passed after rebasing on current main, and exact-head CI is green for |
* fix heartbeat tool prompt sentinel * fix: remove agent runtime fallback config
* fix heartbeat tool prompt sentinel * fix: remove agent runtime fallback config
Heartbeat turns now have two reply contracts. The legacy text path still needs HEARTBEAT_OK so OpenClaw can treat a quiet heartbeat as no user-visible reply, but Codex runtime/message-tool turns have the structured heartbeat_respond tool where silence is represented with notify=false.
Before this change, the Codex happy path could receive both instructions in the same heartbeat turn: use the heartbeat tool, and also reply HEARTBEAT_OK when nothing needs attention. That is exactly the kind of mixed contract that makes the model second-guess the tool path.
This keeps HEARTBEAT_OK for explicit automatic reply mode, but rewrites heartbeat prompts for message-tool and Codex harness sessions so they point at heartbeat_respond instead. The happy-path heartbeat snapshot now shows the structured tool contract without the old text sentinel.
While chasing that cleanup, we also removed the old runtime fallback surface instead of preserving a silent downgrade path. Explicit runtime selection is now honest: asking for Codex, Claude CLI, or another plugin runtime either selects that runtime or fails clearly. The remaining compatibility behavior is
agentRuntime.id: "auto", where OpenClaw can still use PI when no plugin harness claims a run. LegacyagentRuntime.fallbackconfig is cleaned up through doctor, and the schema, generated config metadata, status metadata, docs, and tests now match that contract.