Repository navigation
Description
Bug type
Behavior bug (incorrect output/state without crash)
Beta release blocker
No
Summary
Summary
chat.abort currently cannot stop active runs started via the public
agent RPC.
It only aborts runs tracked in chatAbortControllers, which are created by
chat.send.
This makes it impossible for external runtimes that integrate through
agent to implement a proper "Pause/Stop current session" using public
Gateway RPCs.
Relevant implementation details
chat.abortcheckscontext.chatAbortControllerschat.sendregisters runs intochatAbortControllersagentdoes not register its runs intochatAbortControllers/stopfull semantics live in command handling, not inchat.abort
Why this matters
External apps may intentionally use agent instead of chat.send because
they need:
- raw agent lifecycle/tool/approval events
- per-run system prompt injection
- host-managed conversation/run state
Right now those apps cannot implement a proper public "stop current run/
session" without depending on OpenClaw internal modules.
Suggested direction
Preferred:
- expose a stable public
sessions.stopRPC equivalent to/stop
Alternative:
- extend public abort APIs so they can stop active
agentsession runs as
well
Steps to reproduce
- Start a long-running session via the public
agentRPC:- method:
agent - params:
{ sessionKey, message, idempotencyKey, ... }
- method:
- While the run is still streaming, call:
chat.abort({ sessionKey, runId })- or
chat.abort({ sessionKey })
- Gateway returns:
{ ok: true, aborted: false, runIds: [] }
- The run continues.
Expected behavior
One of the following should be true:
chat.abort/sessions.abortshould also be able to interrupt active
session runs started byagent, or- OpenClaw should expose a public session-level stop API, e.g.
sessions.stop, with semantics equivalent to/stop:- clear queued followups / lane queue
- stop active embedded run
- stop descendant subagents
- trigger stop command hooks
Actual behavior
chat.abort only checks chatAbortControllers, which are populated by
chat.send.
agent runs are not registered there, so abort returns aborted:false even
when the run is still active.
OpenClaw version
2026.4.9
Operating system
macOS 15.4
Install method
npm global
Model
minimax
Provider / routing chain
openclaw -> minimax
Additional provider/model setup details
No response
Logs, screenshots, and evidence
Impact and severity
No response
Additional information
No response
Metadata
Metadata
Assignees
Labels
Type
Fields
Priority
Activity
edvisage commentedon Apr 24, 2026
This is worth prioritizing beyond a standard bug fix. An abort mechanism that only works on chat.send runs but not active agent runs means humans cannot reliably interrupt autonomous agent behavior once it starts. That's a human oversight gap — the assumption that you can stop an agent at any point is foundational to safe deployment. Any agent running with tool access, file permissions, or external API calls that cannot be reliably aborted mid-run is an uncontrolled process. The fix needs to guarantee interruption at the execution boundary, not just at the communication layer, otherwise abort becomes a false sense of control rather than an actual safety mechanism.
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs
fix(gateway): allow chat.abort to stop agent RPC runs