Skip to content

fix: allow assistive tools to invoke onboarding actions - #1797

Draft
paulcam206 wants to merge 3 commits into
openclaw:mainfrom
paulcam206:draft/hub-onboarding-automation
Draft

paulcam206 wants to merge 3 commits into
openclaw:mainfrom
paulcam206:draft/hub-onboarding-automation

Conversation

@paulcam206

@paulcam206 paulcam206 commented Oct 21, 2026 •

Copy link
Copy Markdown
Contributor

What Problem This Solves

Fixes: assistive tools cannot invoke some visible onboarding action cards through their native automation contract.

User Impact

User impact: Accessible automation can invoke the same visible onboarding choices as a user, without private completion flags or bypassing normal consent.

DRAFT. Final standalone source passed full build, Shared/private Tray closeout and 24/24 mounted/native-UIA behavior cases. These use synthetic provider/native-runtime dependencies, not live model/package operations or native pixels. Genuine installed onboarding in combined integration63a remains separately attributed historical evidence.

Why This Change Was Made

Expose the existing action-card invocation through the native UI Automation peer and keep normal busy, ownership, verification and completion gates. Preserve the existing setup and composition owners.

The two lost coverage contracts are now protected behaviorally: mounted Local AI/hosted-provider grouping, manual-input placement, selection versus activation and bound-candidate invocation; and verified completion re-verification, all three destinations, no footer bypass and error-only recovery through the owning AI page. Normal Gateway review also hides competing Local AI setup. The compound Local AI card is unchanged; API-key and recommended-template cards reuse the guarded action adapter.

Typed test friend access replaces implementation reflection. A named test-project reference alias resolves the existing linked FluentIconCatalog ambiguity without a production namespace change.

Landing coordination: the independent onboarding drafts share the canonical MountedControlCapture.cs helper path. Neither requires the other to build; whichever lands second must rebase and retain the other split's reviewed helper changes, including requested-capture geometry diagnostics.

Continuity and onboarding automation remove different, non-overlapping old cases in NativeCompletionPresentationTests.cs. Rebase whichever lands second before final review.

Evidence

Actual running-Companion attempt and remaining credential constraint

The published branch is independent and remains DRAFT. No real provider/model or completion-card invocation pass is claimed. The existing mounted/native-UIA tests and the additional running-app evidence below are distinct.

Private-desktop dependency: the independent current head cannot reach its normal app entrypoint on the private desktop without #1783 (fix: open the Hub when private desktop shell services are unavailable). Exact current-head startup output:

[2026-10-21 19:28:07.863] [ERROR] OnLaunched failed: System.NotImplementedException: Not implemented
SetShownInSwitchers failed.
at WindowManager.InitializeRuntimeAnchor() ... WindowManager.cs:line127
at App.InitializeTrayIcon()
at App.OnLaunchedAsync()

No Default-desktop slot was available. The explicitly approved proof-only composition is COMBINED #1797 + #1783:

  • Target PR head: 09fb0621a56f864717ff714e1b3cd547fa8e3ba1.
  • Startup head: e16d2f9f4070f91aa1da4958c712c0c0ab80436b.
  • Local runtime proof commit: d02d3bd3b7b7d1cdf1d285b4cd7ae3f6ecb9cd7c, never pushed.
  • All17target-PR changed owner files are byte-identical to this independent PR head. The overlay contains only the published startup runtime owners and its published behavioral startup coverage/obsolete-source-guard deletion, not AI logic changes.

The COMBINED tree passed ./build.ps1, Shared4,635passed/25configuredskips, private-desktop Tray4,440passed/zero skipped, and focused mounted/native-UIA plus startup28/28passed. An earlier runtime-only composition had4,440Traypasses/one obsolete source-inspection assertion failure. That failure is preserved; the complete composition includes #1783's already-published deletion and real native startup tests, not a patched marker assertion or relaxed budget.

The real normal COMBINED Companion executable, using the normal installed profile and credential-owning app/CLI paths, then reached authenticated schema2Ready. It was not a preview or synthetic Gateway. The installed packaged Gateway remained OpenClaw2026.10.5 at its existing endpoint; hosting SDK1.0.1 is distinct from this branch's Windows-node SDK1.0.0.

Two normal UI entry paths were actually exercised and stopped before the changed action-card behavior:

Local AI settings:
  LocalAiModelStatus = Not installed
  Title = Local AI is not available
  Message = No supported managed Local AI profile fits this device.
            See why for the limiting requirement.
  provider/model setup entry is not exposed in that state

Forced ordinary onboarding, Existing Gateway connection editor:
  existing Gateway address supplied, password/setup-code fields untouched
  result = Enter a setup code or shared token for this gateway.
  API/provider/model and completion pages were not reached

Cached device-token reconnect Ready is not fresh credential validation. The verified installed packaging owner has only clawctl companion prepare; even --check returns credential-bearing data. There is no supported opaque Companion connect/open/pipe handoff in that owner. clawctl open targets the authenticated browser Control UI and was not repurposed. Normal app/CLI owners performed authentication; the automation did not manually read or copy credentials, print token values, put them in arguments or use the clipboard.

The noncredential native-draft descriptor was checked against redacted saved-gateway metadata: its port is the existing18789 and its logical ID is already the active published record. Re-entering the Native Gateway install/setup choice would make this source's CreateDraftAsync select another available port, so that route was deliberately not run. No second Gateway, reset, install, model change or port change was used to bypass this constraint.

After each actual run, the exact source process was cleaned up and installed Hub403 was restored through its normal packaged activation. Redacted excerpt from the actual lifecycle receipt (not an illustrative MCP response schema):

{
  "ProofKind": "COMBINED #1797 + #1783. Not standalone private-desktop entrypoint proof.",
  "TargetHead": "09fb0621a56f864717ff714e1b3cd547fa8e3ba1",
  "StartupHead": "e16d2f9f4070f91aa1da4958c712c0c0ab80436b",
  "RuntimeProofHead": "d02d3bd3b7b7d1cdf1d285b4cd7ae3f6ecb9cd7c",
  "Before": {
    "Schema": 2,
    "State": "Ready",
    "McpRunning": true,
    "Node": "Connected",
    "Operator": "Connected",
    "Paired": true
  },
  "After": {
    "Schema": 2,
    "State": "Ready",
    "McpRunning": true,
    "Node": "Connected",
    "Operator": "Connected",
    "Paired": true
  },
  "GatewayIdAndEndpointUnchanged": true,
  "ProviderAndModelUnchanged": true,
  "GatewayRestartOrInstallRequested": false,
  "ManualSecretReads": false,
  "ClipboardUsed": false,
  "CleanupIssues": []
}

Still required: a permitted normal entry/credential-delivery route to this running Companion's AI setup, followed by real provider/model and completion Invoke plus disabled/busy rejection. The present constraints do not permit manual setup-secret handling, a new credential transport or changing the shared Gateway's port. No screenshots were fabricated and the28testcases or Ready readback are not presented as that missing runtime behavior.

Current independent head: 09fb0621a56f864717ff714e1b3cd547fa8e3ba1, based on public main 2b7cfce17bb496ec5d8f0c563fb71ebb46e015fa. Published SDK1.0.0 pins unchanged. No unpublished native dependency.

Current-head CI: 17 successful checks, UI and its gate red. Actual failed UI job: unchanged NativeFallback_GatewayMoreRejectsAnOverlappingContinue times out waiting for Gateway More IsLoaded. Identical failure occurs on independent 1665 and 1750, neither changing the implicated wizard/fixture owners. Exact main2b passes the case in841ms. This is a confirmed pre-existing cross-PR failure; no exact red-main case or identical underlying timing cause is asserted. Authorized rerun was denied for missing repository-admin permission; attempt1unchanged.

The lost LocalAI/provider-group/manual-input and completion-recovery/footer coverage was replaced behaviorally, not restored as source markers. Actual mounted cases invoke native UIA/disabled controls, bind repeated choices to their own candidate, distinguish selection from activation, reverify completion for all three destinations and keep error-only recovery through the owning AI page. API/recommended cards reuse the guarded adapter; compound LocalAI is unchanged. Typed friend access and an explicit test assembly alias avoid production namespace changes.

Actual focused standalone mounted/nativeUIA24/24passed with synthetic provider/native-runtime replies. Final local review snapshotbbd1f5e787c79380f296bc5dd6b11ebac9d5bda7found no blocking code finding. That is local review, not hosted current-head review. Genuine installed combined63a UIA onboarding is historical supporting evidence only.

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: mounted action-card UIA invocation, disabled/busy behavior and visible normal onboarding completion.

Validation

Source frozen before commit, exact changed bytes verified unchanged afterward. Tray/native tests used owned private desktops and isolated state; quiet/WER/original-native-handle completion checks passed.

Command Current exact final source
.\build.ps1 PASS
dotnet test .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj --no-restore 4,635 passed, 0 failed, 25 configured skips
dotnet test .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj --no-restore 4,441 passed, 0 failed, 0 skipped; private desktop
.\scripts\validate-docs.ps1; .\scripts\validate-agent-skills.ps1; git diff --check PASS

After UI build with -r win-x64 -p:Platform=x64 -p:DevBuild=false, the following actual private native/mounted selection passed24/24with zero skips:

dotnet test .\tests\OpenClaw.Tray.UITests\OpenClaw.Tray.UITests.csproj --no-build --no-restore -r win-x64 --filter "FullyQualifiedName~OnboardingAiPageTests.CurrentModel_NativeUia|FullyQualifiedName~OnboardingAiPageTests.ApiProviderSelection_DoesNotActivate|FullyQualifiedName~OnboardingAiPageTests.AiGroups_KeepManualInputSeparate|FullyQualifiedName~OnboardingAiPageTests.OpeningApiKeys_DoesNotSubmitAnyCandidate|FullyQualifiedName~OnboardingAiPageTests.RepeatedChoiceCards_InvokeTheirOwnBoundCandidate|FullyQualifiedName~OnboardingWindowsFlowTests.NormalGatewayReview_HidesCompeting|FullyQualifiedName~NativeSharedFlowTests.CompletionFailure_ExposesOnlyErrorRecovery|FullyQualifiedName~NativeSharedFlowTests.NativeInstall_UsesSharedAiVerificationAndAllThreeDestinations|FullyQualifiedName~NativeSharedFlowTests.NativeStartupUsesVisibleChoiceAndRetainsItAcrossRegistrationRetry"

Earlier duplicate-catalog compilation, stale exact-type expectations and unrelated cancellation-fixture failures remain retained. They were repaired at the actual owner/seam, not by deleting coverage or loosening assertions. Pixel proof was not requested in this functional invocation.

Real Behavior Proof

  • Environment tested: actual mounted production WinUI controls and native UIA patterns on task-owned private desktops; synthetic provider/native-runtime responses, isolated temporary data, no installed operations.
  • PR head or commit tested: exact final source 09fb0621a56f864717ff714e1b3cd547fa8e3ba1.
  • Exact steps or command run: focused24case command above; selection without activation, native Invoke/disabled checks, repeated-template binding, normal review, re-verification, three destinations and failure recovery.
  • Evidence after fix: copied actual result:
{"Total":24,"Executed":24,"Passed":24,"Failed":0,"Unexecuted":0,"ExitCode":0,"DesktopCreatorRetainedUntilNativeExit":true,"NativeExitReceiptVerified":true}
  • Observed result: production actions keep existing guards, normal review hides competing LocalAI, and failed completion offers only error recovery rather than footer bypass. All selected native/mounted cases executed.
  • Screenshot or artifact links verified? N/A for local private TRX/ownership receipts; public current-head CI and independent failure links above. No private capture is represented as public visual proof.
  • Not verified or blocked: current-head visible native screenshots/video/compositor/input, live provider/package/pairing execution and whole interactive-pool qualification. Full hosted UI remains red on the inherited Gateway More timeout; the affected24case proof is separate.

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
  • If any answer is Yes, explain the risk and mitigation: No new permissions, credential handling, remote endpoint or product execution surface. UIA invokes the same existing visible action; busy/disabled, ownership and verification checks still govern it.

Compatibility and Migration

  • Backward compatible? Yes. Existing authenticated connection, consent and ownership contracts remain authoritative.
  • Config or environment changes? No persistent source-contract change.
  • Migration needed? No
  • If yes, list the exact upgrade steps: N/A. The separate local environment path repair is not a migration or private-file workaround shipped by this PR. Published SDK1.0.0 pins are unchanged.

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.

This remains DRAFT pending current-head hosted review and required proof. No merge is authorized.

Extract the independently reviewed reliability seam without the held native timeout consumer. No change to executor releases, package pins or sandbox enforcement.
@clawsweeper

clawsweeper Bot commented Oct 21, 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-repro 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-repro Preliminary submission classification; full source review pending. labels Oct 21, 2026
@clawsweeper

clawsweeper Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

Codex review: needs real behavior proof before merge.

What this changes

Adds native UI Automation invocation to onboarding provider, model, API-key, recommended-install, and completion cards.

Example: An assistive tool invokes the visible “Talk to my agent” completion card.

  • Before: The Toolkit peer advertises Invoke without supplying its implementation.
  • After: Invocation reaches the existing guarded completion action and model verification.

Review scores

Measure Result What it means
Overall readiness 🧂 unranked krab (1/6) The implementation is focused and the earlier coverage concerns are resolved, but the supplied running-app evidence does not exercise the changed behavior.
Proof confidence 🧂 unranked krab (1/6) Real behavior proof is necessary before merge. See Before merge.
Patch quality 🐚 platinum hermit (4/6) No actionable review findings were identified.

Product

Kind: Bug fix · Worth it: Yes · Fix scope: Complete
User problem: Assistive tools cannot invoke some visible onboarding cards through their advertised native automation contract.
Reason: Restoring an existing accessibility contract has clear value without introducing a product preference, permission, setting, or competing setup owner.

Merge readiness

⛔ Blocked before merge - 1 item remains

Keep this PR open: current main still lacks the repaired accessibility contract, and the focused adapter preserves existing action owners and resolves both earlier coverage concerns.

Priority: P2
Reviewed head: 09fb0621a56f864717ff714e1b3cd547fa8e3ba1

Before merge

  • Add real behavior proof - The full body supplies 24/24 mounted/native-UIA results with synthetic provider/runtime dependencies. The additional normal Companion attempt used a disclosed startup-only composition and stopped at unavailable Local AI or missing Gateway credentials before reaching the changed cards; both inspected screenshots show that credential error. Attach screenshots/video or redacted UIA diagnostics from running Companion onboarding showing provider/model and completion invocation plus disabled/busy rejection, with IPs, keys, phone numbers, and private endpoints redacted, then request re-review. After adding proof, update the PR body, then request a new review with @clawsweeper re-review. The PR author or someone with repository write access can request it.

Findings

None.

Tests

  • Missing end-to-end proof: Running Companion evidence still needs provider/model and completion Invoke plus disabled/busy rejection, and an intended pre-fix failure run is not supplied.
Agent review details

How this fits together

SetupEngine UI renders onboarding choices and forwards user clicks or automation requests to the existing AI setup controller and verified completion coordinator.

flowchart LR
 A[Assistive tool] --> B[Native UI Automation]
 B --> C[SetupActionCard]
 D[User click] --> C
 C --> E[Guarded page action]
 E --> F[Existing setup coordinator]
Loading

Technical review

Best possible solution:

Retain the focused Invoke adapter and behavioral coverage while preserving existing setup, consent, ownership, and completion guards.

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

Current-main cards, the existing test-helper workaround, and the directly inherited Toolkit peer identify the failing Invoke path; this read-only review did not execute it or independently verify the exact package binary.

Is this the best way to solve the issue?

The small SettingsCard-derived adapter repairs the native invocation boundary while retaining Toolkit presentation and existing action owners.

AGENTS.md: found and applied where relevant.

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

Provenance checked

  • Provider/model and completion-card actions keeps the original intent (feat: guide Windows onboarding from setup to native AI tasks #1531: Shared onboarding uses explicit AI choices, exact-model verification, and guarded destination selection; the PR preserves those decisions.)
  • Local AI grouping and recommended-install cards keeps the original intent (4e069e4: Place detected AI first and preserve distinct local and cloud choices, discovery, and explicit selection.)
  • Framework card-invocation helper changes intended behavior with a stated reason (2e5e219: Wait for the exact mounted card to become ready; the PR explains using the repaired native provider while retaining readiness checks.)
  • Onboarding presentation and completion source guards keeps the original intent (feat: guide Windows onboarding from setup to native AI tasks #1531: Protect explicit selection, independent Local AI ownership, verified completion, and error-only recovery; mounted behavior checks replace the relevant source assertions.)

Testing

Proof path: in-process harness.

Security

None.

Evidence

What I checked:

Likely related people:

  • Scott Hanselman: Raw commit 2e5e219 adds tests/OpenClaw.Tray.UITests/TestSupport.cs:26 relative to its recorded parents. This identifies author metadata, not feature responsibility or a PR merger. (role: source-line author; confidence: high; commits: 2e5e219ade50; files: tests/OpenClaw.Tray.UITests/TestSupport.cs)

Labels

Label changes:

  • add proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

Label justifications:

  • P2: Repairs a bounded native accessibility invocation contract without evidence that ordinary interactive onboarding is wholly blocked.
  • rating: 🧂 unranked krab: Overall readiness is 🧂 unranked krab; proof is 🧂 unranked krab and patch quality is 🐚 platinum hermit.
  • status: 📣 needs proof: The PR needs real behavior proof before ClawSweeper can clear the contributor ask.
  • proof: 📸 screenshot: Contributor real behavior proof includes screenshot evidence.

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-21T04:27:26.488Z sha f759cd4 :: needs real behavior proof before merge. :: [P3] Restore the independent Local AI ownership assertions | [P3] Preserve the completion chooser's remaining contract checks
  • reviewed 2026-10-21T20:18:39.311Z sha 09fb062 :: needs real behavior proof before merge. :: none

Reviewed October 22, 2026, 12:19 AM ET / 04:19 UTC (Revision 3).

@paulcam206

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

🦞👀
Exact review queued.

Re-review progress:

@paulcam206

Copy link
Copy Markdown
Contributor Author

@clawsweeper re-review

@clawsweeper

clawsweeper Bot commented Oct 22, 2026 •

Copy link
Copy Markdown

🦞👀
Exact review queued.

Re-review progress:

@clawsweeper clawsweeper Bot added the proof: 📸 screenshot Contributor real behavior proof includes screenshot evidence. label Oct 22, 2026

This branch has not been deployed

No deployments
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. 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.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant