1. I have a project with package restore enabled and has following references
<package id="Microsoft.AspNet.WebApi" version="4.1.0-alpha-121009" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Client" version="4.1.0-rtm-130109" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Core" version="4.1.0-rtm-130109" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.HelpPage" version="0.2.0-alpha-121107" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.OData" version="4.0.0-rtm-130103" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Tracing" version="0.2.0-alpha-121025" targetFramework="net45" />
2. The alpha packages are now removed/delete from the feed
3. Now when I build the project to restore the package it reports an error Microsoft.ASPnet.webapi
and microsoft.aspnet.webapi.tracing not found in the feed and *VS hangs*
investigating found that during build it keeps pinging
https://nuget.org/api/v2/FindPackagesById()?id='Microsoft.AspNet.WebApi.Tracing'
and
https://nuget.org/api/v2/FindPackagesById()?id='Microsoft.AspNet.WebApi'
I feel the problem is with the following in nuget.targets
where it first fails to restore the packages and assemblies are not resolved.
And then on each build it retires to download the missing packages = the number of assemblies with reference not resolved correctly
<ResolveReferencesDependsOn Condition="$(RestorePackages) == 'true'">
RestorePackages;
$(ResolveReferencesDependsOn);
</ResolveReferencesDependsOn>
Comments: Another user ran into this issue with the following scenario: I think this was the repro, but it was a couple of days ago, so let me know if it doesn’t work. 1. Create a new solution/project. 2. In the solution, reference a NuGet package that hasn’t yet been published (the feed exists, but the package isn’t yet there). a. One way to do this: Use Web Stack 2 Refresh installer and create a Web API solution. Since we haven’t yet gone RTM, the solution will locally add packages, but they won’t be there if you try to download via NuGet. 3. Put the solution somewhere in source control (like Git). Don’t include the packages (use restore packages instead). 4. Go to another machine (or Git clone directory). Open VS and try to restore packages. 5. Note that NuGet.exe spins repeatedly, locking VS. a. With my Web API project, it took about 2 minutes for VS to come back, and it looked like NuGet.exe spawned and immediately died over 100 times.
<package id="Microsoft.AspNet.WebApi" version="4.1.0-alpha-121009" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Client" version="4.1.0-rtm-130109" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Core" version="4.1.0-rtm-130109" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.HelpPage" version="0.2.0-alpha-121107" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.OData" version="4.0.0-rtm-130103" targetFramework="net45" />
<package id="Microsoft.AspNet.WebApi.Tracing" version="0.2.0-alpha-121025" targetFramework="net45" />
2. The alpha packages are now removed/delete from the feed
3. Now when I build the project to restore the package it reports an error Microsoft.ASPnet.webapi
and microsoft.aspnet.webapi.tracing not found in the feed and *VS hangs*
investigating found that during build it keeps pinging
https://nuget.org/api/v2/FindPackagesById()?id='Microsoft.AspNet.WebApi.Tracing'
and
https://nuget.org/api/v2/FindPackagesById()?id='Microsoft.AspNet.WebApi'
I feel the problem is with the following in nuget.targets
where it first fails to restore the packages and assemblies are not resolved.
And then on each build it retires to download the missing packages = the number of assemblies with reference not resolved correctly
<ResolveReferencesDependsOn Condition="$(RestorePackages) == 'true'">
RestorePackages;
$(ResolveReferencesDependsOn);
</ResolveReferencesDependsOn>
Comments: Another user ran into this issue with the following scenario: I think this was the repro, but it was a couple of days ago, so let me know if it doesn’t work. 1. Create a new solution/project. 2. In the solution, reference a NuGet package that hasn’t yet been published (the feed exists, but the package isn’t yet there). a. One way to do this: Use Web Stack 2 Refresh installer and create a Web API solution. Since we haven’t yet gone RTM, the solution will locally add packages, but they won’t be there if you try to download via NuGet. 3. Put the solution somewhere in source control (like Git). Don’t include the packages (use restore packages instead). 4. Go to another machine (or Git clone directory). Open VS and try to restore packages. 5. Note that NuGet.exe spins repeatedly, locking VS. a. With my Web API project, it took about 2 minutes for VS to come back, and it looked like NuGet.exe spawned and immediately died over 100 times.