Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong workload versions installed when pinned to .NET 8 via global.json on latest GitHub Action windows runners #45204

Open
frenzibyte opened this issue Nov 28, 2024 · 0 comments
Labels
Area-Workloads untriaged Request triage from a team member

Comments

@frenzibyte
Copy link

frenzibyte commented Nov 28, 2024

Describe the bug

Since GitHub released new Windows runner images that include the .NET 9 SDK, our build workflows which target .NET 8 projects have stopped working. After dissecting the issue, it turns out that the workloads installed in the build workflow are older than what the projects require to build. More specifically, the workloads installed are from the .NET 7 workload set while we're expecting the ones from the .NET 8 workload set.

This is the output returned by the dotnet workload install android command, from an isolated project linked below to investigate this issue with:

Run dotnet workload install android
  
Installing workload manifest microsoft.net.sdk.android version 33.0.95...
Installing workload manifest microsoft.net.sdk.ios version 16.4.7142...
Installing workload manifest microsoft.net.sdk.maccatalyst version 16.4.7142...
Installing workload manifest microsoft.net.sdk.macos version 13.3.7142...
Installing workload manifest microsoft.net.sdk.maui version 7.0.101...
Installing workload manifest microsoft.net.sdk.tvos version 16.4.7142...
Installing pack Microsoft.Android.Sdk.Windows version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Sdk.Windows version 33.0.95...
Installing pack Microsoft.Android.Sdk.Windows version 32.0.509...
Writing workload pack installation record for Microsoft.Android.Sdk.Windows version 32.0.509...
Installing pack Microsoft.Android.Ref.33 version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Ref.33 version 33.0.95...
Installing pack Microsoft.Android.Runtime.33.android-arm version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Runtime.33.android-arm version 33.0.95...
Installing pack Microsoft.Android.Runtime.33.android-arm64 version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Runtime.33.android-arm64 version 33.0.95...
Installing pack Microsoft.Android.Runtime.33.android-x86 version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Runtime.33.android-x86 version 33.0.95...
Installing pack Microsoft.Android.Runtime.33.android-x64 version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Runtime.33.android-x64 version 33.0.95...
Installing pack Microsoft.Android.Templates version 33.0.95...
Writing workload pack installation record for Microsoft.Android.Templates version 33.0.95...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-arm version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-arm version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-arm64 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-arm64 version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-x64 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-x64 version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-x86 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-x86 version 6.0.31...
Installing pack Microsoft.NET.Runtime.MonoAOTCompiler.Task version 6.0.31...
Writing workload pack installation record for Microsoft.NET.Runtime.MonoAOTCompiler.Task version 6.0.31...
Installing pack Microsoft.NET.Runtime.MonoTargets.Sdk version 6.0.31...
Writing workload pack installation record for Microsoft.NET.Runtime.MonoTargets.Sdk version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x86 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x86 version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x64 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x64 version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm64 version 6.0.31...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm64 version 6.0.31...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-arm version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-arm version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-arm64 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-arm64 version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-x64 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-x64 version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.Mono.android-x86 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.Mono.android-x86 version 7.0.20...
Installing pack Microsoft.NET.Runtime.MonoAOTCompiler.Task version 7.0.20...
Writing workload pack installation record for Microsoft.NET.Runtime.MonoAOTCompiler.Task version 7.0.20...
Installing pack Microsoft.NET.Runtime.MonoTargets.Sdk version 7.0.20...
Writing workload pack installation record for Microsoft.NET.Runtime.MonoTargets.Sdk version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x86 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x86 version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x64 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-x64 version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm version 7.0.20...
Installing pack Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm64 version 7.0.20...
Writing workload pack installation record for Microsoft.NETCore.App.Runtime.AOT.win-x64.Cross.android-arm64 version 7.0.20...
Garbage collecting for SDK feature band(s) 6.0.100 6.0.200 6.0.300 6.0.400 7.0.100 7.0.200 7.0.300 7.0.400 8.0.100 8.0.200 8.0.300 8.0.400 9.0.100...
Successfully installed workload(s) android.

As can be seen above, the workload version installed for android is 33.0.95, which is from the .NET 7 workload set. Running dotnet --info afterwards returns the following:

To Reproduce

I was not able to reproduce this on my local machine, but I have at least prepared an isolated repository containing a random Android project and a GHA workflow reproducing the bug.

Exceptions (if any)

Further technical details

Output from the GHA workflow run linked above:

Run dotnet --info
.NET SDK:
 Version:           8.0.404
 Commit:            7b190310f2
 Workload version:  8.0.400-manifests.1631c74e
 MSBuild version:   17.11.9+a69bbaaf5
Runtime Environment:
 OS Name:     Windows
 OS Version:  10.0.20348
 OS Platform: Windows
 RID:         win-x64
 Base Path:   C:\Program Files\dotnet\sdk\8.0.404\
.NET workloads installed:
Configured to use loose manifests when installing new manifests.
 [android]
   Installation Source: SDK 8.0.400, VS 17.12.35514.174
   Manifest Version:    33.0.95/7.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\7.0.100\microsoft.net.sdk.android\33.0.95\WorkloadManifest.json
   Install Type:        FileBased
 [maui-windows]
   Installation Source: VS 17.12.35514.174
   Manifest Version:    7.0.101/7.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\7.0.100\microsoft.net.sdk.maui\7.0.101\WorkloadManifest.json
   Install Type:        FileBased
 [maccatalyst]
   Installation Source: VS 17.12.35514.174
   Manifest Version:    16.4.7142/7.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\7.0.100\microsoft.net.sdk.maccatalyst\16.4.7142\WorkloadManifest.json
   Install Type:        FileBased
 [ios]
   Installation Source: VS 17.12.35514.174
   Manifest Version:    16.4.7142/7.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\7.0.100\microsoft.net.sdk.ios\16.4.7142\WorkloadManifest.json
   Install Type:        FileBased
 [wasm-tools]
   Installation Source: VS 17.12.35514.174
   Manifest Version:    7.0.20/7.0.100
   Manifest Path:       C:\Program Files\dotnet\sdk-manifests\7.0.100\microsoft.net.workload.mono.toolchain.net7\WorkloadManifest.json
   Install Type:        FileBased
Host:
  Version:      9.0.0
  Architecture: x64
  Commit:       9d5a6a9aa4
.NET SDKs installed:
  6.0.136 [C:\Program Files\dotnet\sdk]
  6.0.203 [C:\Program Files\dotnet\sdk]
  6.0.321 [C:\Program Files\dotnet\sdk]
  6.0.428 [C:\Program Files\dotnet\sdk]
  7.0.120 [C:\Program Files\dotnet\sdk]
  7.0.203 [C:\Program Files\dotnet\sdk]
  7.0.317 [C:\Program Files\dotnet\sdk]
  7.0.410 [C:\Program Files\dotnet\sdk]
  8.0.111 [C:\Program Files\dotnet\sdk]
  8.0.206 [C:\Program Files\dotnet\sdk]
  8.0.307 [C:\Program Files\dotnet\sdk]
  8.0.404 [C:\Program Files\dotnet\sdk]
  9.0.100 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
  Microsoft.AspNetCore.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 6.0.35 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 6.0.36 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 8.0.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.AspNetCore.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 6.0.35 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 6.0.36 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 8.0.11 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.NETCore.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
  Microsoft.WindowsDesktop.App 6.0.5 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 6.0.26 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 6.0.36 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 7.0.5 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 7.0.20 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 8.0.6 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 8.0.11 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
  Microsoft.WindowsDesktop.App 9.0.0 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Other architectures found:
  x86   [C:\Program Files (x86)\dotnet]
    registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]
Environment variables:
  DOTNET_ROOT       [C:\Program Files\dotnet]
global.json file:
  D:\a\dotnet-workload-breakage\dotnet-workload-breakage\global.json
Learn more:
  https://aka.ms/dotnet/info
Download .NET:
  https://aka.ms/dotnet/download
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-Workloads untriaged Request triage from a team member
Projects
None yet
Development

No branches or pull requests

1 participant