Skip to content

fix: Bindings stays on the spinner when config.get fails - #1857

Merged
shanselman merged 4 commits into
openclaw:mainfrom
SebTardif:fix/f119-bindings-config-get
Oct 28, 2026
Merged

shanselman merged 4 commits into
openclaw:mainfrom
SebTardif:fix/f119-bindings-config-get

Conversation

@SebTardif

@SebTardif SebTardif commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes: the Bindings page keeps its spinner up when the gateway is connected but config.get is rejected or never answered.

User Impact

User impact: a failed or stalled bindings load shows "Could not load bindings" and enables Refresh, so the page can be tried again.

Why This Change Was Made

RequestConfigAsync returned when the frame was sent. An ok: false response was only logged, and a missing response had no deadline. Bindings cleared its spinner only after a config snapshot. Refresh stayed disabled for that whole wait.

Bindings now waits on its own config.get for 15 seconds. A rejection or a timeout stops that load and shows a fixed sentence. The gateway's error text stays out of the page, because that text can include config details. A late failure from the request that Refresh replaced does not fail the new load.

Evidence

On 7b7aedfb4a41115461657510a2a0e84c2d6108f4, whose tree is identical to head 6f9f24d728c32d34ab5675e7d32a055ac4eff87e, an isolated fixture tray opened Bindings. The first config.get was rejected. The page showed the error and enabled Refresh. The next config.get was left unanswered until the same error returned and Refresh was enabled again. Refresh started another config.get while the previous request was still unanswered. That late rejection left the page on "Loading bindings...". The current request then returned an empty bindings snapshot and the page showed Single-agent mode.

Change Type

  • Bug fix
  • Feature
  • Refactor
  • Docs or instructions
  • Tests or validation
  • Security hardening
  • Chore or infrastructure

Scope

  • Tray or WinUI UX
  • Windows node capability
  • Local MCP or winnode
  • Gateway, connection, or pairing
  • Setup or onboarding
  • Permissions, privacy, or security
  • Tests, CI, or docs

Required proof pools

  • windows-winui-interactive: the Bindings page in the isolated tray shows the load error, the retry, and the late response.

Validation

  • ./build.ps1 -Project Tray succeeded on product commit 7b7aedfb4a41115461657510a2a0e84c2d6108f4. Head 6f9f24d728c32d34ab5675e7d32a055ac4eff87e is an empty retrigger of that commit.
  • The Bindings page checks, including rejection, the deadline, and a late failure after Refresh, were green.
  • One shared wizard deadline check was green.

Real Behavior Proof

  • Behavior or issue addressed: Bindings stays on the spinner, with Refresh disabled, when a connected config.get is rejected or never answered. A late failure can also fail the refresh that replaced it.
  • Real environment tested: Windows, non-dev win-x64 tray built from this head, isolated OPENCLAW_TRAY_DATA_DIR, synthetic gateway.
  • PR head or commit tested: 6f9f24d728c32d34ab5675e7d32a055ac4eff87e. The log and UI Automation were collected on parent 7b7aedfb4a41115461657510a2a0e84c2d6108f4, which has the same tree.
  • Exact steps or command run: Start the tray against the fixture. Open openclaw://hub/bindings. Reject the first config.get. Leave the next config.get unanswered until the page stops waiting. Click Refresh, leave that request unanswered, click Refresh again, then deliver the previous request's rejection before the current request succeeds.
  • Evidence after fix: At 22:10:33 the log sent config.get and UI Automation read title Could not load bindings, message The gateway did not return bindings. Refresh to try again., and RefreshButton enabled. At 22:11:14 another config.get was sent and left unanswered. The same error returned and RefreshButton was enabled. At 22:13:01 Refresh sent another config.get. At 22:13:02 the log recorded Gateway request failed: config.get rejected while UI Automation read Loading bindings..., RefreshButton disabled, and no error title. The current request then applied the empty snapshot: title Single-agent mode, message All messages route to the default agent. Add bindings for multi-agent routing., RefreshButton enabled, and no error title.
  • Observed result: A rejected or unanswered config.get leaves the loading state and enables Refresh. A late rejection does not replace the load that is still in flight. The successful retry shows Single-agent mode.
  • Screenshot or artifact links verified? No
  • What was not tested: a screenshot. The activity is the log lines and the UI Automation tree.
  • Not verified or blocked: a screenshot. The log lines and the UI Automation tree are the record.

Security Impact

  • New permissions or capabilities? No
  • Secrets or tokens handling changed? No
  • New or changed network calls? No
  • Command or tool execution surface changed? No
  • Data access scope changed? No

Compatibility and Migration

  • Backward compatible? Yes
  • Config or environment changes? No
  • Migration needed? No

Review Conversations

  • I replied to or resolved every bot review conversation addressed by this PR.
  • I left unresolved only conversations that still need maintainer judgment.

A connected Bindings load waited forever when config.get was rejected
or never answered, and Refresh stayed disabled.

Raise ConfigGetFailed when config.get is not sent or the gateway
rejects it. Bindings stops that load on the signal or after 15 seconds.
The raw gateway text stays in the log. The page shows a fixed message.

Validation: ./build.ps1 passed. Shared 4648 passed, 24 skipped. Tray 4510 passed.
The two new Bindings checks failed on the spinner before this change and passed after it.

Signed-off-by: Sebastien Tardif <[email protected]>
@clawsweeper

clawsweeper Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

🦞👀
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.

@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 priority bug or improvement 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 Oct 23, 2026
@clawsweeper

clawsweeper Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Codex review: needs maintainer review before merge.

What this changes

The Bindings page handles rejected or unanswered configuration requests with a localized error and an enabled Refresh button.

Example: A connected gateway leaves the Bindings config.get request unanswered for 15 seconds.

  • Before: The loading spinner remains visible and Refresh stays disabled.
  • After: The page shows “The gateway did not return bindings. Refresh to try again.” and enables Refresh.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) Useful, focused, and proven through the shipped UI; remaining test-quality improvements are nonblocking, and exact-head CI is still running.
Proof confidence 🦞 diamond lobster (5/6) Sufficient (live_output): The supplied Windows proof exercises the actual Bindings page and gateway client against a synthetic gateway, with copied UI Automation values and log observations for rejection, timeout, retry, ignored late rejection, and successful empty bindings on a tree identical to the reviewed head.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Bindings can keep showing its loading spinner with Refresh disabled after a connected gateway rejects or never answers its configuration request.
Reason: A bounded failure state with an in-product retry restores the existing loading contract without adding settings or changing persisted configuration.

Merge readiness

✅ Ready for maintainer review

Keep this PR open: it fixes a source-confirmed loading failure still present on current main, with sufficient runtime evidence and no blocking production finding.

Priority: P2
Reviewed head: 6f9f24d728c32d34ab5675e7d32a055ac4eff87e

Before merge

None.

Findings

None.

Tests

  • Low-value test tests/OpenClaw.Tray.Tests/BindingsPageConnectionTests.cs: Remove ConfigLoadDeadline_UsesAPositiveOverrideOrTheDefault: it mirrors a test-only getter and pins its incidental default without protecting a distinct user failure.
  • Missing end-to-end proof: The revised correlation tests are not shown failing against the base; the initial spinner tests were reported failing before the first patch.
Agent review details

How this fits together

Bindings reads configuration through the operator gateway client, stores successful snapshots in AppState, and projects loading, routing rows, and recovery messages into WinUI controls.

flowchart LR
  A[Bindings page] --> B[Correlated gateway request]
  B --> C[Gateway response or timeout]
  C --> D[Page lifecycle guard]
  D --> E[AppState configuration]
  E --> F[Bindings rows]
  D --> G[Error and Refresh]
Loading

Technical review

Best possible solution:

Land the focused correlated-request repair while preserving the existing AppState, loading-state, and disconnected-recovery owners.

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

Current-main source shows that rejection or silence produces no configuration update to finish loading, and the contributor supplies matching post-fix runtime observations.

Is this the best way to solve the issue?

The repair appropriately reuses the existing response-aware RPC implementation instead of adding transport failure events or a parallel timeout mechanism.

AGENTS.md: found and applied where relevant.

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

Provenance checked

Testing

Proof path: shipped entry point.

Security

None.

Evidence

What I checked:

Likely related people:

  • Sebastien Tardif: Raw commit ae56aa5 adds src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs:41 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: ae56aa5d11f6; files: src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs)
  • Scott Hanselman: Raw commit 1fe8e52 adds src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs:35 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 1fe8e5216ca7; files: src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs)
  • Ranjesh Jaganathan: Raw commit ece8758 adds src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs:29 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: medium; commits: ece8758e9d1e; files: src/OpenClaw.Tray.WinUI/Pages/BindingsPage.xaml.cs)

Review metrics

Metric Value Why it matters
Introduced change size Production and resources +121/-5; tests +176/-4 The production change is confined to Bindings recovery and six localized messages; most added lines exercise failure scenarios.

Labels

Label changes:

No label changes.

Label justifications:

  • P2: A connected gateway failure leaves one settings page waiting indefinitely, with limited blast radius.
  • 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.

  • Synchronize the late-rejection test with callback processing before asserting that the replacement load remains active.
  • Remove the deadline getter test that only mirrors the implementation.

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 (2 earlier review cycles)
  • reviewed 2026-10-23T21:40:59.646Z sha 0ea3c9f :: needs real behavior proof before merge. :: [P1] Use the existing correlated RPC path for the Bindings load
  • reviewed 2026-10-24T05:19:18.139Z sha 7b7aedf :: needs maintainer review before merge. :: none

Reviewed October 24, 2026, 1:36 AM ET / 05:36 UTC (Revision 3).

A rejected or silent config.get left Bindings on the spinner.
The page now waits on its own config.get. A late failure from
the request that Refresh replaced does not fail the new load.

Signed-off-by: Sebastien Tardif <[email protected]>
@SebTardif

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

🦞👀
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. proof: sufficient Contributor real behavior proof is sufficient. 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: 🧂 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. labels Oct 24, 2026
Tray failed StopAsync_CancelsAndDrainsInFlightDirectConfirmation
after 2 seconds. That test is outside this Bindings change, and it
passes locally. A fork cannot rerun the failed job.

Signed-off-by: Sebastien Tardif <[email protected]>
@SebTardif

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 24, 2026 •

Copy link
Copy Markdown

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added clawsweeper:intake:bug Preliminary submission classification; full source review pending. and removed clawsweeper:intake:bug Preliminary submission classification; full source review pending. labels Oct 24, 2026
@shanselman shanselman added the status: 🚢 actively landing A maintainer or agent is actively driving this item through implementation, validation, or merge. label Oct 28, 2026
@shanselman

Copy link
Copy Markdown
Collaborator

Copilot triage agent here, not Scott. Thank you for the spinner fix. The independent reviews found no blocker after a small maintainer patch, 08713bb2: rendering another page's older config no longer discards Bindings' own newer reply. The added regression failed before that patch (stale Single-agent mode) and passes after it. The focused Bindings suite passes all 13 cases, and an independent Opus rubber-duck review found no blocking issue in the patch.

Validation on the exact head: .\build.ps1 passed on native ARM64; dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore recorded 4,642 passed, 1 symlink-privilege failure reproduced on current main, and 26 skipped; dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore recorded 4,503 passed and 4 pre-existing ARM64 prerequisite-fixture failures (the fixture correction already on main passes all four). Exact-head CI, including UI/accessibility and WSL lanes, passed CI Gate. Targeted native UI proof of the new response race was not collected: the authorized fixture launcher has no config fault/reordering controls. The regression is headless page-owner evidence, not screenshot proof. GitHub reports a clean merge state; proceeding with a head-pinned squash merge.

@shanselman
shanselman merged commit b19d4d0 into openclaw:main Oct 28, 2026
24 checks passed
@shanselman shanselman removed the status: 🚢 actively landing A maintainer or agent is actively driving this item through implementation, validation, or merge. label Oct 28, 2026
@clawsweeper clawsweeper Bot mentioned this pull request Oct 29, 2026
5 of 16 tasks
larroy pushed a commit to larroy/openclaw-windows-node that referenced this pull request Oct 30, 2026
* fix: Bindings stays on the spinner when config.get fails

A connected Bindings load waited forever when config.get was rejected
or never answered, and Refresh stayed disabled.

Raise ConfigGetFailed when config.get is not sent or the gateway
rejects it. Bindings stops that load on the signal or after 15 seconds.
The raw gateway text stays in the log. The page shows a fixed message.

Validation: ./build.ps1 passed. Shared 4648 passed, 24 skipped. Tray 4510 passed.
The two new Bindings checks failed on the spinner before this change and passed after it.

Signed-off-by: Sebastien Tardif <[email protected]>

* fix: Bindings config.get failure is tied to that request

A rejected or silent config.get left Bindings on the spinner.
The page now waits on its own config.get. A late failure from
the request that Refresh replaced does not fail the new load.

Signed-off-by: Sebastien Tardif <[email protected]>

* ci: retrigger after an activation-router timeout

Tray failed StopAsync_CancelsAndDrainsInFlightDirectConfirmation
after 2 seconds. That test is outside this Bindings change, and it
passes locally. A fork cannot rerun the failed job.

Signed-off-by: Sebastien Tardif <[email protected]>

* fix: retain pending Bindings response across config updates

Co-authored-by: Copilot App <[email protected]>

---------

Signed-off-by: Sebastien Tardif <[email protected]>
Co-authored-by: Scott Hanselman <[email protected]>
Co-authored-by: Copilot App <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

P2 Normal priority bug or improvement with limited blast radius. proof: sufficient Contributor real behavior proof is sufficient. 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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants