Skip to content

fix(cli): cancel interrupted tts gateway RPCs - #195206

Merged
obviyus merged 5 commits into
openclaw:mainfrom
shuisadev:fix/tts-gateway-rpc-ambient-cancel-367
Nov 8, 2026
Merged

obviyus merged 5 commits into
openclaw:mainfrom
shuisadev:fix/tts-gateway-rpc-ambient-cancel-367

Conversation

@shuisadev

@shuisadev shuisadev commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

openclaw capability tts Gateway commands ignored Ctrl+C. callGateway only attaches an abort handler when it receives a signal, and these call sites passed none, so an interrupted command left its RPC open until the 30s timeoutMs expired — the caller simply sat there until the launcher's ~2s grace SIGKILLed it:

  • openclaw capability tts status
  • openclaw capability tts providers --gateway
  • openclaw capability tts personas --gateway
  • openclaw capability tts enable|disable|set-provider|set-persona --gateway (one shared runTtsStateMutation call site)

openclaw capability tts convert was already fixed this way in #194128; the other Gateway call sites in the same modules were missed.

Why This Change Was Made

runCapabilityCommand already creates the ambient AsyncWorkScope signal and suppresses output once the invocation is cancelled, so the only missing piece was handing that signal to the Gateway transport. Each site now passes signal: getAsyncWorkSignal(), exactly like runTtsConvert. Local (non-Gateway) paths are untouched: they perform no RPC, only config/prefs file access.

Tests: the existing cancellation table in src/cli/capability-cli.test.ts gains tts status, tts providers, tts personas and tts disable Gateway cases (the image case was compacted so the file does not grow). No new test files and no config/test-lines-allocations entry.

User Impact

Ctrl+C now cancels these commands in ~100 ms instead of hanging until SIGKILL and up to 30 s of RPC timeout, no stale RPC output is printed (only the interrupt notice and the terminal-mode restore), and the terminal is left usable. Uninterrupted runs behave exactly as before. For an interrupted set-provider/enable/disable/set-persona, the client only stops waiting: the Gateway can still finish a write it has already received.

Evidence

Shipped CLI, real Gateway, real PTY, A/B on b32f01abae8 (base) vs fb00ca53b1b (this head). Each lane is its own git worktree + pnpm install --frozen-lockfile + pnpm build:runtime, and dist/build-info.json reports the lane commit. A passive WebSocket observer relays the upgrade handshake and every frame unchanged, withholding only the armed res frame; the CLI runs under pty.fork and receives a real VINTR once the observer sees its request reach the Gateway.

boundary lane exit ^C→exit ^C→socket close Gateway served
tts.status base -9 (SIGKILL) 2039.9 ms 2034.9 ms yes
tts.status head 130 97.2 ms 3.7 ms yes
tts.providers base -9 (SIGKILL) 2039.1 ms 2033.6 ms yes
tts.providers head 130 97.4 ms 5.3 ms yes
tts.personas base -9 (SIGKILL) 2046.2 ms 2039.7 ms yes
tts.personas head 130 106.1 ms 4.7 ms yes
tts.setProvider base -9 (SIGKILL) 2043.6 ms 2036.5 ms yes
tts.setProvider head 130 83.1 ms 5.7 ms yes

Control runs (2500 ms hold, no interrupt) exit 0 in both lanes and print the real Gateway envelope. Base prints Command interrupted by SIGINT. Waiting for cleanup before exiting. and then stays silent until SIGKILL; head prints the same line, restores the terminal, and exits 130.

Cancellation covers the caller's RPC, not the mutation. The signal stops the client from waiting; it does not cancel or roll back the Gateway's write. A write the Gateway has received can still finish after the client exits (the maintainer proof below shows settings/tts.json written in both lanes for an interrupted set-provider).

Maintainer proof on the current head (real Gateway, real PTY, main vs candidate, controls, interrupted set-provider): #195206 (comment)

Unit RED on main with production unchanged (current table):

 × cancels pending tts status execution
 × cancels pending tts providers execution
 × cancels pending tts personas execution
 × cancels pending tts disable execution
      Tests  4 failed | 7 passed | 107 skipped (118)

GREEN with the fix: src/cli/capability-cli.test.ts 118/118.

@clawsweeper

clawsweeper Bot commented Nov 8, 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 cli CLI command changes size: S labels Nov 8, 2026
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. P2 Normal backlog priority with limited blast radius. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. 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. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 8, 2026
@clawsweeper

clawsweeper Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: needs maintainer review before merge.

What this changes

Forward the invocation’s abort signal to the remaining TTS Gateway RPC calls.

Example: Press Ctrl+C while openclaw capability tts status --json awaits a delayed Gateway response.

  • Before: The client remains pending until the launcher force-kills it.
  • After: The client closes its connection promptly and exits 130 without printing a late result.

Review scores

Measure Result What it means
Overall readiness 🦞 diamond lobster (5/6) Focused repair with shipped-entry-point proof, useful regression coverage, and no open findings.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (terminal): Contributor and obviyus traces exercise built CLI commands against real Gateways through delayed WebSocket replies and actual PTY Ctrl+C, showing prompt client closure and exit 130, unchanged controls, and retained accepted writes; later changes affect tests only.
Patch quality 🦞 diamond lobster (5/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Ctrl+C leaves several TTS Gateway commands waiting until forced termination.
Reason: This completes an established interruption contract with minimal production changes and supplied real-runtime verification.

Merge readiness

✅ Ready for maintainer review

Keep open: this PR completes a useful cancellation repair with convincing shipped-CLI proof and no identified defects; exact-head CI remains pending.

Priority: P2
Reviewed head: 372951911bb402f19a83b1333d6fd1c1720910cb

Before merge

None.

Findings

None.

Agent review details

How this fits together

TTS command handlers send RPCs through callGateway; the invocation owns client cancellation, while the Gateway retains ownership of accepted preference writes.

flowchart LR
  A[CLI invocation] --> B[TTS command handlers]
  A --> C[AsyncWorkScope signal]
  C --> D[callGateway transport]
  B --> D
  D --> E[Gateway TTS handlers]
  E --> F[TTS preference writer]
Loading

Technical review

Best possible solution:

Merge the existing signal-forwarding repair once the normal exact-head checks complete successfully.

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

Current-main call sites and transport cancellation logic establish the failure path, corroborated by supplied main-versus-candidate Gateway/PTY traces; this review executed no target code.

Is this the best way to solve the issue?

The smallest complete fix is to pass the existing invocation signal at all four missing RPC boundaries, preserving output suppression and Gateway write ownership.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning medium; reviewed against 21e6fd7ee3e1.

Provenance checked

  • TTS Gateway RPC ownership keeps the original intent (9c065c8: The domain split preserved existing command behavior; it does not establish why signals were originally omitted.)
  • Lazy TTS command registration keeps the original intent (c425798: Execution runtimes were deferred until actions; the added scope accessor preserves deferred Gateway imports.)
  • Existing cancellation test table keeps the original intent (e43ec1e: Image interruption coverage extended the shared cancellation table; this PR retains those cases and adds distinct missing TTS boundaries.)

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

Likely related people:

  • Peter Steinberger: Raw commit 9c065c8 adds src/cli/capability-cli/tts-runtime.ts:422 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 9c065c895e78; files: src/cli/capability-cli/tts-runtime.ts)

PR surface

Source +5, Tests -4. Total +1 across 3 files. Added test files: 0.

View PR surface stats
Area Files Added Removed Net
Source 2 5 0 +5
Tests 1 9 13 -4
Docs 0 0 0 0
Config 0 0 0 0
Generated 0 0 0 0
Other 0 0 0 0
Total 3 14 13 +1

Preflight source

Source unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: Interrupted TTS administration commands wait for forced termination; the defect has limited scope and does not change accepted Gateway writes.
  • rating: 🦞 diamond lobster: Overall readiness is 🦞 diamond lobster; proof is 🦞 diamond lobster and patch quality is 🦞 diamond lobster.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR.
  • proof: sufficient: Contributor real behavior proof is sufficient.

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 (4 earlier review cycles)
  • reviewed 2026-11-08T12:26:09.116Z sha 6f077e7ab16da7ab876c9b0c10d867432a379afd :: needs real behavior proof before merge. :: [P3] Add a scoped allocation for the net regression growth
  • reviewed 2026-11-08T14:42:35.494Z sha fb00ca5 :: needs changes before merge. :: [P3] Limit mutation cancellation claims to the caller RPC
  • reviewed 2026-11-08T14:52:51.340Z sha fb00ca5 :: needs maintainer review before merge. :: none
  • reviewed 2026-11-08T15:08:15.198Z sha 4e027db :: needs maintainer review before merge. :: none

Reviewed November 8, 2026, 10:19 AM ET / 15:19 UTC (Revision 5).

`capability tts convert` forwarded the invocation's cancel signal, but the other
TTS Gateway paths called `callGateway` without it: `tts status`, `tts providers
--gateway`, `tts personas --gateway`, and the Gateway branches of `tts enable`,
`disable`, `set-provider`, and `set-persona`. `callGateway` only wires an abort
handler when a signal is passed, so Ctrl+C left those RPCs open until the 30s
timeout.

Pass the existing ambient signal (`getAsyncWorkSignal()`) to every remaining TTS
Gateway call. No new plumbing or behavior for uninterrupted runs.
@shuisadev
shuisadev force-pushed the fix/tts-gateway-rpc-ambient-cancel-367 branch from 6f077e7 to fb00ca5 Compare November 8, 2026 14:36
@shuisadev

shuisadev commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor Author

Shipped-CLI interruption proof for the four TTS Gateway RPC boundaries.

Method

Two independent lanes, each its own git worktree of this repository, installed with
pnpm install --frozen-lockfile --offline and built with
OPENCLAW_TSDOWN_MAX_OLD_SPACE_MB=5000 node --import ./scripts/tsx.mjs scripts/build-all.mts runtime:

lane commit dist/build-info.json
base b32f01abae8d34d14b62f1a6dd9fe4f128cd21e2 commit: b32f01abae8d34d14b62f1a6dd9fe4f128cd21e2, buildId: 2026.11.1-b32f01abae8d-2026-11-08T13-04-09.742Z
head fb00ca53b1b08ad28ecd468ef4c5fee87d89c3c5 commit: fb00ca53b1b08ad28ecd468ef4c5fee87d89c3c5, buildId: 2026.11.1-fb00ca53b1b0-2026-11-08T13-20-11.324Z

Node v24.19.0, same binary in both lanes. Each lane starts one real Gateway
(node openclaw.mjs --profile <lane> gateway run --allow-unconfigured, loopback bind, token
auth, Control UI off, isolated HOME/state/workspace) and drives the shipped launcher
node openclaw.mjs --profile <lane> capability tts ... inside a real PTY (pty.fork).

OPENCLAW_GATEWAY_URL points the client at a passive WebSocket front proxy. The proxy
relays the HTTP upgrade handshake and every frame byte-for-byte; for the armed run only it
withholds the single res frame for holdMs, then releases the unchanged payload. It
never synthesizes a response and never rewrites a request, and it timestamps the request
reaching the Gateway and the Gateway's reply so the "Gateway served" column is observed on
the wire rather than asserted.

Per boundary there are two runs: control (2500 ms hold, no interrupt) proves the CLI
still completes and prints a real Gateway envelope; interrupt (60000 ms hold) writes a
real VINTR only after the observer has recorded the request at the Gateway.

Results

signalToExit = VINTR → process exit. callerClose = VINTR → client WebSocket close, as
seen by the observer. req→receipt = Gateway reply latency observed on the wire.

lane boundary case exit signalToExit callerClose bytes after ^C Gateway served req→receipt
base tts.status control 0 – – – yes 230.0 ms
base tts.status interrupt -9 (SIGKILL) 2039.9 ms 2034.9 ms 70 yes 3.3 ms
base tts.providers control 0 – – – yes 3.6 ms
base tts.providers interrupt -9 (SIGKILL) 2039.1 ms 2033.6 ms 70 yes 3.4 ms
base tts.personas control 0 – – – yes 8.4 ms
base tts.personas interrupt -9 (SIGKILL) 2046.2 ms 2039.7 ms 70 yes 2.3 ms
base tts.setProvider control 0 – – – yes 608.5 ms
base tts.setProvider interrupt -9 (SIGKILL) 2043.6 ms 2036.5 ms 70 yes 22.3 ms
head tts.status control 0 – – – yes 48.3 ms
head tts.status interrupt 130 97.2 ms 3.7 ms 131 yes 2.6 ms
head tts.providers control 0 – – – yes 2.6 ms
head tts.providers interrupt 130 97.4 ms 5.3 ms 131 yes 9.2 ms
head tts.personas control 0 – – – yes 13.3 ms
head tts.personas interrupt 130 106.1 ms 4.7 ms 131 yes 2.1 ms
head tts.setProvider control 0 – – – yes 635.5 ms
head tts.setProvider interrupt 130 83.1 ms 5.7 ms 131 reply lost to the cancel –
head tts.setProvider interrupt (fresh state) 130 133.0 ms 45.5 ms 131 reply lost to the cancel –

Base never returns on its own: the launcher's ~2 s interrupt grace expires and the child is
SIGKILLed, which is why the shell reports -9. Head returns the standard interrupted exit
code 130 within ~100 ms and closes the caller socket within ~5 ms of the VINTR.

What the terminal actually printed after ^C

Base (70 bytes, then ~2 s of silence until SIGKILL):

^CCommand interrupted by SIGINT. Waiting for cleanup before exiting.\r\n

Head (131 bytes: same notice, then the terminal-mode restore, then immediate exit):

^CCommand interrupted by SIGINT. Waiting for cleanup before exiting.\r\n
\x1b[0m\x1b[?25h\x1b[?1000l\x1b[?1002l\x1b[?1003l\x1b[?1006l\x1b[?2004l\x1b[<u\x1b[>4;0m

No stale RPC payload is printed in either lane; the difference is that head finishes its
cleanup instead of waiting to be killed.

Uninterrupted control runs returned the real Gateway envelope in both lanes, e.g.:

{ "transport": "gateway", "enabled": false, "auto": "off", "provider": "openai",
  "persona": null, "personas": [], "fallbackProvider": null, "prefsPath": ".../state/settings/tts.json" }

set-provider under interrupt (stated honestly)

A cancelled tts.setProvider is a state mutation, so a third lane ran only that boundary
in a fresh state directory, interrupt first:

  • before the interrupted run: no state/settings/tts.json
  • after the interrupted run: still no state/settings/tts.json
  • after that lane's control run: {"tts":{"provider":"openai"}}

So in that run the cancel landed before the Gateway submitted the write, which is why no
preference file appeared. That is an observation of this run, not a guarantee: the signal
cancels the caller's RPC, not the Gateway's own write work. The mutation handler keeps its
existing owner, updateTtsPrefsAsync -> the retained TTS preference worker pool, whose
pool.run(input, {}) takes no cancellation signal, so a write the handler already submitted
can complete after the caller exits. That writer replaces the file as a whole, so an
interrupt cannot leave a half-written preference file. No rollback is added here: the fix
is limited to ending the caller's RPC.

Reproduce

git worktree add --detach /tmp/wt-base b32f01abae8d34d14b62f1a6dd9fe4f128cd21e2
git worktree add --detach /tmp/wt-cand fb00ca53b1b08ad28ecd468ef4c5fee87d89c3c5
(cd /tmp/wt-base && pnpm install --frozen-lockfile && pnpm build:runtime)
(cd /tmp/wt-cand && pnpm install --frozen-lockfile && pnpm build:runtime)
python3 pty-runs.py --lane base --repo /tmp/wt-base --out runs/base --expect base
python3 pty-runs.py --lane cand --repo /tmp/wt-cand --out runs/cand --expect cand
python3 pty-runs.py --lane cand-sp --repo /tmp/wt-cand --out runs/cand-sp \
  --expect cand --only set-provider --interrupt-first

rpc-hold-proxy.mjs (observer), pty-runs.py (PTY driver), runs/summary.json (all 18
runs), runs/lane-identity.json (commits, dist/build-info.json, source and dist/entry.js
hashes), and the per-run *.pty.log files are attached as a gist: https://gist.github.com/shuisadev/81ee53a7372ed5795be8c2f0b5448399.

Unit-level guard

RED on b32f01abae8 with the production diff reverted and the tests kept:

 × capability cli > cancels pending tts-providers execution
 × capability cli > cancels pending tts-personas execution
 × capability cli > cancels pending tts-status execution
 × capability cli > cancels pending tts-set-provider execution
      Tests  4 failed | 7 passed | 107 skipped (118)

GREEN with the fix: Test Files 4 passed (4), Tests 132 passed (132).

Gates: check-line-cap-ratchet.mjs OK (6 changed source files, no over-cap growth);
check-test-lines-ratchet.mts --base b32f01abae8 --no-merge-base →
Test lines OK: 6577979; ceiling: 6577980; slack: 1 with
config/test-lines-allocations/195206-tts-gateway-cancel.txt recording the +11 net lines;
oxlint and oxfmt --check clean on the 6 changed files; targeted tsc over the
config-cli test shard has no diagnostics in them.

@clawsweeper

clawsweeper Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. status: 📣 needs proof The PR needs real behavior proof before ClawSweeper can clear the contributor ask. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Nov 8, 2026
@clawsweeper

clawsweeper Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 8, 2026
@clawsweeper clawsweeper Bot added rating: 🦞 diamond lobster Very strong PR readiness with only minor maintainer review expected. status: 👀 ready for maintainer look ClawSweeper has no concrete contributor-facing blocker left for this PR. and removed rating: 🐚 platinum hermit Good normal PR readiness with ordinary maintainer review expected. status: ⏳ waiting on author ClawSweeper has contributor-facing work open and is waiting for author action. clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 8, 2026
@obviyus

obviyus commented Nov 8, 2026 •

Copy link
Copy Markdown
Collaborator

Maintainer proof for 372951911bb4 (production code identical to the built candidate; later commits only touch the test file).

Setup: built openclaw from main (1cba5e993bb4) and from this branch merged with that main, each with pnpm install --frozen-lockfile + pnpm build:runtime, in secretless Docker on node 24.22.1. Each lane starts its own real Gateway (openclaw gateway run, token auth, task-owned state). A small local relay sits between the CLI and the Gateway, passes every frame through, and holds tts.* replies for 25 s, like a slow Gateway reply. The CLI runs in a real pseudo-terminal; Ctrl+C (VINTR) is typed 1 s after the relay sees the tts.* request.

command                                        lane  exit         Ctrl+C -> exit  client socket closed  Gateway-side socket
capability tts status --json                   main  SIGKILL (9)  2174 ms         +2172 ms (by kill)    open for 1.5 s+ after Ctrl+C, closed at kill
capability tts status --json                   cand  130          28 ms           +3 ms                 closed +7 ms
capability tts set-provider --provider openai  main  SIGKILL (9)  2273 ms         +2270 ms (by kill)    open for 1.5 s+ after Ctrl+C, closed at kill
  --gateway --json                             cand  130          22 ms           +2 ms                 closed +8 ms

Main prints Command interrupted by SIGINT. Waiting for cleanup before exiting. and waits until the launcher force-kills it. The candidate prints the same line, restores the terminal and exits 130.

Interrupted set-provider: in both lanes the Gateway had already written settings/tts.json ({"tts":{"provider":"openai"}}) before Ctrl+C. The fix only stops the client from waiting; it does not cancel or roll back a write the Gateway has received.

Controls (no Ctrl+C), same output on main and candidate, exit 0: tts status --json, tts providers --gateway --json, tts personas --gateway --json, and the local paths tts providers --json, tts personas --json (only a Node PID in a deprecation warning differs).

Unit: the existing cancellation table now also covers tts status, tts providers, tts personas and tts disable over the Gateway. With main's production code these 4 cases fail; with this branch all 11 pass, and src/cli/capability-cli.test.ts passes 118/118. The extracted support file and the config/test-lines-allocations file are gone; tests are net -4 lines against main.

@obviyus

obviyus commented Nov 8, 2026

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 8, 2026
@obviyus

obviyus commented Nov 8, 2026

Copy link
Copy Markdown
Collaborator

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Nov 8, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-environment Preliminary submission classification; full source review pending. labels Nov 8, 2026
@obviyus
obviyus merged commit 2e0e3c5 into openclaw:main Nov 8, 2026
113 checks passed
@obviyus

obviyus commented Nov 8, 2026

Copy link
Copy Markdown
Collaborator

Landed in 2e0e3c5. Thanks @shuisadev and @SunnyShu0925. Ctrl+C now stops the TTS Gateway commands at once.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Nov 9, 2026
fix(cli): cancel interrupted tts gateway RPCs

openclaw capability tts status, providers --gateway, personas --gateway and the --gateway state changes (enable, disable, set-provider, set-persona) ignored Ctrl+C. The Gateway request got no abort signal, so the command waited until its 30-second timeout or a forced kill. The abort signal is now passed to these Gateway calls, as tts convert already does since openclaw#194128. The client stops waiting; the Gateway can still finish a write it already received.

Evidence: built openclaw from main and from this change, each with a real Gateway, in Docker on node 24.22.1. A local relay held the tts replies for 25 s, and Ctrl+C was sent in a real terminal 1 s after the request reached the Gateway. tts status: main was force-killed after 2174 ms with the connection still open; this change exits with code 130 after 28 ms and closes the connection. set-provider: 2273 ms and killed on main, exit 130 after 22 ms with this change. In both builds the Gateway had already written the setting before Ctrl+C. Runs without Ctrl+C give the same output on both. Details: openclaw#195206 (comment).

Thanks @shuisadev and @SunnyShu0925.

Co-authored-by: SunnyShu <[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 P2 Normal backlog priority with limited blast radius. proof: sufficient ClawSweeper judged the real behavior proof convincing. rating: 🦞 diamond lobster Very strong PR readiness with only minor 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.

3 participants