Skip to content

fix(infer): stop model run after accepted interrupt - #192818

Closed
wangmiao0668000666 wants to merge 2 commits into
openclaw:mainfrom
wangmiao0668000666:fix/infer-model-run-interrupt
Closed

wangmiao0668000666 wants to merge 2 commits into
openclaw:mainfrom
wangmiao0668000666:fix/infer-model-run-interrupt

Conversation

@wangmiao0668000666

@wangmiao0668000666 wangmiao0668000666 commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes: openclaw infer model run keeps waiting on the in-flight provider/Gateway request after Ctrl+C is accepted. The CLI prints Command interrupted by SIGINT. Waiting for cleanup before exiting. and the cleanup drain then sits on a generation that has no cancellation wired in, so the shipped entry's signal-exit grace expires and the running command is terminated by escalation instead of finishing its own drain.

User Impact

User impact: interrupting a long model run now cancels the request immediately (the local HTTP call is aborted, the Gateway RPC is disconnected) and the command exits cleanly with status 130 in about 0.2 s instead of being force-ended roughly two seconds in with the drain never completed. Uninterrupted runs are unchanged.

Why This Change Was Made

runCapabilityCommand already acquires the CLI work-scope signal and suppresses output for accepted interrupts, but model run never handed that signal to the work itself: the local completion options and the callGateway call both omitted it, so nothing cancelled the in-flight request. This change passes the existing signal to both, mirroring the image (#191176), TTS (#191635) and web (#191628) interrupt fixes in the same infer family — those siblings already document their interrupt contract in docs/cli/infer.md; model run did not. No new timeout, owner, configuration or API is introduced.

Evidence

Base e25fdc28da1cdfa64a047c64612319a4dbd5d9fe → Candidate 5aa763166e4a2dc42c26e1d913dd3ed5c12cc0bb (CI retrigger head 1d431a2291c is an empty commit; the diff is unchanged).

Environment: NewStartOS V4.4.2 (Linux x86_64), Node v24.22.1, built CLI via node --import ./scripts/tsx.mjs scripts/build-all.mts, secretless local proof: a slow Responses-API HTTP fixture on 127.0.0.1:18973 (45 deltas × 350 ms; fixture and drivers live in .artifacts/proof/ and are not part of the PR) with an isolated OPENCLAW_STATE_DIR. Two transports go through the real built entry: --local (the fixture acts as the provider) and --gateway (an isolated foreground openclaw gateway run bound to loopback port 18974 from the same isolated state, shared-secret lane). Each SIGINT run waits for the fixture's request log, delivers SIGINT ~1.5 s later, and measures signal→exit latency; control runs deliver no signal. Every transcript below is the verbatim driver capture (exit status, stdout, stderr, fixture events) reproduced from the per-run JSON — the transcripts contain no keys and only loopback fixture endpoints.

Unit red-on-base (final tree of both revisions, node scripts/run-vitest.mjs run src/cli/capability-cli.test.ts):

Test Base Candidate
prepares local model content and instructions (ChatGPT API: false) FAIL PASS
authorizes Gateway model override Anthropic/CLAUDE-HAIKU-4-5 and preserves profile refs FAIL PASS
authorizes Gateway model override Anthropic/CLAUDE-OPUS-4-7@work and preserves profile refs FAIL PASS
whole file (104 tests) 3 failed | 101 passed 104 passed, 143 s

The red assertions are the new signal-identity checks (local completion options.signal, callGateway signal), each inside an AsyncWorkScope.track run exactly as the image-interrupt precedent does.

Shipped CLI — --local:

Case Base Candidate
control (n=2) exit 0, 25.3 s / 24.4 s, full tok1…tok45 exit 0, 24.8 s / 24.6 s, full tok1…tok45
SIGINT mid-generation (n=2) 2060 / 2055 ms → terminated before a clean exit (no cancellation; the fixture aborts only when the socket dies at +3618 ms, delta 11) 197 / 196 ms → clean exit 130; the fixture aborts right after SIGINT (+1519 / +1516 ms, delta 5) — the request itself is cancelled
stderr Command interrupted by SIGINT. Waiting for cleanup before exiting. same

Shipped CLI — --gateway:

Case Base Candidate
control (n=1) exit 0, 32.1 s, full tok1…tok45 exit 0, 28.5 s, full tok1…tok45
SIGINT mid-generation (n=2) 2054 / 2040 ms → SIGKILL, never a clean exit; no abort event in the caller's run window 138 / 135 ms → clean exit 130; the Gateway RPC is torn down with the invocation, no late stdout
stderr same interruption line same

Raw run transcripts (verbatim captures, one block per run):

base7-sigint — build base e25fdc2, --local, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: base e25fdc28da1
fixture REQ: 1793800203994 REQ POST /v1/responses stream=true
boot: 9 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 2060 ms after SIGINT
outcome: terminated by signal before a clean exit (driver issued no kill; signal name not recorded in this capture)
total wall time: 13640 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  +  3618 ms  ABORT /v1/responses after_chunks=11

base8-sigint — build base e25fdc2, --local, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: base e25fdc28da1
fixture REQ: 1793805664621 REQ POST /v1/responses stream=true
boot: 6 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 2055 ms after SIGINT
outcome: terminated by signal SIGKILL
total wall time: 12511 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  +  2836 ms  COMPLETE /v1/responses chunks=45
  +  2837 ms  END /v1/responses why=complete chunks=45
  +  2837 ms  ENDCLOSE /v1/responses after_chunks=45
  +  3619 ms  ABORT /v1/responses after_chunks=11

Note on base8-sigint fixture window: the COMPLETE/END/ENDCLOSE lines at +2836 ms belong to the previous run in the sequence (basegw-sigint-2, fixture REQ 1793805652034, +15423 ms = 1793805667457) — that gateway-side stream finishing after its own caller had already exited. This run’s own event is the ABORT … after_chunks=11 at +3619 ms (socket death at SIGKILL).

basegw-sigint-1 — build base e25fdc2, --gateway, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: base e25fdc28da1
fixture REQ: 1793805561288 REQ POST /v1/responses stream=true
boot: 5 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 2054 ms after SIGINT
outcome: terminated by signal SIGKILL
total wall time: 10500 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true

basegw-sigint-2 — build base e25fdc2, --gateway, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: base e25fdc28da1
fixture REQ: 1793805652034 REQ POST /v1/responses stream=true
boot: 6 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 2040 ms after SIGINT
outcome: terminated by signal SIGKILL
total wall time: 10379 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true

head-sigint-1 — build head 5aa7631, --local, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: head 5aa763166e4
fixture REQ: 1793799171379 REQ POST /v1/responses stream=true
boot: 5 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 197 ms after SIGINT
outcome: exit code 130
total wall time: 10752 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  +  1519 ms  ABORT /v1/responses after_chunks=5

head-sigint-2 — build head 5aa7631, --local, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: head 5aa763166e4
fixture REQ: 1793799181917 REQ POST /v1/responses stream=true
boot: 6 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 196 ms after SIGINT
outcome: exit code 130
total wall time: 10342 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  +  1516 ms  ABORT /v1/responses after_chunks=5

headgw-sigint-1 — build head 5aa7631, --gateway, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: head 5aa763166e4
fixture REQ: 1793807101197 REQ POST /v1/responses stream=true
boot: 6 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 138 ms after SIGINT
outcome: exit code 130
total wall time: 8782 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true

headgw-sigint-2 — build head 5aa7631, --gateway, mode=sigint

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: head 5aa763166e4
fixture REQ: 1793807109011 REQ POST /v1/responses stream=true
boot: 6 ms
SIGINT: delivered ~1.5 s after fixture REQ; exit 135 ms after SIGINT
outcome: exit code 130
total wall time: 7775 ms
stderr: "Command interrupted by SIGINT. Waiting for cleanup before exiting.\n"
stdout: ""  <-- empty: no late output after SIGINT
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true

base8-control — build base e25fdc2, --local, mode=control

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: base e25fdc28da1
fixture REQ: 1793805677155 REQ POST /v1/responses stream=true
boot: 6 ms
outcome: exit code 0
total wall time: 24375 ms
stderr: ""
stdout: "model.run via local\nprovider: openai\nmodel: gpt-5.5\noutputs: 1\ntok1 tok2 tok3 tok4 tok5 tok6 tok7 tok8 tok9 tok10 tok11 tok12 tok13 tok14 tok15 tok16 tok17 tok18 tok19 tok20 tok21 tok22 tok23 tok24 tok25 tok26 tok27 tok28 tok29 tok30 tok31 tok32 tok33 tok34 tok35 tok36 tok37 tok38 tok39 tok40 tok41 tok42 tok43 tok44 tok45\n"
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  + 15420 ms  COMPLETE /v1/responses chunks=45
  + 15420 ms  END /v1/responses why=complete chunks=45
  + 15421 ms  ENDCLOSE /v1/responses after_chunks=45

basegw-smoke — build base e25fdc2, --gateway, mode=control

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: base e25fdc28da1
fixture REQ: 1793805482138 REQ POST /v1/responses stream=true
boot: 5 ms
outcome: exit code 0
total wall time: 32055 ms
stderr: ""
stdout: "model.run via gateway\nprovider: openai\nmodel: gpt-5.5\noutputs: 1\ntok1 tok2 tok3 tok4 tok5 tok6 tok7 tok8 tok9 tok10 tok11 tok12 tok13 tok14 tok15 tok16 tok17 tok18 tok19 tok20 tok21 tok22 tok23 tok24 tok25 tok26 tok27 tok28 tok29 tok30 tok31 tok32 tok33 tok34 tok35 tok36 tok37 tok38 tok39 tok40 tok41 tok42 tok43 tok44 tok45\n"
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  + 15428 ms  COMPLETE /v1/responses chunks=45
  + 15428 ms  END /v1/responses why=complete chunks=45
  + 15429 ms  ENDCLOSE /v1/responses after_chunks=45

head-control-1 — build head 5aa7631, --local, mode=control

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --local
build: head 5aa763166e4
fixture REQ: 1793799121659 REQ POST /v1/responses stream=true
boot: 6 ms
outcome: exit code 0
total wall time: 24812 ms
stderr: ""
stdout: "model.run via local\nprovider: openai\nmodel: gpt-5.5\noutputs: 1\ntok1 tok2 tok3 tok4 tok5 tok6 tok7 tok8 tok9 tok10 tok11 tok12 tok13 tok14 tok15 tok16 tok17 tok18 tok19 tok20 tok21 tok22 tok23 tok24 tok25 tok26 tok27 tok28 tok29 tok30 tok31 tok32 tok33 tok34 tok35 tok36 tok37 tok38 tok39 tok40 tok41 tok42 tok43 tok44 tok45\n"
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  + 15422 ms  COMPLETE /v1/responses chunks=45
  + 15422 ms  END /v1/responses why=complete chunks=45
  + 15423 ms  ENDCLOSE /v1/responses after_chunks=45

headgw-control — build head 5aa7631, --gateway, mode=control

$ node openclaw.mjs infer model run --model openai/gpt-5.5 --prompt "Count slowly from one." --gateway
build: head 5aa763166e4
fixture REQ: 1793807023090 REQ POST /v1/responses stream=true
boot: 7 ms
outcome: exit code 0
total wall time: 28481 ms
stderr: ""
stdout: "model.run via gateway\nprovider: openai\nmodel: gpt-5.5\noutputs: 1\ntok1 tok2 tok3 tok4 tok5 tok6 tok7 tok8 tok9 tok10 tok11 tok12 tok13 tok14 tok15 tok16 tok17 tok18 tok19 tok20 tok21 tok22 tok23 tok24 tok25 tok26 tok27 tok28 tok29 tok30 tok31 tok32 tok33 tok34 tok35 tok36 tok37 tok38 tok39 tok40 tok41 tok42 tok43 tok44 tok45\n"
fixture events (captured during this run's process window):
  +     0 ms  REQ POST /v1/responses stream=true
  + 15430 ms  COMPLETE /v1/responses chunks=45
  + 15430 ms  END /v1/responses why=complete chunks=45
  + 15431 ms  ENDCLOSE /v1/responses after_chunks=45

Static checks: node scripts/run-format.mts --check clean; pnpm exec oxlint <both src files> 0 warnings/errors; check-line-cap-ratchet OK (no growth in the over-cap test file — the wrapper compaction nets the file −1 line); check-max-lines-ratchet OK; check-test-lines-ratchet OK (6,453,895 / ceiling 6,453,925, slack 30).

Whole-PR delta: production model.ts +9/−1 (net +8), tests +9/−10 (net −1), docs +1.

Notes and negative statements:

  • Gateway-side ownership is unchanged in both revisions: after the caller disconnects, the gateway-side agent run keeps streaming to completion (fixture completes at REQ+15.4 s on base and candidate alike). This PR repairs the caller — cancellation of the invocation's in-flight request/RPC plus a prompt accepted-interrupt exit (130) — it does not change gateway run-disconnect policy, which is out of scope here.
  • Base red exits are terminated by the shipped compile-cache launcher's signal-exit escalation at ~2 s (the terminating signal is recorded as SIGKILL in the gateway-lane twin runs and in base8-sigint); its drain is static-verified to await the command action (signal-exit-barrier.ts), which is what the new signal now releases. In base --local the fixture abort happens only at that kill (delta 11); on the candidate it happens right after SIGINT (delta 5).
  • No Windows or macOS run; no claim about provider transports that ignore mid-stream abort (pre-dispatch throwIfAborted and the post-run output suppression still apply).
  • Exact-head CI: at review time the four failing lanes (check-test-types, check-test-types-core-4, check-lint-core-4, checks-fast-baseline-ratchets) failed on upstream main's own defects — the duplicate closeSessionTitle (TS1117) in ui/src/i18n/locales/en-terminal.ts plus mock-export annotations in upstream-touched UI tests — none of this PR's changed files are implicated, and the local equivalents for the touched files (format, oxlint, line-cap/max-lines/test-lines ratchets, prod types) pass. Upstream has since fixed the duplicate key (single occurrence on current main); CI was retriggered on head 1d431a2291c.

Focused Checks and Simplification

  • One owner, one signal: the existing getAsyncWorkSignal() from the CLI work scope; no second cancellation mechanism, no timeout added, no schema/config/API change. Four production lines of behavior (signal into local completion options, signal into callGateway, one acquisition, one import), the rest is import re-formatting.
  • Tests reuse the existing AsyncWorkScope.track pattern from capability-cli.image-options.test.ts; assertions were folded into the existing local/Gateway cases so the over-cap capability-cli.test.ts does not grow (line-cap gate) and test-lines net is −1.
  • Collision check (1,000-PR file map + per-file GitHub search): same-file holders #171681 (model.ts L224–239, test L821–941) and #191080 (model.ts L92–137, test L51–70/302–343/1814–1873) have hunks disjoint from this PR's edits (model.ts import/action/options/gateway-call; test 787/938); docs/cli/infer.md neighbors #190279 (Web section), #190287 (Audio), #190209 (Embedding) are section-disjoint from this Model-section bullet. git merge-tree HEAD origin/main (main at 7aa96ecca2f) reports no conflicts.

Compatibility and Merge Risk

Two-way door: reverting restores the previous wait-out behavior with no migrations or persisted-state changes. Blast radius is infer model run's own cancellation wiring: local completion requests, the Gateway model-run call, and the interrupt exit path for that command. Unchanged neighboring behavior: uninterrupted runs (proven ×3), output suppression for accepted interrupts (pre-existing runCapabilityCommand contract), other infer subcommands (their own signal wiring untouched), and the exit codes for ordinary failures.

@clawsweeper

clawsweeper Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

Pull request received. I will update this pull request when review starts.

ClawSweeper review complete

ClawSweeper finished reviewing this revision. The review result is being finalized.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation cli CLI command changes size: XS labels Nov 4, 2026
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. P2 Normal backlog priority with limited blast radius. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Nov 4, 2026
@clawsweeper

clawsweeper Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

Pass the CLI invocation’s cancellation signal to local model completion and Gateway model-run requests.

Example: Press Ctrl+C during openclaw infer model run --local against a slow streaming provider.

  • Before: The command waits until signal-exit escalation terminates it.
  • After: The HTTP request aborts and the CLI exits cleanly with status 130 without publishing output.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A useful, focused repair with sufficient shipped-entry proof; weak mock assertions keep the patch below A, and pending CI is not a correctness finding.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (terminal): The updated full body supplies Linux built-entry traces against a slow real HTTP fixture for local completion and an isolated foreground Gateway: candidate SIGINT runs exit 130 without late stdout, local requests abort, and uninterrupted controls complete. Gateway evidence proves caller RPC teardown, not cancellation of server-side generation, which the body explicitly excludes. The reviewed retrigger head is production-identical to the exercised candidate.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Ctrl+C is accepted, but an in-flight model request keeps the CLI waiting until forced termination.
Reason: This restores the established inference interruption contract using existing transport APIs and preserves normal execution.

Merge readiness

✅ Ready for maintainer review

Keep this PR: current main still omits cancellation wiring for model runs, and the focused patch fixes it without changing cleanup ownership. No introduced correctness or security defect was found; exact-head CI remains pending.

Priority: P2
Reviewed head: 1d431a2291cbf4687ae9a565e3c5ba8d1f88831b

Before merge

None.

Findings

None.

Tests

  • Low-value test src/cli/capability-cli.test.ts: The added AbortSignal-presence assertions only inspect mocked call shapes; remove these additions or replace them with a regression that closes the invocation scope and observes cancellation at both execution boundaries.
Agent review details

How this fits together

The inference CLI prepares model input and routes it to local completion or a Gateway RPC; the existing work scope owns interruption, cleanup, and output suppression.

flowchart TD
  A[CLI model run] --> B[Invocation work scope]
  B --> C[Local completion]
  B --> D[Gateway RPC client]
  C --> E[Provider transport]
  D --> F[Gateway agent run]
  B --> G[Cleanup and exit]
Loading

Technical review

Best possible solution:

Forward the existing invocation signal to both execution transports while retaining the current cleanup and output owners.

Do we have a high-confidence way to reproduce the issue?

Current-main source shows the missing signal at both call sites, and contributor-supplied built-CLI traces demonstrate the failure on the base; no target code was executed during this review.

Is this the best way to solve the issue?

The production change is the smallest complete repair: it connects existing cancellation contracts without adding state, timeouts, wrappers, or a competing owner.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 7c2ff8f775ac.

Provenance checked

  • Local prepared-model cleanup keeps the original intent (0fadfb4: Retain the prepared generation through completion interpretation and callback or cancellation drainage.)
  • Model-run request ownership keeps the original intent (78c6294: Keep private request phases with their existing operation owners while preserving lifecycle and authorization contracts.)
  • Consolidated model CLI tests keeps the original intent (86310c8: Reduce overlapping setup while retaining distinct cancellation and lifecycle regressions.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 78c6294 adds src/cli/capability-cli/model.ts:264 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 78c6294f36ec; files: src/cli/capability-cli/model.ts)
  • Tak Hoffman: Raw commit ac66939 adds docs/cli/infer.md:2 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: medium; commits: ac6693986bbf; files: docs/cli/infer.md)

PR surface

Source +7, Tests -1, Docs +1. Total +7 across 3 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 1 8 1 +7
Tests 1 9 10 -1
Docs 1 1 0 +1
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 18 11 +7

Labels

Label changes:

  • add proof: sufficient: Contributor real behavior proof is sufficient.
  • add rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • remove rating: 🦪 silver shellfish: Current PR rating is rating: 🐚 platinum hermit, so this older rating label is no longer current.
  • remove status: 📣 needs proof: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P2: A bounded CLI cancellation defect causes interrupted inference commands to require forced termination.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🦞 diamond lobster and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

Rank-up moves

Optional improvements that raise the rating; they are not merge blockers.

  • Replace the signal-presence mock assertions with an observable cancellation regression, removing the redundant assertions.

Rating scale

6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior.

Workflow

ClawSweeper edits this one comment on every review. Comment @clawsweeper re-review for a fresh review only. Repair and merge execution lanes are retired.

History

Review history (1 earlier review cycle)
  • reviewed 2026-11-04T14:40:09.834Z sha 5aa7631 :: needs real behavior proof before merge. :: none

Reviewed November 4, 2026, 11:11 AM ET / 16:11 UTC (Revision 2).

@wangmiao0668000666

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. labels Nov 4, 2026
@obviyus

obviyus commented Nov 4, 2026

Copy link
Copy Markdown
Collaborator

Thank you — your model-run fix commit is preserved with authorship in #192896, together with the embedding sibling. The sweep includes real controlling-PTY Ctrl+C proof on main and candidate twice per path, uninterrupted controls, and consolidated cancellation regressions with net-negative test lines. Original PRs remain open until the sweep lands.

obviyus added a commit that referenced this pull request Nov 4, 2026
fix(infer): stop model and embedding runs on Ctrl+C

`openclaw infer model run` (local and Gateway) and the embedding command did not pass the existing work-scope abort signal, so Ctrl+C did not stop the request. The CLI hung until it was force-killed about 2 seconds later. The commands now pass the signal: the local or embedding provider request closes, the Gateway caller RPC closes, and the CLI exits with 130. Gateway-side generation keeps its existing behavior. Uninterrupted runs are unchanged.

Sweep of #192818 and #192846; both contributor commits are kept.

Evidence: built CLI with a real PTY and SIGINT, against slow local provider and Gateway fixtures, twice per ref for each path. Main reached SIGKILL after 2.05 to 2.27 s; with this change the CLI exited with 130 in 30 to 56 ms, and the provider HTTP request or Gateway RPC closed within 3 ms. All uninterrupted controls pass. Details: #192896 (comment).

Thanks @wangmiao0668000666.

Co-authored-by: wangmiao0668000666 <[email protected]>
Co-authored-by: Ayaan Zaidi <[email protected]>
@obviyus

obviyus commented Nov 4, 2026

Copy link
Copy Markdown
Collaborator

Thanks @wangmiao0668000666. Your commit landed as part of sweep #192896 (958ae1a), together with the related interrupt fix. Closing this one as included.

@obviyus obviyus closed this Nov 4, 2026
@wangmiao0668000666
wangmiao0668000666 deleted the fix/infer-model-run-interrupt branch November 4, 2026 22:52
github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 5, 2026
…w#192896)

fix(infer): stop model and embedding runs on Ctrl+C

`openclaw infer model run` (local and Gateway) and the embedding command did not pass the existing work-scope abort signal, so Ctrl+C did not stop the request. The CLI hung until it was force-killed about 2 seconds later. The commands now pass the signal: the local or embedding provider request closes, the Gateway caller RPC closes, and the CLI exits with 130. Gateway-side generation keeps its existing behavior. Uninterrupted runs are unchanged.

Sweep of openclaw#192818 and openclaw#192846; both contributor commits are kept.

Evidence: built CLI with a real PTY and SIGINT, against slow local provider and Gateway fixtures, twice per ref for each path. Main reached SIGKILL after 2.05 to 2.27 s; with this change the CLI exited with 130 in 30 to 56 ms, and the provider HTTP request or Gateway RPC closed within 3 ms. All uninterrupted controls pass. Details: openclaw#192896 (comment).

Thanks @wangmiao0668000666.

Co-authored-by: wangmiao0668000666 <[email protected]>
Co-authored-by: Ayaan Zaidi <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli CLI command changes docs Improvements or additions to documentation P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. size: XS status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants