Skip to content

Dedupe connection error bars into a single thin top banner#865

Merged
shanselman merged 1 commit into
openclaw:mainfrom
bkudiess:bkudiess-dedupe-connection-info-bars
Jun 26, 2026
Merged

Dedupe connection error bars into a single thin top banner#865
shanselman merged 1 commit into
openclaw:mainfrom
bkudiess:bkudiess-dedupe-connection-info-bars

Conversation

@bkudiess

@bkudiess bkudiess commented Jun 26, 2026

Copy link
Copy Markdown
Collaborator

Summary

A connection/auth failure rendered two error bars: the global top-window InfoBar and an in-page "Connection Error" InfoBar on the Connection page. The auth pipeline also published two global notifications for a single failure, which forced the banner's action to degrade to "Show more" instead of routing to Connection.

This consolidates everything into one thin top banner and removes the in-page bar, with no loss of states/messages.

What changed

  • Removed the in-page AuthErrorBar (XAML + all code paths) and its now-dead resw strings (ConnectionPage_AuthGuidance*, ConnectionPage_ConnectFailed) across all 5 locales.
  • One global banner carries every state the in-page bar did (gateway connection failed, pairing required, Windows node failed/rate-limited, etc.).
  • Always routes to Connection — connection notifications are prioritized as the visible banner, preferring an actionable one over an action-less transient, so the user always gets an Open Connection action (not "Show more").
  • Consolidated duplicate global notifications — stopped publishing the separate connection:authentication-failed banner; the snapshot-driven connection:issue notification is the single source.
  • Re-homed transient errors — WSL host-action failures use the inline WSL-card status (or a top notification when that card is hidden); connect/switch failures publish via ShowTransientConnectionError on the same banner id (cannot double-bank).
  • Windows-aligned, thinner design — single line: bold headline + " — detail", with the action as a right-aligned hyperlink.

Validation

  • ./build.ps1 — all projects build
  • Tray tests: 1218 passed (incl. new banner-priority / dedupe regression tests)
  • Shared tests: 2514 passed
  • Two adversarial rubber-duck reviews (GPT-5.5); all findings fixed.

Screenshots

Before: two bars (top "Gateway connection failed" + in-page "Connection Error").
image (1)

After: one thin banner — ⊗ Gateway connection failed — Transport error … Open Connection ✕ — with the Connection page showing only its own recovery card.
06-banner-show-more
04-redesigned-thin-banner

@clawsweeper

clawsweeper Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codex review: needs maintainer review before merge. Reviewed June 26, 2026, 6:10 PM ET / 22:10 UTC.

Summary
The PR removes the Connection page AuthErrorBar, consolidates auth/connection failures onto the global connection:issue banner with Open Connection priority, trims the banner to one line, removes dead localized strings, and adds banner selection tests.

Reproducibility: yes. at source/proof level: current main still defines AuthErrorBar and separately publishes connection:authentication-failed, and the inspected before screenshot shows both bars for one failure. I did not run the WinUI app locally because this was a read-only review.

Review metrics: 4 noteworthy metrics.

  • Changed files: 12 files, +218/-255. The patch is bounded to tray notification UI, Connection page cleanup, resource removals, and focused tests.
  • Notification tests: 3 added. The new tests cover the banner priority and dedupe behavior most likely to regress this fix.
  • Locales touched: 5 resource files. Removing the dead AuthErrorBar and auth-guidance strings across supported locales reduces resource drift risk.
  • Check state: 2 passed, 2 skipped, 4 pending. Maintainers should wait for the normal test and E2E jobs before merging even though no code defect was found in review.

Merge readiness
Overall: 🐚 platinum hermit
Proof: 🦞 diamond lobster ✨ media proof bonus
Patch quality: 🐚 platinum hermit
Result: ready for maintainer review.

Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch.

Rank-up moves:

  • [P2] Let the pending GitHub test and E2E jobs finish green before merge.

Risk before merge

  • [P1] The PR’s normal GitHub test and E2E jobs were still pending at review time, so merge should wait for those checks or inspect any failures.
  • [P1] This read-only review did not run the repository build or tests locally; the PR body reports successful local validation, and the branch adds focused unit coverage for the notification-selection behavior.

Maintainer options:

  1. Decide the mitigation before merge
    Land the focused banner consolidation after required checks finish green, preserving the existing Connection-page recovery card as the detailed troubleshooting surface.
  2. Pause or close
    Do not merge this PR until maintainers decide whether the risk is worth taking.

Next step before merge

  • No automated repair lane is needed; the remaining action is maintainer review plus normal check completion.

Security
Cleared: The diff does not change dependencies, build/release automation, credential storage, authorization, network calls, or security boundaries; it changes how existing connection errors are surfaced in the tray UI.

Review details

Best possible solution:

Land the focused banner consolidation after required checks finish green, preserving the existing Connection-page recovery card as the detailed troubleshooting surface.

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

Yes, at source/proof level: current main still defines AuthErrorBar and separately publishes connection:authentication-failed, and the inspected before screenshot shows both bars for one failure. I did not run the WinUI app locally because this was a read-only review.

Is this the best way to solve the issue?

Yes: consolidating onto the existing snapshot-driven connection:issue banner and making actionable connection notifications win is the narrowest maintainable path I found. The existing recovery card still owns detailed repair guidance, while the banner reliably routes users to Connection.

AGENTS.md: found and applied where relevant.

Codex review notes: model internal, reasoning high; reviewed against 9ac8cfb24f35.

Label changes

Label justifications:

  • P2: This is a normal-priority tray UX bug fix for duplicate connection error messaging and degraded recovery routing 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. Sufficient (screenshot): The PR body includes inspected before/after screenshots showing the duplicate bars before and a single thin top banner with Open Connection after, which directly demonstrates the visible WinUI behavior.
  • proof: sufficient: Contributor real behavior proof is sufficient. The PR body includes inspected before/after screenshots showing the duplicate bars before and a single thin top banner with Open Connection after, which directly demonstrates the visible WinUI behavior.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence. The PR body includes inspected before/after screenshots showing the duplicate bars before and a single thin top banner with Open Connection after, which directly demonstrates the visible WinUI behavior.
Evidence reviewed

What I checked:

  • Repository policy applied: AGENTS.md was read fully; its connection/tray guidance required checking connection architecture and visible routing to Connection settings. (AGENTS.md:46, 9ac8cfb24f35)
  • Architecture guidance matches direction: Connection architecture says Tray.WinUI consumes the connection layer through interfaces and tray actions should route common configuration problems to Connection settings. (docs/CONNECTION_ARCHITECTURE.md:21, 9ac8cfb24f35)
  • Current main still has the in-page error bar: The base branch still defines AuthErrorBar on the Connection page, so the central cleanup is not already implemented on main. (src/OpenClaw.Tray.WinUI/Pages/ConnectionPage.xaml:63, 9ac8cfb24f35)
  • Current main still publishes the second auth notification: OnGatewayAuthenticationFailed stores AuthFailureMessage and publishes a separate connection:authentication-failed notification, which can coexist with the snapshot-driven connection:issue banner. (src/OpenClaw.Tray.WinUI/App.xaml.cs:2713, 9ac8cfb24f35)
  • PR consolidates to one connection banner identity: The PR adds ShowTransientConnectionError using the connection:issue id/dedupe key and removes the separate auth-failed banner publication path. (src/OpenClaw.Tray.WinUI/App.xaml.cs:2331, 9ab3be80ef59)
  • PR adds focused regression coverage: The diff adds three AppNotificationBannerState tests covering connection priority, hidden-notification reveal behavior, and preferring actionable connection notifications over actionless connection notifications. (tests/OpenClaw.Tray.Tests/Services/AppNotificationServiceTests.cs:68, 9ab3be80ef59)

Likely related people:

  • RBrid: PR metadata and git blame show commit 1a07759 from Use app notifications for background issues #753 introduced the app-notification routing and connection:authentication-failed path adjacent to this change. (role: recent notification contributor; confidence: high; commits: 1a07759a7e6e; files: src/OpenClaw.Tray.WinUI/App.xaml.cs, src/OpenClaw.Tray.WinUI/Services/AppNotificationPublisher.cs, src/OpenClaw.Tray.WinUI/Strings/en-us/Resources.resw)
  • ranjeshj: git blame and PR metadata tie AppNotificationBannerState and the ConnectionPage AuthErrorBar bridge to commit 429be9b from Apply bkudiess tray UX PR stack #780. (role: adjacent tray UX integrator; confidence: high; commits: 429be9ba9368; files: src/OpenClaw.Tray.WinUI/Services/AppNotificationService.cs, src/OpenClaw.Tray.WinUI/Pages/ConnectionPage.xaml.cs, src/OpenClaw.Tray.WinUI/Windows/HubWindow.xaml.cs)
  • bkudiess: Current main includes commit f51a861 from Improve remote gateway setup and connection error recovery #828, which recently changed ConnectionPage recovery UX and tests in the same surface this PR builds on. (role: recent connection-page recovery contributor; confidence: high; commits: f51a8618ed7b; files: src/OpenClaw.Tray.WinUI/Pages/ConnectionPage.xaml, src/OpenClaw.Tray.WinUI/Pages/ConnectionPage.xaml.cs, src/OpenClaw.Tray.WinUI/Pages/ConnectionPagePlan.cs)
  • vincentkoc: Commit 260fb90 from fix(pairing): clarify reconnect and startup state #616 recently touched pairing/reconnect state and adjacent ConnectionPage/App.xaml.cs behavior. (role: recent connection-state contributor; confidence: medium; commits: 260fb90c6dc7; files: src/OpenClaw.Tray.WinUI/App.xaml.cs, src/OpenClaw.Tray.WinUI/Pages/ConnectionPage.xaml.cs, src/OpenClaw.Tray.WinUI/Pages/ConnectionPagePlan.cs)
What the crustacean ranks mean
  • 🦀 challenger crab: rare, exceptional readiness with strong proof, clean implementation, and convincing validation.
  • 🦞 diamond lobster: very strong readiness with only minor maintainer review expected.
  • 🐚 platinum hermit: good normal PR, likely mergeable with ordinary maintainer review.
  • 🦐 gold shrimp: useful signal, but proof or patch confidence is still limited.
  • 🦪 silver shellfish: thin signal; proof, validation, or implementation needs work.
  • 🧂 unranked krab: not merge-ready because proof is missing/unusable or there are serious correctness or safety concerns.
  • 🌊 off-meta tidepool: rating does not apply to this item.

Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics.

How this review workflow works
  • ClawSweeper keeps one durable marker-backed review comment per issue or PR.
  • Re-runs edit this comment so the latest verdict, findings, and automation markers stay together instead of adding duplicate bot comments.
  • A fresh review can be triggered by eligible @clawsweeper re-review comments, exact-item GitHub events, scheduled/background review runs, or manual workflow dispatch.
  • PR/issue authors and users with repository write access can comment @clawsweeper re-review or @clawsweeper re-run on an open PR or issue to request a fresh review only.
  • Maintainers can also comment @clawsweeper review to request a fresh review only.
  • Fresh-review commands do not start repair, autofix, rebase, CI repair, or automerge.
  • Maintainer-only repair and merge flows require explicit commands such as @clawsweeper autofix, @clawsweeper automerge, @clawsweeper fix ci, or @clawsweeper address review.
  • Maintainers can comment @clawsweeper explain to ask for more context, or @clawsweeper stop to stop active automation.

@clawsweeper clawsweeper Bot added 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. P2 Normal priority bug or improvement with limited blast radius. labels Jun 26, 2026
@bkudiess bkudiess marked this pull request as ready for review June 26, 2026 19:12
@clawsweeper clawsweeper Bot added proof: sufficient Contributor real behavior proof is sufficient. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. 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. labels Jun 26, 2026
@bkudiess bkudiess force-pushed the bkudiess-dedupe-connection-info-bars branch from 19ad06d to bd37f32 Compare June 26, 2026 21:18
A connection/auth failure rendered two error bars: the global top-window
InfoBar plus an in-page "Connection Error" InfoBar on the Connection page.
The auth pipeline also published two global notifications for one failure,
which forced the banner action to degrade to "Show more".

Remove the in-page AuthErrorBar and consolidate to one top banner that:
- carries the gateway/node error states the in-page bar covered
- always routes the user to the Connection page via an "Open Connection"
  action (connection notifications are prioritized as the visible banner,
  preferring an actionable one over an action-less transient)
- renders as a single thin line: bold headline + " - detail", with the
  action as a right-aligned hyperlink (Windows-aligned InfoBar)

Other changes:
- Stop publishing the duplicate connection:authentication-failed banner;
  the snapshot-driven connection:issue notification is the single source.
- Re-home transient errors: WSL host-action failures use the inline card
  status (or a top notification when the card is hidden); connect/switch
  failures publish via ShowTransientConnectionError on the same banner id.
- Remove now-dead resw strings (ConnectionPage_AuthGuidance*,
  ConnectionPage_ConnectFailed) across all five locales.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@shanselman shanselman force-pushed the bkudiess-dedupe-connection-info-bars branch from bd37f32 to 9ab3be8 Compare June 26, 2026 22:06
@shanselman shanselman merged commit 977648c into openclaw:main Jun 26, 2026
12 checks passed
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: 📸 screenshot Contributor real behavior proof includes screenshot evidence. 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