Skip to content

fix: keep v4 apps connected after widget retirement - #182277

Merged
steipete merged 4 commits into
mainfrom
openclaw/calm-lobster-3
Oct 24, 2026
Merged

steipete merged 4 commits into
mainfrom
openclaw/calm-lobster-3

Conversation

@roboclaw-bot

@roboclaw-bot roboclaw-bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Collaborator

Related: #182109

What Problem This Solves

Fixes: existing protocol-v4 apps cannot connect after the A2UI retirement because the Gateway requires protocol v5.

User Impact

User impact: existing apps, including OpenClaw for macOS 2026.10.3, can connect without an unnecessary app upgrade. The shipped v3 node/probe compatibility window remains available.

A2UI remains retired. Existing Doctor backup/removal behavior is unchanged; recreate retired widgets as HTML.

Why This Change Was Made

Keep the connection protocol at v4. Retain the old registered-widget wire declarations for parsing, but reject retired widget puts with an actionable error before any board mutation. Restore the v3 node envelope, signing metadata, and session feature ceilings instead of treating v4 as the legacy dialect.

No renderer, plugin registration API, or persisted registered content is restored. The necessary production growth restores the shipped node compatibility path removed in #182109; it does not introduce another compatibility owner.

Evidence

  • A frozen v5-constants negative control reproduces the exact Mac handshake failure: client min/max 4, Gateway expectedProtocol 5. With this fix, the same authenticated WebSocket handshake and health RPC pass.
  • Six focused Vitest shards pass, covering Gateway auth/negotiation, retired-widget rejection with unchanged stored state, v4 response parsing, client fallback/signing, node command policy, board persistence, dashboard output, and prompt-prefix stability.
  • Production and affected package/Gateway test typechecks, targeted type-aware lint, formatting, and diff checks pass.
  • Protocol registry/schema checks and deterministic Swift/Kotlin generation checks pass; Control UI validators regenerated.
  • Independent review of the final extraction found no actionable P0–P2 findings; staged line-cap ratchet passes without exemptions.
  • Final client regression run: 125 tests pass across three files, including three real-WebSocket v3 fallback cases (0.84 seconds of test time); 38.44 seconds wall time including worker compilation. CI timings will be supplied by the PR checks.

Rust workspace and TypeScript contracts passed in Node Runtime Conformance. This is Gateway handshake proof, not a native macOS app UI test. No live Gateway was modified or restarted.

Inherited CI failures

CI run 40067226183 reports three pre-existing test failures. All three reproduce with the same failure on baseline 4dc5be9f02824634ba58edbe11f98f7d9ded1915, using frozen dependencies and the captured failing shard inputs:

  • Scheduler E2E: the test requests openai/gpt-4.1 while its fixture permits only mock-openai/scheduler-canary.
  • Session catalog: the delayed-source assertion expects CATALOG_LOADING, while the existing implementation returns pending: true.
  • Chat abort settlement: the accepted-injection fixture observes zero queued injections instead of one.

The CI-executed merge was 6208c3388b5a6ae5efdb5f7185fac2041c7aa3a0 (main parent 7c374d4539b244c582d585054d7e98af261de27c, PR parent c3810e4a56c2ade46278ccca1fdce9a8c63f5cfb). Eighteen inspected failure-owner, fixture, config, runner, package and lockfile inputs have identical Git objects across the reproduced baseline, CI main parent and executed merge. The failed baseline replays are attribution evidence, not passing CI or fixes. These unrelated failures remain unchanged.

Hosted ClawSweeper review did not produce a verdict because its input-safety check held the run. The independent autoreview described above completed.

Reported by and implemented at the direction of @steipete.

Work sessions

Worked on by

roboclaw-bot and others added 2 commits October 24, 2026 05:38
Worked on by:
- @steipete

Co-authored-by: steipete <[email protected]>
OpenClaw-Publication: c546c295-63b0-41e3-9c81-a0f723d6660f
@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

🦞👀
ClawSweeper picked this up.

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

ClawSweeper review blocked

Automated review did not run, so no review verdict was produced.

Reason: The input-safety check rejected material in this revision. No detected value, path, or scanner output is reproduced here.

Automatic review is on hold, including after source changes. Request a fresh re-review after resolving the failure; maintainers can also release the hold through an intentional scanner-policy update.

Next step: If this is a genuine credential, remove and rotate it. If it is an intentional test fixture, a maintainer must review and qualify it.

View the workflow run.

@openclaw-barnacle openclaw-barnacle Bot added docs Improvements or additions to documentation app: web-ui App: web-ui gateway Gateway runtime scripts Repository scripts agents Agent runtime and tooling size: L labels Oct 24, 2026
roboclaw-bot and others added 2 commits October 24, 2026 05:39
Preserve the split native signed-connect tests while retaining v3/v4 expectations.

Co-authored-by: steipete <[email protected]>
Worked on by:
- @steipete

Co-authored-by: steipete <[email protected]>
OpenClaw-Publication: fcbbb6bc-7192-4f86-95aa-b9182b69eadf
@roboclaw-bot
roboclaw-bot marked this pull request as ready for review October 24, 2026 05:41
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Security sensitive changes

This maintainer PR changes sensitive security components.

No secops approval is required. This comment is informational because the PR author has Maintain or Admin access.

  • Current SHA: c3810e4a56c2ade46278ccca1fdce9a8c63f5cfb
  • Maintainer: @roboclaw-bot
  • Repository role: maintain

These security sensitive changes were made:

  • src/gateway/server/ws-connection/connect-admission.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.
  • src/gateway/server/ws-connection/connect-device-pairing.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.
  • src/gateway/server/ws-connection/connect-node-session.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.
  • src/gateway/server/ws-connection/connect-session.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.
  • src/gateway/server/ws-connection/message-handler-types.ts: Controls Gateway authentication, pairing, or caller permissions. Check identity validation, scope checks, and revocation.

Carefully review these changes before merging.

@roboclaw-bot
roboclaw-bot enabled auto-merge (squash) October 24, 2026 05:45
@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. labels Oct 24, 2026
@roboclaw-bot
roboclaw-bot disabled auto-merge October 24, 2026 06:06
@steipete

Copy link
Copy Markdown
Contributor

Landing under the inherited-failure exception, at Peter's direction ("ensure that it's landed then update team server"). The Team Gateway is currently on r195 (83c72975), which includes #182109, so protocol-v4 apps can't connect until this ships.

The three red jobs reproduce identically on unchanged main 23db299b15b4. Each was run locally as a single file with Node 26.12.1, node scripts/run-vitest.mjs <file> --maxWorkers=1:

  • checks-node-changed-8: test/gateway.multi.e2e.test.ts > "preserves scheduler runtime across a scheduler-disabled Gateway edit". On main it fails the same way: invalid cron.add params: automation model override 'openai/gpt-4.1@openai:cron-passive-manager' rejected by agents.defaults.models (1 failed, 2 passed).
  • checks-node-changed-compact-large-16: src/gateway/server-methods/session-catalog.test.ts > "keeps a delayed source off the catalog RPC path". On main it fails the same way (1 failed, 14 passed).
  • checks-node-changed-compact-large-23-2: src/gateway/server.chat-abort-settlement.test.ts > "preserves an acknowledged abort across accepted-injection". On main it fails the same way (1 failed, 5 passed).

None of these files are touched by this PR, and openclaw/ci-gate fails only downstream of them. Every other check passed on exact head c3810e4a56c2ade46278ccca1fdce9a8c63f5cfb. CI was not rerun.

@steipete
steipete merged commit 2875e81 into main Oct 24, 2026
269 of 274 checks passed
@steipete
steipete deleted the openclaw/calm-lobster-3 branch October 24, 2026 06:10
@roboclaw-bot

roboclaw-bot commented Oct 24, 2026 •

Copy link
Copy Markdown
Collaborator Author

Merged by @steipete via squash. Verified the landed tree matches the reviewed head applied to its landing parent, and the commit is on main.

github-actions Bot pushed a commit to Desicool/openclaw that referenced this pull request Oct 25, 2026
* fix: keep v4 apps connected after widget retirement

Co-authored-by: steipete <[email protected]>

* fix: keep v4 apps connected after widget retirement

Worked on by:
- @steipete

Co-authored-by: steipete <[email protected]>
OpenClaw-Publication: c546c295-63b0-41e3-9c81-a0f723d6660f

* Publish openclaw/calm-lobster-3

Worked on by:
- @steipete

Co-authored-by: steipete <[email protected]>
OpenClaw-Publication: fcbbb6bc-7192-4f86-95aa-b9182b69eadf

---------

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

Labels

agents Agent runtime and tooling app: web-ui App: web-ui clawsweeper:intake:bug Preliminary submission classification; full source review pending. clawsweeper:intake:needs-repro Preliminary submission classification; full source review pending. docs Improvements or additions to documentation gateway Gateway runtime scripts Repository scripts security-sensitive-changed size: L

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants