Skip to content

Align all projects on .NET 10 - #327

Merged
Sergio0694 merged 4 commits into
mainfrom
sergio0694-align-on-net10
Dec 4, 2026
Merged

Sergio0694 merged 4 commits into
mainfrom
sergio0694-align-on-net10

Conversation

@Sergio0694

Copy link
Copy Markdown
Member

Agent assessment

Self-reported assessment, not an independent review.

Assessed revision: 2236c15da041ab905d2fd5c1cbf11c36f59c5d69

Dimension Assessment Rationale
Change confidence 8/10 ↑ In a CI-like consumer layout, wasdk and uwp (WinUI 2) legs build and the template tests pass 9/9; wasm head builds in Release and boots in a browser; generator tests pass on net10.0.
↓ Validated on SDK 10.0.404 only (CI pins 10.0.402).
↓ Android/iOS/MacCatalyst/WPF/GTK net10.0 targets not built (Uno 5.5 support unverified).
↓ PR CI not yet inspected.

Moves everything on modern .NET to net10.0 and drops all net8.0/net9.0 TFMs (generators stay netstandard2.0).

  • Generator test projects now target net10.0.
  • MultiTarget TFMs and heads are net10.0 only. The Wasm head moves to Uno.Wasm.Bootstrap 10.0.98 and 10.0.x support packages, because 9.x doesn't boot on net10. The Release MAXIMUM_MEMORY=4GB Emcc flag is dropped, since Bootstrap 10 would otherwise need the wasm-tools workload.
  • Redundant workarounds are removed: manual NET*_OR_GREATER constants, the IsExternalInit polyfill, UseRidGraph, and old-TFM placeholders.
  • Docs and instructions are updated.

Consumer repos will need follow-ups when they bump the submodule (for example net8.0 test paths in CI and UwpTargetFrameworks overrides).

Sergio0694 and others added 4 commits December 3, 2026 16:48
The tests now run on the same runtime as the pinned SDK, so the extra older runtime requirement is dropped from the docs.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Drop the net8.0 and net9.0 target frameworks from the available TFM lists (UWP/WinAppSdk, Uno heads and libs, common), define NET10_0_OR_GREATER, keep only a net10.0 placeholder in the mismatched-TFM Uno workaround, and simplify the RuntimeIdentifier selection now that win-* RIDs always apply. The sample project no longer references System.Collections.Immutable outside netstandard, as it is pruned (NU1510) on net10.0.

Uno.Wasm.Bootstrap 9.x expects the .NET 9 blazor.boot.json layout and leaves the Wasm head stuck on the splash screen on net10.0, so move to 10.0.98 together with the 10.0.15 Microsoft.Windows.Compatibility, Microsoft.Extensions.Logging and ILLink.Tasks packages (which also clears the NU1902/NU1903 advisories of the 9.0.0 ones). Drop the Release MAXIMUM_MEMORY=4GB Emcc flag: Bootstrap 10 requires the wasm-tools workload whenever extra Emcc flags are set, which CI does not install.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
The SDK already defines NET*_OR_GREATER for every net10.0 TFM (verified by compiling #if probes for net10.0 and net10.0-windows), so the manual DefineConstants are dropped. The IsExternalInit polyfill in App.Shared was dead code, as all heads are on net10.0, and UseRidGraph (WindowsAppSDK#3842) is no longer needed: wasdk, uwp and wasm legs build and the wasdk and uwp template tests pass without it.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@Sergio0694
Sergio0694 merged commit c001882 into main Dec 4, 2026
8 checks passed
@Sergio0694
Sergio0694 deleted the sergio0694-align-on-net10 branch December 4, 2026 19:44
Sergio0694 added a commit to CommunityToolkit/Labs-Windows that referenced this pull request Dec 4, 2026
Points tooling at CommunityToolkit/Tooling-Windows-Submodule#327, which is
merged on tooling main (c0018820).

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Sergio0694 added a commit to CommunityToolkit/Labs-Windows that referenced this pull request Dec 4, 2026
* Update tooling submodule to .NET 10 alignment

Points tooling at CommunityToolkit/Tooling-Windows-Submodule#327, which is
merged on tooling main (c0018820).

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Target net10.0 only for XAML-free UWP libraries and DPG tests

- AppServices, Notifications and DependencyPropertyGenerator now override
  UwpTargetFrameworks with net10.0-windows10.0.17763.0 only (dropping
  net8.0/net9.0), matching the tooling .NET 10 alignment.
- The DependencyPropertyGenerator tests now target
  net10.0-windows10.0.17763.0. Their compilations reference the net10 package
  assembly, so they must use net10 reference assemblies (otherwise CS1705):
  move to Basic.Reference.Assemblies.Net100 and ReferenceAssemblies.Net.Net100,
  which requires Microsoft.CodeAnalysis.CSharp.{Analyzer,CodeFix}.Testing 1.1.3.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Remove workarounds that are no longer needed on net10.0

- Delete the TransitionHelper IsExternalInit polyfill: its targets (uwp and
  wasdk) are net10.0 only now, where the type ships in the BCL.
- Drop LangVersion=preview from the Adorners library: it was only needed for
  the 'field' keyword, which is stable in C# 14 (the default for net10.0). The
  samples keep it, as they use CommunityToolkit.Mvvm partial properties.
- Drop the NU1903 suppression from the DependencyPropertyGenerator tests: the
  vulnerable transitive packages are no longer restored with the updated
  Roslyn testing packages and net10.0 package pruning.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Update docs and CI for the .NET 10 alignment

- ReadMe: require the .NET 10 SDK (matching global.json) and Visual Studio 2026
  (18.0), which the .NET 10 SDK requires.
- build.yml: require VS 18.0+ for setup-msbuild instead of 17.13.
- Copilot instructions: refresh the UwpTargetFrameworks and IsAotCompatible
  notes for net10.0.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Flow trim requirements from the Adorners input validation sample

ObservableValidator and DataAnnotations validation rely on reflection, and
the Apple SDKs always run the trim analyzer (with the default SdkOnly link
mode they don't suppress its warnings), so the net10.0-ios/net10.0-maccatalyst
Release builds failed with IL2026 errors in the sample.

Annotate the sample ViewModel with [RequiresUnreferencedCode] so the
requirement is expressed correctly, and only suppress IL2026 where the page
instantiates it, scoped to the Apple TFMs.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

* Skip the wasm-tools workload check in the wasm-linux job

Uno.Wasm.Bootstrap 10 errors (UNOWA0001) when native wasm assets are
used without the wasm-tools workload. SkiaSharp.NativeAssets.WebAssembly
(via RivePlayer) turns on native linking, and this compile-only job
doesn't install the workload. Skip the check there: the Windows wasm leg
covers the full native build.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
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