teamcity-nuget-support
teamcity-nuget-support copied to clipboard
Failed to install packages even though they exist
Just wanted to get some ideas on this as there seem to be a few people facing the same issue and most of them are using teamcity
https://github.com/NuGet/Home/issues/7699
I downloaded the latest Nuget 4.9.4 and wrote a small Powershell script to continually loop and delete, clear caches and restore packages and it did not log a single error about not being able to pull packages, unfortunately when run using the teamcity nuget step it almost seems to be 50/50 whether the issue will occur or not.
Script (run from .net project root directory)
while($true)
{
Remove-Item packages -Recurse -ErrorAction Ignore
nuget locals global-packages -clear
nuget restore -NoCache
$native_call_success = $?
if (-not $native_call_success)
{
throw 'error making native call'
}
Start-Sleep 10
}
and run like
.\restoretest.ps1 2>> error.log 3>> warning.log
There are no firewalls enabled proxies that I'm aware of on that machine/network that would intermittently effect network connectivity.