chore(automation): Sync master → feature/breakingchanges#23625
chore(automation): Sync master → feature/breakingchanges#23625github-actions[bot] wants to merge 71 commits into
Conversation
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Bumps [anthropics/claude-code-action](https://github.com/anthropics/claude-code-action) from 1.0.157 to 1.0.162. - [Release notes](https://github.com/anthropics/claude-code-action/releases) - [Commits](anthropics/claude-code-action@428971d...6c0083b) --- updated-dependencies: - dependency-name: anthropics/claude-code-action dependency-version: 1.0.162 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [actions/checkout](https://github.com/actions/checkout) from 6 to 7. - [Release notes](https://github.com/actions/checkout/releases) - [Commits](actions/checkout@v6...v7) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
…actions/checkout-7 chore(deps): bump actions/checkout from 6 to 7
…anthropics/claude-code-action-1.0.162 chore(deps): bump anthropics/claude-code-action from 1.0.157 to 1.0.162
AdaptiveTrigger evaluated only against XamlRoot.Bounds and re-evaluated only on XamlRoot.Changed, so a host that simulates a form factor by resizing previewed content rather than the window could not make adaptive breakpoints re-evaluate. Add a global, opt-in size override (SetWindowSizeOverride), analogous to the Uno Toolkit ResponsiveHelper.SetOverrideSizeProvider: when set, UpdateState evaluates against it and every live trigger re-evaluates on change; passing null reverts to XamlRoot.Bounds. - No-op when the override value is unchanged - Subscribe the override event only while a XamlRoot exists, so never-loaded triggers are not rooted by the static event - Guarded Debug log on set/clear for diagnosability Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Toggling the override applies the resizable item's size via SetWindowSizeOverride, so the page's AdaptiveTrigger (MinWindowWidth=720) flips by resizing the item across the breakpoint instead of the window. The override is cleared on toggle-off and when leaving the sample. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Nick Randolph seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account. You have signed the CLA already but the status is still pending? Let us recheck it. |
chore(docs): External Docs Update - master
Fixes: #23159 Context: dotnet/runtime#4538 (comment) Context: https://github.com/unoplatform/uno/blob/ffbb0c0ed47679ede7c67effaa979e7a9934ed33/doc/articles/controls/WebView.md?plain=1#L198-L206 Use of WebView2 on Linux Wayland requires that the `GDK_BACKEND` environment variable be set, lest Bad Things Happen™. On the ignorable side, the bad things are simply messages written to stdout. For example, build and run SamplesApp.Skia.Generic: dotnet build -c Release -f net10.0 src/SamplesApp/SamplesApp.Skia.Generic/SamplesApp.Skia.Generic.csproj LD_PRELOAD=/usr/lib/aarch64-linux-gnu/libfreetype.so.6.20.1 \ dotnet src/SamplesApp/SamplesApp.Skia.Generic/bin/Release/net10.0/SamplesApp.Skia.Generic.dll (The $LD_PRELOAD is needed to avoid [a *different* problem][0], which should get fixed by updating SkiaSharp; see #23598.) Once SamplesApp.Skia.Generic has launched: 1. Click the "checkbox list" icon on the top-left to show the RuntimeTests panel. 2. In the "Enter test filter here" textbox, enter `When_ExecuteScriptAsync`. 3. Click the▶️ Run button Console output will contain messages such as: (SamplesApp.Skia.Generic:25303): Gdk-CRITICAL **: 09:20:32.946: gdk_x11_window_get_xid: assertion 'GDK_IS_X11_WINDOW (window)' failed … fail: Uno.UI.WebView.Skia.X11.X11NativeWebView[0] SetScrollingEnabled is not supported on the X11 target. … warn: Uno.WinUI.Runtime.Skia.X11.X11ApplicationHost[0] X11 protocol error — ErrorCode: 3, RequestCode: X_UnmapWindow, MinorCode: 0, ResourceId: 0x0, Serial: 428 However, the tests *pass* and the app *doesn't crash*. Enter #23159: if we build Uno.Gallery for *Native AOT* and hit the WebView2 logic, we see the same `Gdk-CRITICAL` message, *and also* these messages: fail: Uno.WinUI.Runtime.Skia.X11.X11NativeOverlappedPresenter[0] Couldn't get OverlappedPresenterState: _NET_WM_STATE does not exist on the window. Make sure you use an EWMH-compliant WM. fail: Uno.WinUI.Runtime.Skia.X11.X11NativeOverlappedPresenter[0] Couldn't get OverlappedPresenterState: _NET_WM_STATE does not exist on the window. Make sure you use an EWMH-compliant WM. followed by a *hard crash*: (Uno.Gallery:8586): Gdk-CRITICAL **: 14:46:16.851: gdk_x11_window_get_xid: assertion 'GDK_IS_X11_WINDOW (window)' failed X Error of failed request: BadWindow (invalid Window parameter) Major opcode of failed request: 3 (X_GetWindowAttributes) Resource id in failed request: 0x0 Serial number of failed request: 103 Current serial number in output stream: 104 The workaround for this, as documented in `doc/articles/controls/WebView.md`, is to export the `GDK_BACKEND` environment variable to `x11`: export GDK_BACKEND=x11 dotnet … This works, but requires reading documentation (who does that?!). The ideal fix would be to have `X11NativeWebProvider` export the environment variable during app startup. The problem is that the "obvious" way to do this: Environment.SetEnvironmentVariable("GDK_BACKEND", "x11"); [*does not work*][1] > we will not support the case where a user wants to modify the > environment from managed code and expects to see those changes > reflected in a native library they PInvoke to, or vice versa. Since we *need* native code in `libgdk*` et al to see the `GDK_BACKEND` environment variable, we can't use `Environment.SetEnvironmentVariable()` to do so. Instead, P/Invoke into **setenv**(3). This allows us to set the `GDK_BACKEND` environment variable on the native side, allowing `libdk*` et al to see the value we set and behave accordingly. With this fix in place, `SamplesApp.Skia.Generic.dll` no longer produces the `Gdk-CRITICAL` or X11 protocol error messages. [0]: #20532 (comment) [1]: dotnet/runtime#4538 (comment)
RenderTargetBitmap now records the visual tree into an SKPicture on the UI thread (mirroring the regular rendering pipeline) and replays it into a GRContext-backed surface during the CompositionTarget's next render pass, reading the pixels back into the caller's buffer. The GRContext is resolved from the draw canvas (SKCanvas.Context), so the mechanism is platform-neutral and applies to every Skia backend; when the target renders in software (raster canvas), pending render jobs fail fast and the previous raster path is used as fallback. Opting out is possible via the new FeatureConfiguration.Rendering.UseGpuRenderTargetBitmap flag, since GPU rasterization can produce slightly different anti-aliasing than the software rasterizer. RenderAsync now completes asynchronously on Skia (one render pass later) instead of synchronously inside the call. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Adds an orientation test guarding against vertically-flipped output on GPU backends with bottom-left-origin surfaces, and pins When_CornerRadius_AntiAliasing to software RenderTargetBitmap since its reference asset was rendered by the software rasterizer and GPU anti-aliasing differs slightly along the rounded edge. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
GPU rendering of RenderTargetBitmap is now always on when the target renders with a GRContext. When_CornerRadius_AntiAliasing consequently can no longer pin itself to the software rasterizer, and no RMSE threshold separates valid GPU-vs-CPU anti-aliasing variance (0.0325) from a simulated non-anti-aliased render (0.0349) on this image, so the test now asserts the invariant directly: a meaningful fraction of the pixels in a ring around the circle's edge must blend between the two colors (~34% for the CPU rasterizer, 0% for a jagged render). Its software-rendered reference asset is removed with it. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Both overloads carried identical copy-pasted bodies differing only in scaledSize and, through historical drift, in the fallback used when element is null (PublicRootVisual vs RootElement). They now share one core, unified on RootElement: the window's root visual, i.e. what is presented on screen including popups. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The hardware and software paths shared no code despite doing the same thing: both now record the SKPicture through one method (owning the layout-clip removal and the IsSoftwareRenderer record-time flag) and replay it through one method (surface, optional resampling, pixel read-back). The only difference between the two paths is the surface factory: GRContext-backed for hardware, raster for the fallback. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Runner images picked up a Homebrew version that refuses formulas from third-party taps until explicitly trusted, breaking every iOS UI test stage overnight: Error: Refusing to load formula facebook/fb/idb-companion from untrusted tap facebook/fb. Trust only the idb-companion formula (least privilege), with tap-level trust as fallback and a no-op on older brews that have no trust command. Also document what this script does and where idb comes from (sha256-pinned facebook/idb v1.1.8 artifact; tap dormant since 2022).
…ook-tap ci(ios): trust the facebook/fb tap formula required by newer Homebrew
The drag visual was captured with RenderAsync, which now completes during a later render pass; the resulting dispatcher yield broke the synchronous DragStarting -> DragStarted -> DragEnter/DragOver sequence (matching WinUI) that the drag-and-drop runtime tests assert, failing them on all Skia CI targets. The capture now uses a synchronous software render (its behavior before the GPU path was introduced), while the public RenderAsync stays asynchronous. Also hardens RenderAsync against overlapping calls on the same instance: calls are serialized with an async gate and the pending GPU replay roots the pixel buffer it writes to, so a concurrent EnsureBuffer can neither resize nor free it mid-write. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
RunRenderJobs took the canvas only to reach its GRContext; callers now resolve the context themselves. Also asserts UI-thread access in TryExecuteOnNextRenderAsync, matching the rest of the scheduling surface. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Pull request was converted to draft
d5f9017 to
6c94bdd
Compare
…ear-loop fix(datepicker): Don't loop the year column for a single year
…rline-style-property fix: Make Hyperlink.UnderlineStyleProperty public for WinUI API parity
…NativeAOT+WebView2-master feat(win32): WebView2Aot backend for <WebView2/>
…indow-size-override feat: Add host window-size override to AdaptiveTrigger
Co-authored-by: David <github.site@torick.net>
Co-authored-by: David <github.site@torick.net>
…-layout-leak fix(ItemsView): drop leaking DEBUG layout-invalidation diagnostics
…ng-tests test: Add ContextRequested bubbling regression tests
…ux-nativeassets fix(sdk): align Linux SkiaSharp native asset on desktop
…ync/feature/breakingchanges # Conflicts: # build/test-scripts/ios-uitest-run.sh # src/Uno.UI/UI/Xaml/Media/Imaging/RenderTargetBitmap.cs
a84436c to
17415a9
Compare
RenderTargetBitmap: keep master's async RenderAsync refactor while preserving feature/breakingchanges' native drop (#if __SKIA__ guard). ios-uitest-run.sh: take master's robust idb-companion trust block. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Mr8yh7TH7BHLD4PP7keeHc
…ature/breakingchanges
There was a problem hiding this comment.
Pull request overview
Automated merge-sync of master into feature/breakingchanges, bringing in a broad set of upstream fixes and improvements across Uno.UI rendering (Skia), DevServer/add-in hosting, WebView2 backends (including NativeAOT), diagnostics/ALC leak mitigation, and test coverage expansions.
Changes:
- Skia RenderTargetBitmap: add GPU-thread render-job execution path, serialized async rendering, and a synchronous capture path for drag visuals.
- DevServer/add-ins: improve assembly resolution (bridge + on-demand probing), quarantine failing add-in hosted services, and add a CLI “safe mode” retry when startup crashes before readiness.
- Fix multiple retention/leak scenarios (TreeView item maps, diagnostics overlay notifications/materialization) and add/adjust unit/runtime tests plus docs.
Reviewed changes
Copilot reviewed 52 out of 53 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/Uno.UI/UI/Xaml/UIElement.Pointers.cs | Uses Skia-only synchronous RenderTargetBitmap capture for drag visuals to preserve WinUI-like sequencing. |
| src/Uno.UI/UI/Xaml/Media/Imaging/RenderTargetBitmap.skia.cs | Reworks Skia RenderTargetBitmap to record on UI thread and replay on render thread (GPU when available), with serialization gate + software fallback and RenderSync. |
| src/Uno.UI/UI/Xaml/Media/Imaging/RenderTargetBitmap.cs | Consolidates RenderAsync paths and introduces async wrapper for non-Skia implementations; changes default element resolution to root element. |
| src/Uno.UI/UI/Xaml/Media/CompositionTarget.Rendering.skia.cs | Adds render-job queue and TryExecuteOnNextRenderAsync to run work on the render thread with a current GRContext. |
| src/Uno.UI/UI/Xaml/Documents/Hyperlink.cs | Makes UnderlineStyleProperty public to match typical DP exposure patterns. |
| src/Uno.UI/UI/Xaml/Controls/TreeView/TreeViewViewModel.cs | Prunes detached node/item mappings (and selected vectors) to avoid item retention on Reset/collapsed removals. |
| src/Uno.UI/UI/Xaml/Controls/ItemsView/ItemsView.cs | Removes DEBUG-only no-op diagnostics handlers and documents prior leak via shared Layout instance subscriptions. |
| src/Uno.UI/UI/Xaml/Controls/DatePicker/DatePickerFlyoutPresenter_Partial.cs | Ensures year selector does not loop and fixes host selection guard to avoid mis-attachment/NREs. |
| src/Uno.UI/UI/Xaml/AdaptiveTrigger.cs | Adds Uno-specific global window-size override hook and re-evaluation notification path. |
| src/Uno.UI.UnitTests/Windows_UI_Xaml/Given_AdaptiveTrigger.cs | Adds unit coverage for AdaptiveTrigger window-size override behavior and cleanup. |
| src/Uno.UI.Toolkit/Diagnostics/DiagnosticsOverlay.Notification.cs | Clears notification presenter content/template on hide to avoid collectible-ALC retention. |
| src/Uno.UI.Toolkit/Diagnostics/DiagnosticsOverlay.cs | Reconciles removals even while hidden and prunes stale materialized views; clears stale notifications on removal. |
| src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Media_Imaging/Given_RenderTargetBitmap.cs | Adds regression test to ensure rendered output is not vertically flipped on GPU backends. |
| src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Input/Given_ContextRequested.Injection.Bubbling.cs | New Skia runtime tests validating ContextRequested bubbling stops at the innermost flyout via real input injection. |
| src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Controls/Given_Border.cs | Replaces reference-image comparison with pixel sampling assertion for AA behavior stability. |
| src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Controls/DatePickerIntegrationTests.cs | Adds runtime tests ensuring year column does not loop for single-year range and remains populated for multi-year ranges. |
| src/Uno.UI.RuntimeTests/Tests/Microsoft_UI_Xaml_Controls/Given_WebView2.cs | Adds macOS regression test for DocumentTitle access before navigation. |
| src/Uno.UI.Runtime.Skia.Win32/Uno.UI.Runtime.Skia.Win32.csproj | Adds conditional WebView2Aot package reference for net10+ and introduces banned API analyzers config. |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeWebViewBase.cs | New base class factoring HWND hosting + WndProc forwarding for Win32 native web views. |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeWebView.cs | Selects backend via UNO_WEBVIEW2_BACKEND, uses new base class, and supports WebView2Aot on net10+. |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeAotWebView.cs | Adds NativeAOT WebView2 backend implementation for Win32 (net10+). |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeAotWebView.Request.cs | Adds AOT wrappers for WebResourceRequested request/event args plumbing. |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeAotWebView.Response.cs | Adds AOT wrappers for WebResourceRequested response/headers plumbing. |
| src/Uno.UI.Runtime.Skia.Win32/UI/Xaml/Controls/WebView/Win32NativeAotWebView.Helpers.cs | Adds stream conversion helpers and a byte-array-backed COM IStream for AOT interop. |
| src/Uno.UI.Runtime.Skia.Win32/BannedSymbols.txt | Adds banned symbol guidance for DirectN PWSTR creation pattern. |
| src/Uno.UI.Runtime.Skia.MacOS/UnoNativeMac/UnoNativeMac/UNOWebView.m | Fixes potential crash when WKWebView title is nil (avoid strdup(NULL)). |
| src/Uno.UI.RemoteControl.Host/Helpers/HostAssemblyResolution.cs | Extends default-ALC resolution: bridge first, then on-demand load via TPA + registered probing directories, with identity guards. |
| src/Uno.UI.RemoteControl.Host/Helpers/AssemblyHelper.cs | Registers add-in directories for probing before load to improve dependency resolution ordering. |
| src/Uno.UI.RemoteControl.Host/Extensibility/AddInsExtensions.cs | Refactors add-in registration and applies hosted-service quarantine to add-in-added services. |
| src/Uno.UI.RemoteControl.Host/Extensibility/AddInHostedServiceQuarantine.cs | New quarantine wrapper to prevent broken add-in hosted services from killing the DevServer process. |
| src/Uno.UI.RemoteControl.DevServer.Tests/Uno.UI.RemoteControl.DevServer.Tests.csproj | Links quarantine source for tests and stages a new failing-hosted-service fixture. |
| src/Uno.UI.RemoteControl.DevServer.Tests/Given_HostAssemblyResolution.cs | Adds unit tests covering on-demand resolution from runtime TPA and registered probing directories. |
| src/Uno.UI.RemoteControl.DevServer.Tests/Given_AddInHostedServiceQuarantine.cs | Adds unit tests validating quarantine behavior, callback reporting, cancellation propagation, and stop semantics. |
| src/Uno.UI.RemoteControl.DevServer.Tests/Fixtures/AddInWithFailingHostedService/AddInWithFailingHostedService.csproj | Adds new net9 fixture project producing an add-in with a failing hosted service ctor. |
| src/Uno.UI.RemoteControl.DevServer.Tests/Fixtures/AddInWithFailingHostedService/Stub.cs | Fixture code registering a throwing hosted service followed by a healthy sentinel hosted service. |
| src/Uno.UI.RemoteControl.DevServer.Tests/DevServerTests.cs | Adds integration test proving DevServer remains ready when add-in hosted service ctor throws; adds safe-mode sentinel coverage. |
| src/Uno.UI.DevServer.Cli/StartCommandHandler.cs | Changes direct spawn contract, adds “safe mode” retry (disable add-ins) for died-before-ready crash scenarios. |
| src/Uno.UI.DevServer.Cli/Helpers/DevServerProcessHelper.cs | Introduces DirectSpawnResult and failure classification (died-before-ready vs timeout) with captured stderr. |
| src/Uno.UI.DevServer.Cli.Tests/Mcp/Given_StartCommandHandler.cs | Adds unit tests for safe-mode retry decision matrix and new spawn result shape. |
| src/Uno.UI.DevServer.Cli.Tests/Mcp/Given_StartCommandHandler_Integration.cs | Updates integration tests for new direct-spawn result type. |
| src/Uno.Sdk/targets/Uno.Implicit.Packages.ProjectSystem.Desktop.targets | Injects SkiaSharp.NativeAssets.Linux into desktop heads to keep native assets aligned when SkiaSharpVersion is overridden. |
| src/Uno.Foundation/Diagnostics/DiagnosticViewRegistry.cs | Raises registry-changed event after clearing collectible-ALC registrations to force overlay reconciliation. |
| src/SamplesApp/SamplesApp.Samples/Windows_UI_Xaml/AdaptiveTriggerTests/AdaptiveTrigger_WindowSizeOverride.xaml | Adds SamplesApp manual sample UI demonstrating AdaptiveTrigger global size override. |
| src/SamplesApp/SamplesApp.Samples/Windows_UI_Xaml/AdaptiveTriggerTests/AdaptiveTrigger_WindowSizeOverride.xaml.cs | Adds sample logic to toggle/apply/clear override safely on unload and update status text. |
| src/Directory.Build.targets | Adds central package version update for WebView2Aot. |
| src/AddIns/Uno.UI.WebView.Skia.X11/X11NativeWebView.cs | Forces GDK_BACKEND=x11 early via setenv and logs failures to improve X11 backend stability. |
| doc/import_external_docs.ps1 | Bumps external docs refs for uno.wasm.bootstrap and uno.extensions. |
| doc/articles/controls/WebView.md | Documents Windows WebView2 backends, NativeAOT requirement, default selection, and fallback via env var. |
| build/test-scripts/run-net7-template-linux.ps1 | Adds CI guard validating SkiaSharp.NativeAssets.Linux aligns with overridden SkiaSharpVersion. |
| build/test-scripts/ios-uitest-run.sh | Adds detailed header docs and adjusts Homebrew trust/install flow for idb-companion. |
| .github/workflows/master-sync.yml | Updates actions/checkout version used by sync workflow. |
| .github/workflows/claude-code-review.yml | Updates pinned claude-code-action revision. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-23625/wasm-skia-net9/index.html |
…tomation/master-sync/feature/breakingchanges
|
/azp run |
|
Azure Pipelines successfully started running 2 pipeline(s). |
Automated sync — merges the latest
masterintofeature/breakingchanges.820557db64..9d3087e6f3Warning
Merge conflicts — opened as a draft so it cannot auto-merge. Resolve, then mark Ready for review.
Conflicted files:
Resolve locally (the merge is already committed with the conflict markers):
Maintained automatically; updates in place. Generated by this run.