runner-images icon indicating copy to clipboard operation
runner-images copied to clipboard

ubuntu-latest: Failing to run NET6 app due to missing Microsoft.NETCore.App

Open sebastien-marichal opened this issue 7 months ago • 16 comments

Description

After the latest update in ubuntu-latest we started having issues in our Azure pipeline while running a NET6 app with the error:

/usr/share/dotnet/sdk/7.0.201/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(376,5):
error NETSDK1127: The targeting pack Microsoft.NETCore.App is not installed. Please restore and try again.

This time the issue seems to come from the update of .NET 8 update from 8.0.301 to 8.0.302.

Similar to issues we already reported in #5792, #6925 & #7319.

Platforms affected

  • [x] Azure DevOps
  • [ ] GitHub Actions - Standard Runners
  • [ ] GitHub Actions - Larger Runners

Runner images affected

  • [ ] Ubuntu 20.04
  • [X] Ubuntu 22.04
  • [ ] Ubuntu 24.04
  • [ ] macOS 11
  • [ ] macOS 12
  • [ ] macOS 13
  • [ ] macOS 13 Arm64
  • [ ] macOS 14
  • [ ] macOS 14 Arm64
  • [ ] Windows Server 2019
  • [ ] Windows Server 2022

Image version and build link

Image: ubuntu-22.04 Version: 20240624.1.0

Is it regression?

Yes. The previous version was working correctly.

Expected behavior

Run the App without a runtime error.

Actual behavior

Following error:

/usr/share/dotnet/sdk/7.0.201/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(376,5):
error NETSDK1127: The targeting pack Microsoft.NETCore.App is not installed. Please restore and try again.

Repro steps

Could not reproduce this locally.

Changing the image to ubuntu-20.04 seems to solve the issue on the pipeline, at least.

sebastien-marichal avatar Jun 28 '24 14:06 sebastien-marichal