Dotnet core 2.2

Seems like dotnet core 2.2 was released today. But we are getting a

The command “sudo apt-get install -qq dotnet-sdk-2.2” failed and exited with 100 during .

Can we please add dotnet core 2.2

6 Likes

It would be great to detail how the community can help add the releases to travis. I am copying over an issue from github that was never addressed for the asp previews.

I am interested in testing the new dotnet preview and it appears that travis is not configured to download/install this sdk.

e[31;1mC# support for Travis-CI is community maintained.e[0m
e[31;1mPlease open any issues at https://github.com/travis-ci/travis-ci/issues/new and cc @joshua-anderson @akoeplinger @nterrye[0m
travis_fold:start:dotnet-install
e[0Ke[33;1mInstalling .NET Coree[0m
$ export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
$ export DOTNET_CLI_TELEMETRY_OPTOUT=1
travis_time:start:177f4d5e
e[0KW: http://ppa.launchpad.net/couchdb/stable/ubuntu/dists/trusty/Release.gpg: Signature by key 15866BAFD9BCC4F3C1E0DFC7D69548E1C17EAB57 uses weak digest algorithm (SHA1)

travis_time:end:177f4d5e:start=1535645637267150544,finish=1535645644198876233,duration=6931725689
e[0Ktravis_time:start:3bd8cf2d
e[0KE: Unable to locate package dotnet-sdk-2.2
E: Couldn't find any package by glob 'dotnet-sdk-2.2'
E: Couldn't find any package by regex 'dotnet-sdk-2.2'

travis_time:end:3bd8cf2d:start=1535645644203828672,finish=1535645647988227690,duration=3784399018
e[0K
e[31;1mThe command "sudo apt-get install -qq dotnet-sdk-2.2=2.2.100-preview1-009349*" failed and exited with 100 during .e[0m

Your build has been stopped.

Does someone need to add this version to apt-get?

cc @joshua-anderson @akoeplinger

3 Likes
Installing .NET Core
$ export DOTNET_SKIP_FIRST_TIME_EXPERIENCE=1
$ export DOTNET_CLI_TELEMETRY_OPTOUT=1
6.01s16.32sSelecting previously unselected package liburcu1.
(Reading database ... 97797 files and directories currently installed.)
Preparing to unpack .../liburcu1_0.7.12-0ubuntu2_amd64.deb ...
Unpacking liburcu1 (0.7.12-0ubuntu2) ...
Selecting previously unselected package liblttng-ust-ctl2:amd64.
Preparing to unpack .../liblttng-ust-ctl2_2.4.0-4ubuntu1_amd64.deb ...
Unpacking liblttng-ust-ctl2:amd64 (2.4.0-4ubuntu1) ...
Selecting previously unselected package liblttng-ust0:amd64.
Preparing to unpack .../liblttng-ust0_2.4.0-4ubuntu1_amd64.deb ...
Unpacking liblttng-ust0:amd64 (2.4.0-4ubuntu1) ...
Selecting previously unselected package dotnet-runtime-deps-2.2.
Preparing to unpack .../dotnet-runtime-deps-2.2_2.2.0-1_amd64.deb ...
Unpacking dotnet-runtime-deps-2.2 (2.2.0-1) ...
Selecting previously unselected package dotnet-host.
Preparing to unpack .../dotnet-host_2.2.0-1_amd64.deb ...
Unpacking dotnet-host (2.2.0-1) ...
Selecting previously unselected package dotnet-hostfxr-2.2.
Preparing to unpack .../dotnet-hostfxr-2.2_2.2.0-1_amd64.deb ...
Unpacking dotnet-hostfxr-2.2 (2.2.0-1) ...
Selecting previously unselected package dotnet-runtime-2.2.
Preparing to unpack .../dotnet-runtime-2.2_2.2.0-1_amd64.deb ...
Unpacking dotnet-runtime-2.2 (2.2.0-1) ...
dpkg-deb: error: archive '/var/cache/apt/archives/aspnetcore-runtime-2.2_2.2.0-1_amd64.deb' has premature member 'control.tar.xz' before 'control.tar.gz', giving up
dpkg: error processing archive /var/cache/apt/archives/aspnetcore-runtime-2.2_2.2.0-1_amd64.deb (--unpack):
 subprocess dpkg-deb --control returned error exit status 2
Selecting previously unselected package dotnet-sdk-2.2.
Preparing to unpack .../dotnet-sdk-2.2_2.2.100-1_amd64.deb ...
Unpacking dotnet-sdk-2.2 (2.2.100-1) ...
Processing triggers for man-db (2.6.7.1-1ubuntu1) ...
Errors were encountered while processing:
 /var/cache/apt/archives/aspnetcore-runtime-2.2_2.2.0-1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
The command "sudo apt-get install -qq dotnet-sdk-2.2" failed and exited with 100 during .

i wonder if the issue is not just that we need a dpkg update

I’m having the same issue as well:
“The command “sudo apt-get install -qq dotnet-sdk-2.2=2.2.100*” failed and exited with 100 during .”

Spec:
sudo: required
language: csharp
dotnet: 2.2.100
services:
- docker
os:
- linux
# trucated for sake of simplicity

Seems dotnet core 2.2 build fine on bionic and xenial

3 Likes

Same issue here. Any suggestions for a workaround?

travis.yml: https://github.com/collinbarrett/FilterLists/blob/issue636/.travis.yml
Build log: https://travis-ci.org/collinbarrett/FilterLists/builds/466775864

Hi,
Is there any estimate time to support for net core 2.2 ?
Regards
Krzysztof

same here

Workaround: use xenial of bionic

2 Likes

Could you post or link to an example yml file? I do not know travis nor ubuntu enough to know what “use xenial of bionic” fully means or how to do it.

This error suggests that either the package is incorrect, or – which is extremely more likely – that it uses the syntax of a newer dpkg version that the older version in trusty doesn’t understand.

So, the workaround is indeed to use Xenial.

Download .NET (Linux, macOS, and Windows), does claim Trusty support but lists a different set of steps.

https://github.com/travis-ci/travis-build/blob/12634169f0b886123b2e219f05f07cb38decd0d5/lib/travis/build/script/csharp.rb doesn’t follow these steps but invents its custom ones that make their own assumptions about URLs and such (how much they are equivalent is up for debate; the important thing is, MS doesn’t promise that any other steps would work).

So this looks like Travis’ issue; could possibly be MS’ issue, too, if the package fetched with correct steps also couldn’t be parsed.

1 Like


this for example works fine

3 Likes

The root cause of this error that seems to be an old version of dpkg has been reported several times in the GitHub repository of Travis:

They said as a workaround to update manually dpkg but in this case, I haven’t find any way to run the update command before Travis tries to install .NET Core. The before_install and apt addons seems to run in a later step.

In my case, I’m updating the dist from trusty to xenial as recommended before.

Any updates?

I think in most of case people are just switching to xenial

this is still an issue?

@Kritner yes, that’s still in issue. You have to set the dist in your yaml-file to either use xenial or bionic.

Oh ok I’ll give that a shot thanks! I guess I glossed over the changes above in the thread, I thought it was saying I needed to switch to some other service to build 2.2, which I didn’t want to do :smiley:

What’s this “dist” property? And how does using it over dist: trusty make the difference? I’m very new to this, so apologies if that’s a dumb question.

That’s a build-environment as well.

Add to the first line of your yaml-file

dist: bionic

and you are good to go. You can find here a sample of mine.

Do also need to set mono to none? I tried the xenial dist, but the old dotnet 2.1 get’s installed although I specified the 2.2 version.

All this ‘magic’ going on to get things running is a bit unfortunate, I think.