Skip to content

fix(ci): Build the native test heads again (6.8) - #25552

Draft
agneszitte wants to merge 5 commits into
servicing/6.8from
dev/agzi/fix-68-native-heads
Draft

agneszitte wants to merge 5 commits into
servicing/6.8from
dev/agzi/fix-68-native-heads

Conversation

@agneszitte

@agneszitte agneszitte commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

GitHub Issue: related to #25551

PR Type:

🏗️ Build or CI related changes

What changed? 🚀

servicing/6.8 branch builds have failed on the WASM Native and Android Native heads since the branch was created (2026-09-02): runtime tests and one sample don't compile there. PR builds skip those stages, so the backports that broke them merged green. One commit per concern:

  • Runtime tests compile on the native heads: the Given_WebView2 iframe tests and Given_DisplayInformation_FrameBufferOrientation are Skia-only (they use WasmSemanticDomHelper, BrowserHtmlElement and Application.Host, which the native heads don't build); Given_Visual_ArrangePending is partial (the native Android generator extends its nested panel); TextContextMenuHelper filters UIElements, which are views on native Android.
  • The WASM accessibility lifecycle tests are excluded from the native heads, like the other Given_Accessible* tests: Given_WasmAccessibilityLifecycle (from ci: Backport master's CI fixes to 6.8 #25725) uses WasmSemanticDomHelper, which those heads don't build (CS0234 on Android Native and WASM Native since 2026-10-27).
  • The native scroll negotiation sample guards its Uno.UI.NativeElementHosting using with __SKIA__, like all its uses.
  • 9 runtime tests that never passed on native WASM are excluded there (they still run on Skia): two Given_FocusManager page-navigation tests, the detached-Hyperlink focus tests (Detached elements can receive or retain keyboard focus #23750), the ItemContainer touch-scroll test (Pointer events are not raised for ListView items when ItemContainer is used inside ItemTemplate #23892), the NavigationView top-nav overflow test ([Skia] NavigationView "Index was out of range" after resizing when PaneDisplayMode="Top" #20193), and Given_WindowCollectibleEventPrune, which already excluded Skia WASM for the same GC reason. They failed on every native WASM run of the 6.7 and 6.8 branch builds since they were added (6.7 since 2026-08-04, 6.8 since 2026-09-02), so this documents a known gap rather than hiding a regression.

Validation (local, CI's commands, Release):

  • SamplesApp.netcoremobile (-f net10.0-android -p:UnoTargetFrameworkOverride=net10.0-android) builds. Before: CS0260 and CS0234; each fix uncovered the next error (CS1929, then CS0234 in the sample).
  • SamplesApp.Wasm (-p:UnoTargetFrameworkOverride=net10.0) builds. Before: CS0103 and CS1061.
  • Rebased on servicing/6.8 on 2026-10-28 and built again with both commands: both pass.
  • PR CI skips the native stages, so the branch build after merge is the CI proof.

Same fixes for 6.7: #25553. Not covered: the intermittent macOS Skia runtime-test crash, which master has too.

PR Checklist ✅

🤖 Generated with Claude Code

@github-actions github-actions Bot added the area/automation Categorizes an issue or PR as relevant to project automation label Oct 16, 2026
@github-actions

github-actions Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @agneszitte's task in 2m 5s —— View job


Review: ship ✅

Todo list:

  • Gather context (PR description, changed files, diff)
  • Review diff against AGENTS.md / .claude/rules/* (platform-targeting, runtime-tests, code-style, debugging-discipline, samples)
  • Post inline comments for findings (none — see below)
  • Post summary

Verdict

No inline findings. This is a tightly-scoped, CI-only fix with no behavioral/production code changes, and each change checks out as correct on inspection:

  • #if HAS_UNO → #if __SKIA__ in Given_DisplayInformation_FrameBufferOrientation.cs and the Uno.UI.NativeElementHosting using in BrowserHtmlElement_NativeScrollNegotiation.xaml.cs — verified Application.Host/BrowserHtmlElement are Skia-only, and the sample's other __SKIA__-guarded members (_nativeElement, ctor body, event handlers) already used the narrower guard, so the using/import now matches its own usage.
  • TextContextMenuHelper.FindCommand: switching .OfType<DependencyObject>() → .OfType<UIElement>() before .EnumerateDescendants() is correct, not just a style change — on native Android, EnumerateDescendants extends _View = Android.Views.View, and UIElement (a real class there, inheriting the native view hierarchy per DependencyObject-is-an-interface-on-Android) implicitly converts to it, while DependencyObject (interface) does not. Confirmed by reading ViewExtensions.visual-tree.cs's conditional _View alias.
  • Given_Visual_ArrangePending made partial: confirmed its nested NeverArrangesChildrenPanel is itself partial class ... : Panel at line 117, consistent with a native-Android source generator extending it — the outer class needs to be partial too.
  • Given_WindowCollectibleEventPrune: RuntimeTestPlatforms.SkiaWasm → RuntimeTestPlatforms.Wasm (Wasm = NativeWasm | SkiaWasm per RuntimeTestPlatforms.cs) extends the existing GC non-determinism exclusion to native WASM too — consistent with the unchanged comment above it, which already talks about "WASM" generally, not just Skia WASM.
  • Given_WebView2.cs: the new #if __SKIA__ block is balanced (opens after the always-needed usings, wraps the two DOM-reading tests + their Skia-only helpers, closes before the class's closing brace) and the file's pre-existing #if HAS_UNO_WINUI / trailing #endif are untouched.
  • New [PlatformCondition(ConditionMode.Exclude, RuntimeTestPlatforms.NativeWasm)] additions (Given_ItemContainer, Given_NavigationView, Given_FocusManager ×2, Given_FocusManager_DetachedElements ×2) each carry a GitHubWorkItem link and an explanatory comment, which is the documented-known-gap pattern from .claude/rules/runtime-tests.md (attribute-based skip, not #if around [TestMethod]) rather than a silent/undocumented skip.
  • Commits are small, single-concern, and Conventional-Commits-formatted (fix(samples), test ×3).

No SOLID/DI/async/DP concerns apply — this PR touches no production logic, only compile guards and test platform conditions.

@agneszitte agneszitte added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Oct 16, 2026
@github-actions github-actions Bot added the area/build Categorizes an issue or PR as relevant to build infrastructure label Oct 16, 2026
@github-actions

github-actions Bot commented Oct 16, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @agneszitte's task in 1m 4s —— View job


Review: ship ✅

Todo list:

  • Gather context (diff vs origin/servicing/6.8, PR description, changed files)
  • Review diff against AGENTS.md / .claude/rules/* (platform-targeting, runtime-tests, code-style, debugging-discipline, samples)
  • Post inline comments for findings (none)
  • Post summary

Findings: 0 blocking, 0 non-blocking

Re-reviewed the full current diff (5 commits, same 14 files as the original review, now including db3759fc). No inline comments posted.

  • The four C#/test-only commits (3a5353f9, d69fd4ba, a42d05d0, 6f9aa0a7) are unchanged from the prior review pass and verify correct on inspection: __SKIA__ guards now match the actual Skia-only surface they wrap (Application.Host, BrowserHtmlElement, WasmSemanticDomHelper), Given_Visual_ArrangePending needs partial because its nested panel already is, TextContextMenuHelper.FindCommand switching to OfType<UIElement>() is required (not stylistic) for EnumerateDescendants() to resolve against the native Android view type, and every new native-WASM exclusion carries a [GitHubWorkItem]/explanatory comment documenting a pre-existing gap rather than hiding one.
  • db3759fc (new since the last pass) is CI-only: it temporarily loosens condition: on packages_tests/wasm_tests/android_tests/test_finalization and three Android/Linux test jobs so this PR's build exercises the native stages that PR builds normally skip. Each change is self-documented (# TEMP (#25552): ... Revert before merging.) and the PR already carries do-not-merge/work-in-progress — flagging as a reminder, not a defect, that these five CI conditions need reverting before this merges.
  • No production logic is touched anywhere in the diff — only compile guards, test platform conditions, and CI stage gating.

@unodevops

Copy link
Copy Markdown
Contributor

🤖 Your WebAssembly Sample App stage site is ready! Visit it here:

1 similar comment
@unodevops

Copy link
Copy Markdown
Contributor

🤖 Your WebAssembly Sample App stage site is ready! Visit it here:

@nventive-devops

Copy link
Copy Markdown
Contributor

The build 240006 did not find any UI Test snapshots differences.

@unodevops

Copy link
Copy Markdown
Contributor

⚠️⚠️ The build 240006 has failed on Uno.UI - CI.

agneszitte and others added 5 commits October 28, 2026 02:10
The WASM Native and Android Native heads stopped compiling the runtime
tests on servicing/6.8 (failing on every branch build since at least
2026-10-02):

- Given_WebView2's iframe tests use WasmSemanticDomHelper and
  BrowserHtmlElement, which those heads don't build. They only run on
  Skia WASM, so they are now Skia-only.
- Given_DisplayInformation_FrameBufferOrientation uses Application.Host,
  which only exists on Skia. It only runs on the framebuffer host.
- Given_Visual_ArrangePending must be partial: on native Android the
  source generator extends its nested panel.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
These have failed on every native WASM run of the 6.7 and 6.8 branch
builds since they were added (6.7 since 2026-08-04, 6.8 since
2026-09-02): two FocusManager page-navigation tests, the detached
Hyperlink focus tests (#23750), the ItemContainer touch-scroll test
(#23892), the NavigationView top-nav overflow test (#20193) and the
collectible-subscriber prune test, which already excludes Skia WASM for
the same GC reason. They stay covered on the Skia heads.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
On native Android, EnumerateDescendants extends Android views, which a
DependencyObject isn't (CS1929). Popup children are UIElements, which
are views there and DependencyObjects elsewhere. The compiler only
reported this once the earlier errors on that head were fixed.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…droid

Its Uno.UI.NativeElementHosting using was guarded by HAS_UNO, but the
namespace only exists on Skia (CS0234 on the native Android head). All
its uses are already under __SKIA__, so the using now is too.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…heads

Given_WasmAccessibilityLifecycle (from #25725) uses WasmSemanticDomHelper,
which the native Android and WASM heads don't build, so they failed with
CS0234. Exclude it like the other Given_Accessible* tests there.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@agneszitte
agneszitte force-pushed the dev/agzi/fix-68-native-heads branch from db3759f to 51b4720 Compare October 28, 2026 06:22
@github-actions

github-actions Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Claude finished @agneszitte's task in 2m 23s —— View job


Review: ship ✅

Todo list:

  • Gather context (diff vs origin/servicing/6.8, prior review history, new commits since last pass)
  • Review diff against AGENTS.md / .claude/rules/* (platform-targeting, runtime-tests, code-style, debugging-discipline, samples)
  • Post inline comments for findings (none)
  • Post summary

Findings: 0 blocking, 0 non-blocking

Current HEAD is 5 commits / 12 files (the earlier db3759fc temporary CI-condition-loosening commit flagged in my prior pass is no longer present, so that concern is resolved). The four commits already reviewed previously (5385e3da, 8e196369, d60ae622, f52714cd) are unchanged in substance and still verify correct on inspection.

The one commit new since the last review pass, 51b47203 ("Exclude the WASM accessibility lifecycle tests from the native heads"), adds Given_WasmAccessibilityLifecycle.cs to the existing <Compile Remove> ItemGroup in both Uno.UI.RuntimeTests.Wasm.csproj and Uno.UI.RuntimeTests.netcoremobile.csproj. I checked this against .claude/rules/platform-targeting.md's "never use Compile Remove for suffixes in a .csproj" rule — it doesn't apply here: this isn't suffix-based exclusion, it's excluding one explicitly named file from the native-head-specific projects so it only compiles in Uno.UI.RuntimeTests.Skia.csproj, exactly matching the pre-existing precedent in the same ItemGroup (Given_Accessible*.cs, WasmSemanticDomHelper.cs), which exists for the identical reason (the file depends on WasmSemanticDomHelper/Skia-WASM-DOM APIs the native heads don't build). Consistent with precedent, not a new pattern.

Cross-cutting note (non-blocking)

The PR description's bullet list doesn't mention the Given_WasmAccessibilityLifecycle exclusion specifically — worth a one-line addition to the description for completeness, but not a code issue.

No production logic is touched anywhere in the diff — only compile guards, test platform conditions, and test-project compile inclusion.
(branch)

agneszitte added a commit that referenced this pull request Oct 28, 2026
They read the browser DOM through WasmSemanticDomHelper and
BrowserHtmlElement, which the native heads don't build, so native Android
failed with CS0234 since #25780. Same change as on servicing/6.8 (#25552).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@unodevops

Copy link
Copy Markdown
Contributor

🤖 Your WebAssembly Sample App stage site is ready! Visit it here:

@nventive-devops

Copy link
Copy Markdown
Contributor

The build 241935 did not find any UI Test snapshots differences.

@mergify

mergify Bot commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

This pull request is a draft, so it cannot be queued yet. Mark it as ready for review to get the box back.

@agneszitte
agneszitte marked this pull request as draft October 28, 2026 21:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/automation Categorizes an issue or PR as relevant to project automation area/build Categorizes an issue or PR as relevant to build infrastructure do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants