Build failing without any change

Tzach Shabtay's Avatar

Tzach Shabtay

13 Mar, 2018 01:31 AM

It seems like something changed on the virtual machine causing the build to fail without any change to the codebase.

The failing build:
A successful build just 3 days ago for the same codebase:

Note that the error seen in the failed build also happens in the successful build, so it wasn't failing the build then but it is now?.

This is the error:
C:\projects\monoags\Source\AGS.API\AGS.API.csproj(281,3): error MSB4019: The imported project "C:\Program Files\dotnet\sdk\2.1.100\Microsoft\Portable\v5.0\Microsoft.Portable.CSharp.targets" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.

The only difference seems to be that the successful build is running against dotnet 2.1.4 and not 2.1.100.

  1. Support Staff 1 Posted by Ilya Finkelshte... on 13 Mar, 2018 01:49 AM

    Ilya Finkelshteyn's Avatar

    What happens if you rebuild your successful build? For that you can open it and press RE-BUILD COMMIT button.

  2. 2 Posted by Tzach Shabtay on 13 Mar, 2018 11:59 AM

    Tzach Shabtay's Avatar
  3. Support Staff 3 Posted by Owen McDonnell on 14 Mar, 2018 01:06 AM

    Owen McDonnell's Avatar

    As a workaround, you can add a global.json file to the project with the following in it to force specific dotnet sdk,

      "sdk": {
        "version": "2.1.4"
  4. 4 Posted by Tzach Shabtay on 14 Mar, 2018 03:24 PM

    Tzach Shabtay's Avatar

    Thanks, the workaround works for now.

  5. Support Staff 5 Posted by Owen McDonnell on 14 Mar, 2018 06:23 PM

    Owen McDonnell's Avatar

    Sorry, i misspoke. Its not really a workaround but rather the established way to specify a version of .net core sdk.

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:


Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts


? 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