JetBrains / teamcity-dotnet-plugin

TeamCity plugin for .NET projects

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

restore fails for dotnet SDK 1.x

senritsu opened this issue · comments

With the project.json based project format, restore fails after update to 2017.2 and automatic change to this plugin from the old .Net Core plugin.

[10:59:40][Step 2/13] restore
[10:59:40][restore] Starting: "C:\Program Files\dotnet\dotnet.exe" restore @E:\TeamCity\buildAgent\temp\agentTmp\bcba3af3a0a34317a49f1bbda622b193.rsp
[10:59:40][restore] in directory: E:\TeamCity\buildAgent\work\PROJECT_NAME\BRANCH_NAME
[10:59:40][restore] error: @E:\TeamCity\buildAgent\temp\agentTmp\bcba3af3a0a34317a49f1bbda622b193.rsp
[10:59:40][restore] Process exited with code 1

Probably related to a few of the comments on the plugin download page (https://plugins.jetbrains.com/plugin/9190--net-cli-support) who also had issues with the sudden addition of the .rsp file parameter to the dotnet commands.

@senritsu, thanks for reporting this problem.

@senritsu what version of dotnet core/sdk/VS tooling you are using? As I know the newest version of tooling for VS 2015 is preview 2 and it is not quite convenient for us to support preview/beta. Microsoft has dropped support for the project.json and we would like to do the same. They are encouraging everyone doing .NET Core development to move to Visual Studio 2017, including migrating from project.json to csproj.
So my question: is it possible to migrate your projects to csproj, because you will face this anyway?
In any case, we will solve this issue :)

It was a VS15 project using 1.1 with SDK Preview 2.1 build 3177. We are migrating to .csproj based core 2 already, but depending on the project size it can take some time. While i can understand that supporting it is a difficult decision, Microsoft themselves label all of the 1.x versions as LTS. It seems support is not quite dropped yet, even if they are (understandably) trying to phase it out as fast as they can.

For us specifically, the issue was solved by switching the build runner type back to the old .Net Core from the new .Net CLI for our build steps, which is fortunately possible.

To switch off usage of .rsp files add the configuration parameter dotnet.cli.rsp=false.
But in this case some of features of TeamCity like System Parameters will be not available. Also the length of a command line will be significantly increased and it could be a reason of some issues.
It is available in master now