Skip to content

refactor(macos): move app settings into the Dashboard and keep Connection native - #138092

Merged
steipete merged 21 commits into
mainfrom
steipete/mac-settings-into-dashboard
Sep 5, 2026
Merged

steipete merged 21 commits into
mainfrom
steipete/mac-settings-into-dashboard

Conversation

@steipete

@steipete steipete commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

Related: #115999 (native/dashboard ownership doctrine), #137971 (Control UI half of this change)

Land after #137971. This PR removes the native settings surface; the Dashboard pages it points to ship in #137971 with the Gateway.

What Problem This Solves

The macOS app has two settings surfaces. The native Settings window owns General, Permissions, Voice & Talk, Updates and a set of "legacy" gateway panes (Channels, Skills, Cron Jobs, Threads, Instances) that were handed off to the Dashboard in #115999 but never deleted and kept receiving fixes; the Dashboard owns everything else. Users have to know which window holds which setting, the native panes drift from the Dashboard as it evolves, and app-local settings such as voice-wake trigger words are unreachable from any browser.

Why This Change Was Made

This completes the #115999 decision: native owns device-local capability, the Dashboard owns settings UI. The native Settings window is removed. Device-local capability is exposed to the Control UI through a new WKWebView bridge (openclawDeviceSettings, contract owned by ui/src/app/native-device-settings.ts from #137971): the app publishes a validated snapshot of app preferences, capabilities, browser import and cookie-sync state, all eight macOS permission statuses, voice settings, and updater state, and applies set / request-permission / open-system-settings / open / check-for-updates messages through the same native owners the panes used (never by writing openclaw.json). Enabling capabilities that let a Gateway act on or export data from this Mac (cookie sync and its domains/profile, Computer Control, Peekaboo Bridge, camera) requires a native confirmation sheet, because origin trust on the dashboard page is not user intent.

What stays native, deliberately: a small Connection window (Connection tab with mode, remote/SSH, Tailscale and discovery; Gateways tab with saved profiles; Debug tab while the developer toggle is on) because it must work when the Gateway is unreachable; the standard macOS About panel; and the bridge-opened panels (Quick Chat shortcut recorder, microphone tester with live meter, browser-login import). Settings… (⌘,) and the status menu's Settings… open the Dashboard's Settings; the status menu gains Connection…; the dashboard failure page gains "Connection Settings…". Exec approvals for this Mac need no bridge: the Devices page already edits them through exec.approvals.node.*, which shares the node's SQLite store with the app.

apps/macos/AGENTS.md records the doctrine so it stops living only in a PR body. Platform docs are updated to the new locations.

User Impact

One settings surface. In the Mac app, Dashboard → Settings gains a This Mac group (This Mac, Permissions) and This Mac sections on Talk and Updates; the native Settings window and its fifteen tabs are gone. Connection… remains available from the status menu, the app menu, and the dashboard failure page. About OpenClaw shows the standard About panel. Nothing changes for browsers, iOS, or other platforms.

Net production change: about −11.4k lines of Swift.

Evidence

Before (native Settings window, baseline build of main, isolated before profile):

Before: General
Before: Permissions
Before: Voice & Talk
Before: Channels handoff page
Before: Exec Approvals
Before: About

After (this branch's app under an isolated after profile, direct remote mode to a dev gateway serving the #137971 Control UI):

After: status menu with Settings…, Connection…, About
After: This Mac page, live bridge data
After: Permissions page, live TCC statuses with Grant… actions
After: Talk page with the This Mac section
After: Updates page with app version and updater state
After: native Connection window
After: About panel

Live test notes: the app connected as a paired node and UI client to the dev gateway, the This Mac pages rendered real snapshot data (shortcut ⌥Space, granted/undetermined TCC statuses), Connection… opened the native window on both tabs, About opened the standard panel. Found and fixed during the live test: the Talk page's primary language fell back to the first option because the published primary locale id was not in the available list (system-default marker); the snapshot now always publishes a member id.

Local proof (native SwiftPM with the packaging flags):

  • swift build --build-system native -c debug --product OpenClaw and swift build --build-system native --build-tests green.
  • Targeted pure-logic tests: swift test --filter 'DeviceSettingsBridgeTests|ConnectionWindowTests|CronModelsTests|DeviceSettingsRequestQueueTests' and DashboardRouteMapTests in OpenClawKit.
  • scripts/lint-swift.sh macos, scripts/format-swift.sh macos, pnpm native:i18n:verify, pnpm test test/scripts/apple-app-i18n.test.ts, node scripts/check-changed.mjs green.
  • Stateful window/permission/TCC tests remain for the isolated macos-swift CI job (never run on an operator desktop).
  • Codex autoreview (branch vs origin/main, P2): five findings, four fixed in the follow-up commit (native consent for high-risk capability enablement, login item still disable-able after the app moves, microphone tester released on terminal callbacks, no case-only string-catalog renames so existing translations survive); the fifth ("new strings are English-only in other locales") is the normal post-merge native locale-refresh flow and is not a defect.
  • Maintainer review fix: the bridge no longer registers the 1 s PermissionMonitor poll for the lifetime of dashboard windows; it refreshes on activation, after its own permission requests, and on the web status message.
  • Follow-up commits after review: fix(macos): confirm sensitive device settings natively (native consent sheet, login-item disable path, microphone tester release, catalog key restores, no TCC polling), fix(macos): publish valid voice locale selections (live-test finding above), and chore(macos): leave the string catalog to the locale refresh workflow (the preflight scope gate requires native source changes plus apps/.i18n/native-source.json only; Localizable.xcstrings stays owned by the post-merge native locale refresh, so new strings show English until that runs).
  • Later follow-ups: fix(macos): confirm voice wake and location escalation natively (final review pass: Voice Wake on, precise location on, and any location-mode escalation now also require the native consent sheet) and chore(macos): remove dead symbols left by the settings retirement (Periphery strict scan clean; removes the now-subscriber-less 1 s TCC poller, the native onboarding chat views the custodian replaced, and pane-only presentation helpers; the stale native-app-i18n inventory test now asserts surviving copy). Cumulative production delta on this branch is about −12.2k lines.

Final build (head with the consent and locale fixes), same isolated rig:

After: native consent sheet when the Dashboard enables camera access; Cancel is the default and cancelling leaves the toggle off
After: Talk page with the resolved system locale option

  • ClawSweeper P1s addressed in fix(macos): confirm presence reporting and point older Gateways at Dashboard settings: enabling active-computer-presence reporting now needs the same Cancel-default native consent (it shares this Mac's idle time with the Gateway), and the native Connection window gained a footer that tells users where app-local settings live and that the Gateway must include those Dashboard pages, with an "Open Dashboard Settings" button; the Connection and Updates docs say the same. No version gates or compatibility fallbacks were added, per the ownership doctrine. Branch rebased onto current main.
  • Rebase note for landing: main keeps touching retired test files. As of 8ef56e23c9d the only conflicts are apps/macos/Tests/OpenClawIPCTests/CronJobsStoreTests.swift (content) and apps/macos/Tests/OpenClawIPCTests/SkillsSettingsSmokeTests.swift (deleted here, modified upstream); keep this branch's deletion and its CronJobsStoreTests fixture shape, then pnpm native:i18n:baseline.
  • Landing-cycle commits (added while getting exact-head CI green across the Blacksmith macOS stall): fix(macos): retire consent with Dashboard documents (the native suite caught that consent sheets and queued requests survived document replacement or window teardown; now cancelled, with lifecycle tests), fix(macos): route bridge settings deep links through their permission owners (one owner for System Settings deep links; the existing "unrelated permissions get no privacy pane" test stays valid), fix(macos): preserve Dock icon selection in Dashboard (the retired General pane's icon style picker is now app.iconStyle on the bridge), fix(macos): settle dashboard edits after native consent (the bridge answers set with the settled snapshot via WKScriptMessageHandlerWithReply, so the web clears drafts only after native settlement), fix(macos): fence pending Voice Wake authorization and fix(macos): preserve newer location permission intent (generation guards so a newer Off cannot be overwritten by an older awaited authorization), fix(macos): publish language-aware Voice Wake availability, fix(macos): reject stale cookie domain consent and browser-session validation before device-settings writes, plus test-only isolation fixes for hosted-runner flakes hit along the way (native-app-i18n inventory assertions, iOS Watch settlement waits, package-mac-app readiness, dashboards-list-demand e2e). Exact-head native proof: the hosted release_gate dispatch run (macos-swift tests and release green).
  • Cross-window cookie consent (ClawSweeper P1 / security finding on 6786d743485): fixed in fix(macos): reject stale cookie domain consent and fix(macos): validate the browser session before device settings writes. After the native sheet resolves, the handler recomputes the consent the current shared allowlist would require and rejects the write unless it equals the consent that was actually shown; cookie-domain and profile mutations are now synchronous with that check (no await between check and write), and every device-settings write additionally requires a current, validated browser-session lease. Proof is the AppKit/WebKit lifecycle suite (apps/macos/Tests/OpenClawIPCTests/DashboardDeviceSettingsLifecycleTests.swift, real windows and sheets): revoke-domains is the reviewer's reproduction (window A requests ["existing.test", "added.test"], window B removes existing.test while A's sheet is open, A is allowed): A's set promise resolves with the settled snapshot whose browser.cookieSync.domains is [], the shared cookieSyncDomains stays [], so CookieSyncManager never observes a restored domain and no cookie-sync process is launched for it; normalize-profile / provisional prove normal approval still persists ["existing.test", "added.test"]; revoke-session (new) revokes the session lease during consent and both promises reject with no write. Local run at the pushed head: swift test --build-system native --filter 'DashboardDeviceSettingsLifecycleTests|DashboardBrowserSessionTests' → 12 tests in 2 suites passed (all 9 lifecycle transitions).
  • Compatibility (ClawSweeper's config/data-model asks): no openclaw.json keys added, changed, or removed; no SQLite or other stored data-model change (the "unknown-truncated-pull-files" marker is the reviewer's truncated file list); one legacy UI preference retired (the native-pane visibility escape hatch), all capability preferences keep their existing app-defaults keys and native owners; an app-only upgrade against an older Gateway keeps native Connection recovery and the Connection window's footer pointing at Dashboard settings, which is the accepted upgrade contract from the ownership decision, without version gates.
  • Final rebase for landing: rebased onto main at 3e4becea5e2; the worker's unrelated test(gateway): isolate update run ledger fixtures commit was dropped because test(update): isolate campaign RPC ledger state #139116 landed the upstream fix for that file, and a stray readability tweak to an Android UI test was reverted so the PR stays on the Mac and Dashboard surfaces. Exact-head native proof for the pushed head: hosted release_gate dispatch run https://github.com/openclaw/openclaw/actions/runs/33982020911. The PR's own pull_request run failed macos-swift (tests) on one unrelated case, OnboardingAISetupTests "activation consent uses shared wizard" (rejected-unavailable, manual), whose two-second poll caps left the AI setup model still busy on the hosted macos-26 runner; this PR does not touch that model, and the hosted exact-head run passed the same suite. Recorded as a follow-up for that test's settlement wait.

@clawsweeper

clawsweeper Bot commented Sep 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 app: macos App: macos scripts Repository scripts size: XL maintainer Maintainer-authored PR labels Sep 4, 2026
@steipete
steipete force-pushed the steipete/mac-settings-into-dashboard branch from 028d562 to 46f6991 Compare September 4, 2026 08:36
@steipete
steipete marked this pull request as ready for review September 4, 2026 08:37
@steipete steipete closed this Sep 4, 2026
@steipete steipete reopened this Sep 4, 2026
@clawsweeper clawsweeper Bot added P1 High-priority user-facing bug, regression, or broken workflow. merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. merge-risk: 🚨 security-boundary 🚨 May affect sandboxing, authorization, credentials, or sensitive data. 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 Sep 4, 2026
@clawsweeper

clawsweeper Bot commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

Codex review: blocked before merge. Reviewed September 5, 2026, 2:59 PM ET / 18:59 UTC.

ClawSweeper review

What this changes

Moves macOS app settings into the embedded Dashboard through a native bridge, retains an offline Connection window, and removes retired settings panes and supporting code.

Merge readiness

⛔ Blocked before merge - 6 items remain

This PR remains useful: current main still contains the native settings window. The inspected source addresses the prior consent and lifecycle findings; the remaining review limitation concerns access to the captured proof addendum, not a newly identified code defect.

Priority: P2
Reviewed head: 0f68afbd4f4788dff5da17ceefcfb08994f60bc1
Owner decision: Required. See Decision needed.

Review scores

Measure Result What it means
Overall readiness 🐚 platinum hermit (4/6) A coherent consolidation with meaningful native boundary coverage and prior repairs; reviewer access to the remaining addendum is handled separately from patch quality.
Proof confidence 🐚 platinum hermit (4/6) Sufficient (logs): Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Verification

Check Result Evidence
Real behavior Verified Sufficient (logs): Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.
Evidence reviewed 10 items Current main still needs the native half: Current main retains SettingsRootView and its native General, Permissions, Voice, and other panes. The supplied GitHub context verifies that #137971 merged the complementary Dashboard pages, not this native retirement.
Consent is revalidated at the write boundary: After native confirmation, the handler checks the requesting document and recomputes consent from current shared settings. Cookie domain and destination writes then occur synchronously through existing AppState setters.
Document and session fencing: Device reads and writes require an open, trusted, current document and a current browser session. The controller additionally validates the browser session’s origin and expiry; session-store replacement invalidates leases synchronously before awaited WebKit cleanup.
Findings None None.
Security None None.

How this fits together

The macOS app embeds the Gateway’s Dashboard. Dashboard settings requests pass through a native bridge to existing Mac preference and permission owners, which return the settled state to the page.

flowchart TD
  A[Dashboard settings] --> B[Native message bridge]
  B --> C[Validate document and session]
  C --> D[Native consent when required]
  D --> E[Revalidate scope and lifetime]
  E --> F[Mac preference and permission owners]
  F --> G[Settled Dashboard snapshot]
  H[Offline Connection window] --> A
Loading

Decision needed

Question Recommendation
Does the captured cookie-export addendum establish the allowed and revoked-scope final effects needed to resolve the existing proof decision? Inspect the existing addendum: Verify the captured export evidence and record whether it closes the remaining final-effect assessment before landing.

Why: The settings-write and lifecycle evidence is available, but the captured addendum is omitted and network retrieval failed; this requires someone with evidence access, not an automatic request for contributor rework.

Before merge

  • Resolve merge risk (P2) - Existing users upgrading the app while retaining an older Gateway can lose access to app-local settings until the Gateway supplies the Dashboard pages; the documented coordinated-upgrade contract intentionally replaces the native fallback.
  • Resolve merge risk (P1) - The captured cookie-export proof addendum remains inaccessible to this reviewer, so its final-effect coverage cannot be independently assessed here.
  • Complete next step (P2) - Have a maintainer with access inspect the captured cookie-export addendum and resolve the existing proof-sufficiency decision before merge.
  • Resolve maintainer decision - Resolve the maintainer decision shown above before merge.
  • Review config compatibility - Confirm compatibility and upgrade impact for the changed config or default surface before merge.
  • Add data-model compatibility proof - Confirm migration or upgrade compatibility proof before merge.
Agent review details

Security

None.

PR surface

PR surface statistics unavailable: the file list is incomplete.

Review metrics

Metric Value Why it matters
Production versus test footprint Production/tooling net −11,992 lines; tests/support net −5,802 lines Rename-aware accounting excludes generated localization and docs/policy; the reduction removes duplicate panes while retaining native owners.
Retired preference surface 1 legacy-pane preference removed The former native-settings opt-in no longer restores the retired panes, making the Dashboard dependency an upgrade concern.

Stored data model

Persistent data-model change detected: unknown-truncated-pull-files. Confirm migration or upgrade compatibility proof before merge.

Merge-risk options

Maintainer options:

  1. Retain the coordinated-upgrade contract (recommended)
    Ship the app with the matching Dashboard capability and retain the documented Connection guidance for older remote Gateways.

Technical review

Best possible solution:

Keep one Dashboard settings surface backed by existing native owners, with coordinated app/Gateway upgrades, offline Connection recovery, and verified consent-to-effect coverage.

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

Not applicable to the overall refactor. Prior consent failures have concrete native regression scenarios, but this read-only review did not execute them.

Is this the best way to solve the issue?

Yes, the inspected design consolidates duplicate settings UI while preserving native preference, permission, and offline recovery owners; the remaining evidence-access decision is separate from that architectural fit.

AGENTS.md: found and applied where relevant.

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

Labels

Label changes:

  • add proof: sufficient: Contributor real behavior proof is sufficient. Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.
  • add status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (logs): Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.
  • remove status: needs maintainer proof decision: Current PR status label is status: 👀 ready for maintainer look.

Label justifications:

  • P2: This is an actively maintained macOS settings consolidation with bounded product impact, not evidence of an urgent current outage.
  • merge-risk: 🚨 compatibility: Removing native settings makes existing app-local controls depend on the connected Gateway supplying the replacement Dashboard pages.
  • rating: 🐚 platinum hermit: Overall readiness is 🐚 platinum hermit; proof is 🐚 platinum hermit and patch quality is 🐚 platinum hermit.
  • status: 👀 ready for maintainer look: ClawSweeper has no concrete contributor-facing blocker left for this PR. Sufficient (logs): Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.
  • proof: sufficient: Contributor real behavior proof is sufficient. Recorded native after-fix runs support the settings and document-retirement behavior through real AppKit/WebKit owners; inspected source connects those scenarios to settled native writes. This preserves that positive evidence and the accepted presence exception, without claiming inspection of the omitted cookie-export addendum, which remains a maintainer proof decision.

Evidence

What I checked:

Likely related people:

  • steipete: Suggested for follow-up; no historical authorship or introduction is verified. (role: unverified routing candidate; confidence: low)

Rank-up moves

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

  • Resolve the existing export-proof assessment by inspecting the captured addendum.

Rating scale

Score Internal tier Crab rank Meaning
6/6 S 🦀 challenger crab Exceptional readiness
5/6 A 🦞 diamond lobster Very strong readiness
4/6 B 🐚 platinum hermit Good normal PR; ordinary maintainer review
3/6 C 🦐 gold shrimp Useful, but confidence is limited
2/6 D 🦪 silver shellfish Proof or implementation needs work
1/6 F 🧂 unranked krab Not merge-ready
N/A NA 🌊 off-meta tidepool Rating does not apply

Overall follows the weaker of proof and patch quality.
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.

Workflow

  • 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.

History

Review history (25 earlier review cycles; latest 8 shown)
  • reviewed 2026-09-05T02:58:45.444Z sha ebf971c :: needs real behavior proof before merge. :: [P1] [P1] Invalidate pending location grants when a newer choice arrives
  • reviewed 2026-09-05T04:52:45.243Z sha b5781ca :: needs real behavior proof before merge. :: none
  • reviewed 2026-09-05T06:08:34.612Z sha bc48fa8 :: blocked before merge. :: [P2] [P2] Publish selected-language Voice Wake availability
  • reviewed 2026-09-05T07:43:50.305Z sha 051c89f :: blocked before merge. :: none
  • reviewed 2026-09-05T08:59:51.416Z sha 051c89f :: blocked before merge. :: none
  • reviewed 2026-09-05T09:47:03.138Z sha 6786d74 :: blocked before merge. :: none
  • reviewed 2026-09-05T10:03:27.314Z sha 6786d74 :: needs real behavior proof before merge. :: [P1] Revalidate cookie-domain consent after another window changes its scope
  • reviewed 2026-09-05T17:58:55.760Z sha 0f68afb :: needs real behavior proof before merge. :: none

@clawsweeper clawsweeper Bot added proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. and removed rating: 🧂 unranked krab Not merge-ready due to missing proof or serious correctness/safety concerns. rating: 🦪 silver shellfish Thin PR readiness signal; proof, validation, or implementation needs work. proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. labels Sep 4, 2026
@steipete
steipete force-pushed the steipete/mac-settings-into-dashboard branch from d95f8c8 to 41d2e85 Compare September 4, 2026 11:17
@clawsweeper clawsweeper Bot added the proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. label Sep 4, 2026
@steipete
steipete force-pushed the steipete/mac-settings-into-dashboard branch from 41d2e85 to d920a62 Compare September 4, 2026 12:20
steipete added a commit that referenced this pull request Sep 4, 2026
…shboard settings

Require native consent before sharing idle/activity presence with the Gateway and keep app-local settings guidance available in the offline Connection window (PR #138092).
@steipete

steipete commented Sep 4, 2026

Copy link
Copy Markdown
Contributor Author

Rank-up moves from the 12:47 UTC review:

  • Make ConnectionTab Hashable (P1): payload-less Swift enums are implicitly Hashable, which is why the native build and the ConnectionWindowTests filter have been green on every push; the next push makes the conformance explicit anyway.
  • Active-presence Cancel/Allow final-effect proof: presence enablement goes through the same DeviceSettingsConsent → confirm → setDeviceSetting path that the camera capture in the body exercises live (Cancel leaves the toggle and the owner untouched); the presence mapping itself is covered by DeviceSettingsConsentTests, including the decrease-needs-no-consent cases. No separate live presence trace was recorded; the proof stands on the shared path plus the unit test.
  • Landing order: this PR lands only after feat(ui): add This Mac settings backed by the native device bridge #137971 is merged, then rebases onto that main.
  • Config / data-model compatibility: no openclaw.json keys, defaults, schema versions, or stored representations change in this PR; the bridge writes through the same native owners the retired panes used.

steipete added a commit that referenced this pull request Sep 4, 2026
…shboard settings

Require native consent before sharing idle/activity presence with the Gateway and keep app-local settings guidance available in the offline Connection window (PR #138092).
@steipete
steipete force-pushed the steipete/mac-settings-into-dashboard branch from d920a62 to 16d3a1c Compare September 4, 2026 16:55
Route the surviving progress card directly through ChatMarkdownRenderer and remove unused skill update and construction helpers left behind by the native settings retirement. The shared iOS/macOS Periphery intersection now has no findings.
Cancel the device-settings queue and native consent when WebKit commits a
replacement document or the manager transfers the window to a new controller.
Use NSWindow.close for manager teardown so a modal sheet cannot disable the
close operation and skip the existing windowWillClose cleanup.

The real AppKit regression failed for replacement, committed navigation, and
close before this change; all four cases now pass in an isolated macOS VM.
The complete 22-test Dashboard window ownership suite also passes.

Replace the failing iOS Watch settlement test's busy-yield waits with buffered
receipt and warning callbacks, retaining the two-second deadline and every
settlement, sibling-send, and no-replay assertion. Exact-head iOS CI must verify
that fixture repair in the original suite order.

Validation: both native builds, 24 focused tests, strict Periphery with no
findings, Swift lint/format, native localization, docs checks, and Codex P2
review pass. Document consent retirement and remove a duplicated docs paragraph.
Keep the six Dock icon designs introduced on main reachable after retiring
General Settings. Advertise the existing native preference and available
artwork through the device bridge, and render the acknowledged selection
in This Mac. Remove the retired SwiftUI picker and its unused helpers.

Validate the native enum and artwork at the owner, preserve older host
snapshots, and cover parser, page, and browser request/acknowledgement flows.
Select the retained Connection health render by its current Swift Testing
identifier, preserving the sandbox and all five required image artifacts.

Suspend the Watch route-lease and reconnect fixtures on their existing
send/receipt callbacks instead of polling MainActor work. Preserve the
two-second deadlines and every journal, command, text, and no-replay check.

Hosted macOS tests passed 1,983 cases before the stale render selector
failed. The adjacent iOS lease fixture exposed the remaining polling race;
local strict-concurrency receipt proof and P2 review pass. A fresh hosted
run will verify the original iOS suite order and actual health rendering.
Use WebKit's per-message replies to return canonical native state after
consent, including Cancel and normalized values. Settle only the matching
pending draft before notifying the current Dashboard page; preserve newer
edits and reject requests from retired documents.

Extend native WebKit lifecycle and browser coverage for cancellation,
normalization, delayed replies, and navigation. Keep the coordinated
Dashboard upgrade contract and existing capability owners.
Start the held-roster browser fixture on New Session so default-enabled Swarm child hydration cannot be mistaken for a duplicate canonical request. Keep every exact dashboard and roster count, late-reply assertion, and per-tab refresh check, and assert the initial canonical query explicitly.
Commit permission completion only for the current enablement intent and requesting Dashboard document. Keep persistence and runtime refresh in the existing property observer, removing premature writes and duplicate refresh tasks.

Add cancellation regression coverage and reuse the existing Compose-aware waiter in the Android settings fixture exposed by hosted CI. Native builds, focused tests, strict Periphery, localization, full changed-file checks, Android fixture proof, and P2 review pass.
Reuse the native selected-language recognition policy in device snapshots. Keep the Dashboard explanation and allow an already-enabled setting to be turned off. Preserve interactive voice controls. The existing Talk regression fails before repair and all 53 cases pass after; native builds, Periphery, localization, changed-file checks, and P2 review pass.
Wait for each architecture fixture to report installed signal handlers before
requesting cancellation, and join the launcher through the existing Mac test
fixture lifetime before deleting its inputs. Preserve the fifteen-second test
deadline and existing outcome, assembly, process, and lock assertions.

The full changed gate reproduced the former one-second expect.poll readiness
race; explicit readiness events avoid a startup-speed dependency.
Revalidate the scope shown by native consent immediately before synchronous device settings writes. A domain revoked from another Dashboard window cannot be restored by an older Allow response. Preserve canonical snapshot replies and the Voice Wake/location permission owners.
Device settings requests now require a current, valid browser session lease, so a renewal that revokes the lease before WebKit cleanup replaces the document cannot let a stale page write settings. Dashboard failure copy points at the Connection window, and the lifecycle test waits for the real dashboard document on lease-backed loads.
The Voice Wake fence commit carried a readability-only change to an Android UI test; keep this PR scoped to the Mac and Dashboard settings surfaces.
@steipete

steipete commented Sep 5, 2026

Copy link
Copy Markdown
Contributor Author

Merged via squash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

app: ios App: ios app: macos App: macos app: web-ui App: web-ui docs Improvements or additions to documentation maintainer Maintainer-authored PR merge-risk: 🚨 compatibility 🚨 May break existing users, config, migrations, defaults, or upgrade paths. 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. scripts Repository scripts size: XL 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.

1 participant