Fix browser-wasm test restore NU1102 failures#124288
Merged
lewing merged 1 commit intodotnet:darc-main-e2f5167c-e029-48f9-9320-5da37ced6868from Feb 11, 2026
Merged
Conversation
Member
Author
|
testing analysis |
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes browser-wasm test restore failures (NU1102) by ensuring restores and local targeting pack resolution correctly account for runtime flavor and the browser-wasm RID, alongside a broader codeflow/dependency/tooling update.
Changes:
- Pass
RuntimeFlavorinto thedotnet restoreinvocation for test restores. - Add
browser-wasmto the CoreCLRRuntimePackRuntimeIdentifierslist used for local targeting/runtime pack resolution. - Update pinned SDK/dependency versions and adjust shared eng/CI scripts/templates (pool images, native deps).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/tests/build.proj | Adds conditional /p:RuntimeFlavor=... to the restore command used by test builds. |
| eng/targetingpacks.targets | Extends CoreCLR runtime pack RID list to include browser-wasm for local pack resolution. |
| global.json | Updates pinned SDK/tooling and MSBuild SDK versions. |
| eng/common/templates/variables/pool-providers.yml | Updates example pool image reference (comment-only change). |
| eng/common/native/install-dependencies.sh | Installs Ninja across supported OS/distro paths. |
| eng/common/cross/build-rootfs.sh | Adjusts LLDB package selection for Ubuntu 24.04 (noble). |
| eng/common/core-templates/post-build/post-build.yml | Moves publishing pools from windows.vs2019 to windows.vs2022 images/demands. |
| eng/common/core-templates/job/source-build.yml | Updates source-build pool selection to Azure Linux 3 images/demands. |
| eng/common/core-templates/job/publish-build-assets.yml | Moves publishing pools from windows.vs2019 to windows.vs2022 images. |
| eng/Versions.props | Bumps prerelease iteration. |
| eng/Version.Details.xml | Updates codeflow source SHA and multiple dependency versions. |
| eng/Version.Details.props | Updates corresponding dependency version properties. |
After UseMonoRuntime was removed from in-tree wasm props (PR dotnet#121789), test restores for browser-wasm fail with NU1102 because the SDK tries to download runtime packs that don't exist on NuGet. The test restore only needs NuGet package references - runtime packs come from the local build and are wired up separately during test build. Fix: Unconditionally disable runtime and targeting pack downloads during test dependency restore, since they are never needed from NuGet.
09f96e9 to
f1b6cdd
Compare
Member
Author
|
it looks like it was added in net8 tfm bump #78354 |
Member
Author
|
I'm going to merge it into the vmr flow since ci isn't running here |
25d8826
into
dotnet:darc-main-e2f5167c-e029-48f9-9320-5da37ced6868
13 of 15 checks passed
lewing
added a commit
that referenced
this pull request
Feb 12, 2026
The previous fix (PR #124288) made EnableTargetingPackDownload=false and EnableRuntimePackDownload=false unconditional for all platforms. This broke coreclr/NativeAOT/Libraries test restores that need those packs from NuGet. Fix: Add 'or TargetOS==browser' to the existing UseLocalAppHostPack condition instead of making the flags unconditional. This fixes browser-wasm NU1102 while preserving original behavior for all other platforms.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Problem
After UseMonoRuntime was removed from in-tree wasm props (PR #121789 by @maraf), browser-wasm test restores fail with NU1102 (package not found).
The
RestorePackagetarget inbuild.projrunsdotnet restorefor test dependency projects. These projects useMicrosoft.NET.Sdk(not the WebAssembly SDK), soUseMonoRuntimeis not set. Without it, the newer SDK tries to downloadMicrosoft.NETCore.App.Runtime.browser-wasm(CoreCLR pattern) orMicrosoft.NETCore.App.Runtime.Mono.browser-wasmfrom NuGet — packages that don't exist for .NET 11.The test restore doesn't need runtime or targeting packs from NuGet — those come from the local build and are wired up during the test build step. However,
EnableRuntimePackDownload=falseandEnableTargetingPackDownload=falsewere only passed conditionally (whenUseLocalAppHostPack=true), and browser-wasm setsUseLocalAppHostPack=false.Fix
Unconditionally pass
-p:EnableRuntimePackDownload=false -p:EnableTargetingPackDownload=falseto the test dependency restore command. This fixes both Mono and CoreCLR browser-wasm configurations since neither needs pack downloads during restore.Context
cc @maraf @akoeplinger