.NET Core SDK 2.1.403 disappeared from Ubuntu image

azizatif+appveyor's Avatar

azizatif+appveyor

16 Nov, 2018 08:43 AM

Hi,

The builds for all my .NET Core projects are failing today because they use global.json to pin to version 2.1.4 of the SDK and it seems to have disappeared between yesterday and today on the Ubuntu image. The Windows builds are working fine.

As can be seen below, from the output of dotnet --info on the Ubuntu image, there is now 2.1.500 but no 2.1.400+:

.NET Core SDKs installed:
  1.1.5 [/usr/share/dotnet/sdk]
  1.1.6 [/usr/share/dotnet/sdk]
  1.1.7 [/usr/share/dotnet/sdk]
  1.1.8 [/usr/share/dotnet/sdk]
  1.1.9 [/usr/share/dotnet/sdk]
  1.1.10 [/usr/share/dotnet/sdk]
  1.1.11 [/usr/share/dotnet/sdk]
  2.0.0 [/usr/share/dotnet/sdk]
  2.0.2 [/usr/share/dotnet/sdk]
  2.0.3 [/usr/share/dotnet/sdk]
  2.1.2 [/usr/share/dotnet/sdk]
  2.1.3 [/usr/share/dotnet/sdk]
  2.1.4 [/usr/share/dotnet/sdk]
  2.1.101 [/usr/share/dotnet/sdk]
  2.1.103 [/usr/share/dotnet/sdk]
  2.1.104 [/usr/share/dotnet/sdk]
  2.1.105 [/usr/share/dotnet/sdk]
  2.1.200 [/usr/share/dotnet/sdk]
  2.1.201 [/usr/share/dotnet/sdk]
  2.1.202 [/usr/share/dotnet/sdk]
  2.1.500 [/usr/share/dotnet/sdk]

The build fails due to the following error at the end:

A compatible SDK version for global.json version: [2.1.400] from [/home/appveyor/projects/boxing/global.json] was not found
Did you mean to run dotnet SDK commands? Please install dotnet SDK from:
  https://go.microsoft.com/fwlink/?LinkID=798306&clcid=0x409

See build 7 of my Boxing project. The same project was building fine yesterday and the same Ubuntu image had version 2.1.403 installed:

.NET Core SDKs installed:
  1.1.5 [/usr/share/dotnet/sdk]
  1.1.6 [/usr/share/dotnet/sdk]
  1.1.7 [/usr/share/dotnet/sdk]
  1.1.8 [/usr/share/dotnet/sdk]
  1.1.9 [/usr/share/dotnet/sdk]
  1.1.10 [/usr/share/dotnet/sdk]
  1.1.11 [/usr/share/dotnet/sdk]
  2.0.0 [/usr/share/dotnet/sdk]
  2.0.2 [/usr/share/dotnet/sdk]
  2.0.3 [/usr/share/dotnet/sdk]
  2.1.2 [/usr/share/dotnet/sdk]
  2.1.3 [/usr/share/dotnet/sdk]
  2.1.4 [/usr/share/dotnet/sdk]
  2.1.101 [/usr/share/dotnet/sdk]
  2.1.103 [/usr/share/dotnet/sdk]
  2.1.104 [/usr/share/dotnet/sdk]
  2.1.105 [/usr/share/dotnet/sdk]
  2.1.200 [/usr/share/dotnet/sdk]
  2.1.201 [/usr/share/dotnet/sdk]
  2.1.202 [/usr/share/dotnet/sdk]
  2.1.403 [/usr/share/dotnet/sdk]

I checked the list of .NET Core SDK version pre-installed on the Linux images and 2.1.4 is still listed.

I would appreciate any help you can offer as most of my project builds are failing now.

Thanks!

  1. Support Staff 1 Posted by Wasa Pleshakov on 16 Nov, 2018 03:11 PM

    Wasa Pleshakov's Avatar

    The reason here is that Microsoft replaced 2.1.403 with 2.1.500. Let me try to explain how Microsoft versioning SDKs now.
    Each time we update ubuntu images we install all software from scratch. We install .NET SDKs from official Microsoft's repository which you can browse here https://packages.microsoft.com/ubuntu/16.04/prod/pool/main/d/. If you run apt-cache search dotnet-sdk-* on any ubuntu host you will see a pretty much same list of SDKs.
    As you may see a version is a part of deb package name.
    After releasing .NET SDK 2.1.300 RC1 as dotnet-sdk-2.1.300-rc1... deb package in May 2018 Microsoft decided to remove minor version from package name and released .NET SDK 2.1.300 as dotnet-sdk-2.1 deb package. All next versions released with this package name.
    So now there is a bunch of versions under dotnet-sdk-2.1 name https://packages.microsoft.com/ubuntu/16.04/prod/pool/main/d/dotnet...
    or you can get the same list with apt-cache show dotnet-sdk-2.1 command.
    apt consider it all as different versions of the same package. apt does now allow to install multiple versions of the same package co-exist on the same system. Thus you may get installed either 2.1.400 or 2.1.500 on the system.

    if it is crucial for you to run your builds with .NET SDK 2.1.400 you may use previous ubuntu image.

  2. 2 Posted by azizatif+appvey... on 19 Nov, 2018 07:54 AM

    azizatif+appveyor's Avatar

    Thanks for a very detailed answer, Wasa! I wasn't aware of those changes and now I understand exactly how to go about and resolve my issue.

    Thanks again and keep up the splendid work!

  3. azizatif+appveyor closed this discussion on 19 Nov, 2018 08:04 AM.

  4. azizatif+appveyor re-opened this discussion on 19 Nov, 2018 08:34 AM

  5. 3 Posted by azizatif+appvey... on 19 Nov, 2018 08:34 AM

    azizatif+appveyor's Avatar

    Just in case someone else coming looking for a solution, here's what I ended up adding to the install section of my appveyor.yml:

    apt-get install -y --allow-downgrades dotnet-sdk-2.1=2.1.403-1
    
  6. azizatif+appveyor closed this discussion on 19 Nov, 2018 08:34 AM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac