Skip to content

fix: setup choices disappear and UI checks fail before controls are ready - #2115

Merged
bkudiess merged 2 commits into
openclaw:mainfrom
bkudiess:bkudiess-ci-fixes-integration
Nov 11, 2026
Merged

bkudiess merged 2 commits into
openclaw:mainfrom
bkudiess:bkudiess-ci-fixes-integration

Conversation

@bkudiess

Copy link
Copy Markdown
Collaborator

What Problem This Solves

Fixes missing setup choices and misleading CI failures when native controls are not ready, windowless XAML peers report PID zero, or isolated Gateway cleanup is incomplete.

User Impact

User impact: setup keeps its More choices across pre-mount/reset transitions; developers get stricter, more faithful native tests and preserve isolated fixture data when uninstall cannot be verified.

Draft, not merge-ready: required independent review is blocked, real WSL/MXC proof remains unverified, and target main has advanced beyond the locally tested base. No historical native crash or lost-draft cause is claimed fixed.

Why This Change Was Made

  • Keep setup expansion under its stable XAML owner instead of depending on a not-yet-mounted parent.
  • Validate native window/process ancestry rather than treating a zero leaf PID as either ownership or a foreign process. Preserve negative controls, foreground, geometry, capture and keyboard assertions.
  • Wait for the actual dialog/search/layout state, preserve current main's stronger Usage aperture checks, and restore scroll position after failures.
  • Make fixture cleanup fail closed and MCP readiness observations redacted. Keep ordinary rollback; exclude session-only external ownership hooks.
  • Remove docs/CI_FAILURES.md and its backlinks. Contributors must investigate, fix and validate failures, or report a concrete blocker; deleting the backlog does not close unresolved bugs.

Evidence

Current-source check Result
Full repository, managed test projects, native Debug and non-Dev Release builds Passed
Full Shared suite 5,764 passed, 28 permitted skips, 0 failed
Full Tray suite 6,277 passed, 0 skipped or failed
Fixture-free readiness/cleanup E2E selection 24/24 passed
Selected native Debug cases 64/64 passed, 0 skipped
Selected non-Dev Release fixture cases 22/22 passed, 0 skipped
Documentation/skill/whitespace checks Passed

Proof was collected from an exact uncommitted source snapshot based on 994539b8b6f51182841e62247357f31cac7ed6e4: normalized Git tree 9a23fb46efc6f7954c51e1cde6137bace0a38b3e, 2,460-file SHA256 manifest 4E9F61DD2F335A8FC184A63F83924DB56C61F7D2335DCFCDE6DA0438BC5738D7. Committing identical source does not constitute a new runtime run.

Earlier failed attempts are retained. The corrected Inbox-to-Automations ownership path passed. Keyboard/window foreground failures required an explicitly approved elevated guest-console launch; console route and elevation changed together, so this is not an isolated cause or ordinary unelevated keyboard proof. A later locked-desktop admission stopped before launching the last four Release cases; those four subsequently passed after access was restored.

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 component, UIA ownership, real-app fixture, keyboard and capture contracts. The selected 64 Debug and 22 Release cases passed; this is not a claim that the entire pool ran.
  • windows-wsl-gateway-e2e: changed shared E2E readiness/teardown fixture. Pure helper tests passed; the real Gateway path is not verified / blocked.
  • windows-wsl-mxc: required setup/connect/MXC boundary remains not verified / blocked. No AllowSkip result is used as proof.
  • windows-11-arm64: native ARM64 behavior remains not verified / blocked; all local runtime proof here is x64.

Validation

The commands below retain the executed flags and filters; $repo and $results denote the exact frozen checkout and each fresh, private result directory. Test execution used the repository wrapper against source-bound prebuilt assemblies, rather than claiming additional project-mode dotnet test --no-restore runs.

# Passed. Matching Shared/Tray/E2E test-project builds also passed.
pwsh -NoProfile -File .\build.ps1
dotnet build .\tests\OpenClaw.Shared.Tests\OpenClaw.Shared.Tests.csproj -c Debug -m:1 -p:BuildInParallel=false -p:UseSharedCompilation=false -nr:false -v:minimal --no-restore
dotnet build .\tests\OpenClaw.Tray.Tests\OpenClaw.Tray.Tests.csproj -c Debug -m:1 -p:BuildInParallel=false -p:UseSharedCompilation=false -nr:false -v:minimal --no-restore
dotnet build .\tests\OpenClaw.E2ETests\OpenClaw.E2ETests.csproj -r win-x64 -c Debug -m:1 -p:BuildInParallel=false -p:UseSharedCompilation=false -nr:false -v:minimal --no-restore

# Passed: native Debug and production-shaped unsigned Release fixture builds.
dotnet build .\tests\OpenClaw.Tray.UITests\OpenClaw.Tray.UITests.csproj -r win-x64 -p:Platform=x64 -c Debug -m:1 -p:BuildInParallel=false -p:UseSharedCompilation=false -nr:false -v:minimal --no-restore
dotnet build .\tests\OpenClaw.Tray.UITests\OpenClaw.Tray.UITests.csproj -c Release -r win-x64 -p:DevBuild=false -p:RequireSignedCleanupHost=false -m:1 -p:BuildInParallel=false -p:UseSharedCompilation=false -nr:false -v:minimal --no-restore

# Passed: 5,764 / 28 permitted skips / 0 failed.
pwsh -NoProfile -File "$repo\scripts\Invoke-CiTest.ps1" -Project "$repo\tests\OpenClaw.Shared.Tests\bin\Debug\net10.0\OpenClaw.Shared.Tests.dll" -ResultsDirectory "$results" -TrxFileName CanonicalShared.trx -Configuration Debug -HangTimeoutSeconds 300

# Passed: 6,277 / 0 skipped / 0 failed, in the owned guest.
pwsh -NoProfile -File "$repo\scripts\Invoke-CiTest.ps1" -Project "$repo\tests\OpenClaw.Tray.Tests\bin\Debug\net10.0\OpenClaw.Tray.Tests.dll" -ResultsDirectory "$results" -TrxFileName Debug-Tray.trx -Configuration Debug -ExpectedTestCount 6277 -HangTimeoutSeconds 300 -CaptureHostExit -RequireAllTestsPassed

# Discovery found exactly 24; execution passed 24 / 0 skipped / 0 failed.
$filter = 'FullyQualifiedName~SetupAndConnectTestsMcpReadiness|FullyQualifiedName~SetupAndConnectTestsUninstallIsolation'
pwsh -NoProfile -File "$repo\scripts\Invoke-CiTest.ps1" -Project "$repo\tests\OpenClaw.E2ETests\bin\Debug\net10.0-windows\win-x64\OpenClaw.E2ETests.dll" -ResultsDirectory "$results" -TrxFileName PureE2E24.trx -Configuration Debug -Runtime win-x64 -Filter $filter -HangTimeoutSeconds 300 -ExpectedTestCount 24 -RequireAllTestsPassed

# Passed: docs 73 files / 7 pools; skills 17 / 28 files; validator 27 fixtures.
.\scripts\validate-docs.ps1
.\scripts\validate-agent-skills.ps1
.\scripts\test-agent-skills-validator.ps1
git diff --check

Native invocations used this command shape with the exact selections below, a fresh result root per group, all three isolated profile roots, and the matching built app:

# Debug: bin\x64\Debug\...\win-x64; Release: bin\Release\...\win-x64.
pwsh -NoProfile -File "$repo\scripts\Invoke-CiTest.ps1" -Project "$assembly" -ResultsDirectory "$results" -TrxFileName "$label.trx" -Runtime win-x64 -Configuration $configuration -Filter $filter -ExpectedTestCount $expected -HangTimeoutSeconds 300 -CaptureHostExit -RequireAllTestsPassed

Fixture groups used OPENCLAW_RUN_GATEWAY_FIXTURE_UI=1, the exact OPENCLAW_GATEWAY_FIXTURE_APP, synthetic artifact roots and screenshot opt-in. Keyboard group 5 additionally used OPENCLAW_RUN_KEYBOARD_PROOF=1. Group 1 uses the ordinary workspace fixture. No live WSL/Gateway opt-ins were enabled.

Exact native selections and results

The following filters are the exact values supplied to -Filter. Each fixture filter ran in both configurations. Expected counts were enforced with -ExpectedTestCount and -RequireAllTestsPassed.

Selection Debug Release
Components 42/42 Not selected
Workspace 5/5 5/5
Sidebar and continuity 2/2 2/2
Modal navigation 6/6 6/6
Inbox and notifications 5/5 5/5
Keyboard and clipboard 3/3 3/3
Usage 1/1 1/1
# Components
$filter = 'FullyQualifiedName~NativeSharedFlowTests.WizardMore_|FullyQualifiedName~NativeSharedFlowTests.NativeFallback_GatewayMore|FullyQualifiedName~NativeUiOwnershipTests|FullyQualifiedName~A2UISvgTests|FullyQualifiedName~ReactorChatLayoutProofTests.QueuedMessages_RenderCompactPanelAndPreserveSendLifecycle|FullyQualifiedName~SystemsPageProofTests.Hero_StateMatrixRetainsFocusAndGeometryAcrossMountedWidths|FullyQualifiedName~SystemsPageProofTests.NarrowDialog_StacksFactsAndFooterWithoutChangingDestructiveFocus|FullyQualifiedName~SystemsPageProofTests.AddAndForgetDialogs_ExposeConsequencesAndSafeDefaults|FullyQualifiedName~SystemsPageProofTests.ExpandedResources_AfterDisconnect_RetainHeadingsAndVisibleLastKnownLabels|FullyQualifiedName~SystemsPageProofTests.ForgetConfirmation_AfterGatewayChange_CannotSubmit'
# Workspace
$filter = 'FullyQualifiedName~WorkspaceWindowProofTests.SettingsChrome_SearchAndBidirectionalHistory_StayBelowNativeTitle|FullyQualifiedName~WorkspaceWindowProofTests.SettingsBackToApp_ReturnsToAppDestinationInSameWindow'
# Sidebar and continuity
$filter = 'FullyQualifiedName~GatewayFixtureUiTests.HomeSidebar_CustomizeDoesNotNavigate_AndHomeRestoresCanonicalConversation|FullyQualifiedName~GatewayFixtureUiTests.SelectedAssistantAndConversationSurviveTransientRosterLossButNotAuthoritativeRemoval'
# Modal navigation
$filter = 'FullyQualifiedName~GatewayFixtureUiTests.SharedRootDialog_DefersNavigationAndRejectsNativeBinding|FullyQualifiedName~GatewayFixtureUiTests.SettingsDisconnectPruning_WaitsForRealDialogBeforeRenderingFallbackOrLatestIntent'
# Inbox and notifications
$filter = 'FullyQualifiedName~GatewayFixtureUiTests.InboxFeed_|FullyQualifiedName~GatewayFixtureUiTests.NotificationAction_'
# Keyboard and clipboard
$filter = 'FullyQualifiedName~GatewayFixtureUiTests.ConfigRemove_KeyboardReachabilityAndDiscardRestoresRows|FullyQualifiedName~GatewayFixtureUiTests.NotificationOptions_ExposeContextAndSupportKeyboardTraversal|FullyQualifiedName~GatewayFixtureUiTests.ClipboardExpander_SupportsKeyboardSelectionAndCollapse'
# Usage
$filter = 'FullyQualifiedName~GatewayFixtureUiTests.UsageHero_RealShellCapturesCardAndRangeInLightAndDark'

Local case-inventory SHA256: 19766D555E335AD9F9EBE399FF57E2FFB8F9808C3CADD8E5904316EC40EE3E5E. Only a helper body changed in the final revision; the selected declarations and expected counts stayed unchanged.

Real Behavior Proof

  • Environment tested: native x64 Windows Sandbox, networking and host clipboard sharing disabled; isolated synthetic profiles. Debug and non-Dev Release were built separately on NTFS. Release used the existing unsigned fixture setting, not signed-release acceptance.
  • PR head or commit tested: base 994539b8b6f51182841e62247357f31cac7ed6e4 plus the 32-path working change, exact tree 9a23fb46efc6f7954c51e1cde6137bace0a38b3e and source manifest above. Publication must retain that exact tree.
  • Exact steps or command run: source/binary hash admission, desktop and process admission, then the native selections above; every expected method/case count matched with zero skips. Earlier failures and pre-launch admission blocks were preserved.
  • Evidence after fix: owned-window screenshot/hash metadata shows the referenced Automations destination, reconnect/send/removal states, and complete Usage session details in Light/Dark with the shell-minimum hero restored. Representative Release frames were inspected. Native ownership negative controls reject other windows, wrong PIDs and unverifiable owners.
  • Observed result: 64 Debug and 22 Release selected cases passed; all 2,460 source files and 2,036 Debug / 1,821 Release deployment entries remained exact after execution. No test/app processes remained; normal host-profile metadata was unchanged.
  • Screenshot or artifact links verified? (Yes/No/N/A) N/A: local artifacts were verified but are not uploaded or presented as public links. Combined closeout SHA256: 3C824720984241A34E0F00A88E59E1073A2727C528C9EBAAF4786F7D78020B51.
  • Not verified or blocked: independent source/rubber-duck review is blocked because the canonical helper refuses required unchanged TokenSanitizer.cs context as a sensitive filename. No reviewer launched and no alternative route bypassed that refusal. Real WSL/MXC, native ARM64, signed installer/release, extra Automations consumers outside the selected inventory, mounted SVG pixel/heartbeat proof and private-desktop Systems captures remain unverified. Historical Reasoning crash, lost-Space, lost-draft and ReFS corruption causes are not claimed fixed. Main was four commits ahead at publication preflight (65de1e3584b3525ae802f29f68d9ae73b3be38b9); its merge result is not covered by the local runs.

Security Impact

  • New permissions or capabilities? (Yes/No) No.
  • Secrets or tokens handling changed? (Yes/No) Yes, test-harness readiness diagnostics only. Bearer authentication remains; output is limited to fixed descriptions, status codes and exception types, never token contents.
  • New or changed network calls? (Yes/No) No new endpoints or transport. The existing authenticated loopback health poll is factored into a tested observation helper.
  • Command or tool execution surface changed? (Yes/No) No shipped command/tool surface. Session-only external guard execution was excluded.
  • Data access scope changed? (Yes/No) No expansion. Test cleanup deletes existing fixture roots only after successful uninstall and verified exact-distro absence.
  • If any answer is Yes, explain the risk and mitigation: redaction and failure-path tests cover readiness observations; unexpected client lifecycle failures surface. No production credentials or profiles were used for proof.

Compatibility and Migration

  • Backward compatible? (Yes/No) Yes; no protocol, capability or settings schema change.
  • Config or environment changes? (Yes/No) No product configuration changes. Existing isolated proof opt-ins were used.
  • Migration needed? (Yes/No) No.
  • If yes, list the exact upgrade steps: N/A.

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.

@clawsweeper

clawsweeper Bot commented Nov 11, 2026

Copy link
Copy Markdown

🦞👀
ClawSweeper picked this up.

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

@bkudiess

Copy link
Copy Markdown
Collaborator Author

@clawsweeper review

@clawsweeper

clawsweeper Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

🦞👀
Exact review queued.

Re-review progress:

@bkudiess
bkudiess marked this pull request as ready for review November 11, 2026 19:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant