Skip to main content

Azure DevOps NuGet error

When trying to restore a NuGet package inside an Azure DevOps Build it failed with the following error message:

2019-11-13T09:17:59.8686867Z ##[section]Starting: NuGet restore

2019-11-13T09:17:59.8813825Z ==============================================================================

2019-11-13T09:17:59.8813825Z Task         : NuGet Installer

2019-11-13T09:17:59.8813825Z Description  : Installs or restores missing NuGet packages

2019-11-13T09:17:59.8813825Z Version      : 0.2.31

2019-11-13T09:17:59.8813825Z Author       : Microsoft Corporation

2019-11-13T09:17:59.8813825Z Help         : [More Information](https://go.microsoft.com/fwlink/?LinkID=613747)

2019-11-13T09:17:59.8813825Z ==============================================================================

2019-11-13T09:18:01.6050815Z [command]C:\Windows\system32\chcp.com 65001

2019-11-13T09:18:01.6050815Z Active code page: 65001

2019-11-13T09:18:01.6070347Z Detected NuGet version 3.3.0.212 / 3.3.0

2019-11-13T09:18:01.6080113Z SYSTEMVSSCONNECTION exists true

2019-11-13T09:18:01.6080113Z [command]D:\b\4\agent\_work\_tasks\NuGetInstaller_333b11bd-d341-40d9-afcf-b32d5ce6f23b\0.2.31\node_modules\nuget-task-common\NuGet\3.3.0\NuGet.exe restore -NonInteractive D:\b\4\agent\_work\59\s\MestbankPortaal.sln -ConfigFile D:\b\4\agent\_work\59\s\nuget.config

2019-11-13T09:18:02.1119369Z MSBuild auto-detection: using msbuild version '14.0' from 'C:\Program Files (x86)\MSBuild\14.0\bin'.

2019-11-13T09:18:02.4713257Z Feeds used:

2019-11-13T09:18:02.4713257Z   C:\Users\tfsservice\AppData\Local\NuGet\Cache

2019-11-13T09:18:02.4713257Z   C:\Users\tfsservice\.nuget\packages\

2019-11-13T09:18:02.4713257Z   http://tfs:8080/tfs/DefaultCollection/_packaging/Feed/nuget/v3/index.json

2019-11-13T09:18:02.4713257Z   C:\Program Files (x86)\Microsoft SDKs\NuGetPackages\

2019-11-13T09:18:02.4713257Z

2019-11-13T09:18:02.4986705Z Restoring NuGet package IAM.Security.2.6.1.

2019-11-13T09:18:45.2347882Z WARNING: Unable to find version '2.6.1' of package 'IAM.Security'.

2019-11-13T09:18:45.2572523Z Unable to find version '2.6.1' of package 'IAM.Security'.

2019-11-13T09:18:45.2816698Z ##[error]Error: D:\b\4\agent\_work\_tasks\NuGetInstaller_333b11bd-d341-40d9-afcf-b32d5ce6f23b\0.2.31\node_modules\nuget-task-common\NuGet\3.3.0\NuGet.exe failed with return code: 1

2019-11-13T09:18:45.2816698Z ##[error]Packages failed to install

2019-11-13T09:18:45.2855766Z ##[section]Finishing: NuGet restore

This was a package that was recently added to our private Azure Artifacts feed, but I was able to restore it without any problem on my local machine.

Eventually I found out that I could solve the problem by increasing the NuGet version used by the build process to version 4:

Popular posts from this blog

DevToys–A swiss army knife for developers

As a developer there are a lot of small tasks you need to do as part of your coding, debugging and testing activities.  DevToys is an offline windows app that tries to help you with these tasks. Instead of using different websites you get a fully offline experience offering help for a large list of tasks. Many tools are available. Here is the current list: Converters JSON <> YAML Timestamp Number Base Cron Parser Encoders / Decoders HTML URL Base64 Text & Image GZip JWT Decoder Formatters JSON SQL XML Generators Hash (MD5, SHA1, SHA256, SHA512) UUID 1 and 4 Lorem Ipsum Checksum Text Escape / Unescape Inspector & Case Converter Regex Tester Text Comparer XML Validator Markdown Preview Graphic Color B

Help! I accidently enabled HSTS–on localhost

I ran into an issue after accidently enabling HSTS for a website on localhost. This was not an issue for the original website that was running in IIS and had a certificate configured. But when I tried to run an Angular app a little bit later on http://localhost:4200 the browser redirected me immediately to https://localhost . Whoops! That was not what I wanted in this case. To fix it, you need to go the network settings of your browser, there are available at: chrome://net-internals/#hsts edge://net-internals/#hsts brave://net-internals/#hsts Enter ‘localhost’ in the domain textbox under the Delete domain security policies section and hit Delete . That should do the trick…

Azure DevOps/ GitHub emoji

I’m really bad at remembering emoji’s. So here is cheat sheet with all emoji’s that can be used in tools that support the github emoji markdown markup: All credits go to rcaviers who created this list.