Home: VS2015.3: Can't install any nuget package with error: Install failed. Rolling back...

Created on 12 Jul 2016  路  9Comments  路  Source: NuGet/Home

I'm using Win10 + VS2015 Update 3 + Nuget3.4.4 and create a simple c# console solution, I always get the following error when installing any nuget package. I restarted or even reinstalled different version of Nuget manager per google search result, but no lucky.

Attempting to gather dependencies information for package 'EntityFramework.6.1.3' with respect to project 'TestConsole', targeting '.NETFramework,Version=v4.6.1'
Attempting to resolve dependencies for package 'EntityFramework.6.1.3' with DependencyBehavior 'Lowest'
Resolving actions to install package 'EntityFramework.6.1.3'
Resolved actions to install package 'EntityFramework.6.1.3'
Adding package 'EntityFramework.6.1.3' to folder 'D:\VisualStudioProjects\VS2015\TestConsole\packages'
Added package 'EntityFramework.6.1.3' to folder 'D:\VisualStudioProjects\VS2015\TestConsole\packages'
-Install failed. Rolling back...
Package 'EntityFramework.6.1.3 : ' does not exist in project 'TestConsole'
Removing package 'EntityFramework.6.1.3 : ' from folder 'D:\VisualStudioProjects\VS2015\TestConsole\packages'
Removed package 'EntityFramework.6.1.3 : ' from folder 'D:\VisualStudioProjects\VS2015\TestConsole\packages'
Failed to add reference to 'EntityFramework'.
========== Finished ==========

Most helpful comment

Same issue.
Reinstalled - didn't work
Repair - didn't work
C:\Users{{username}}\AppData\Roaming - Delete Nuget.config - didn't work

Anymore suggestions?

All 9 comments

I was encountering the same problem with Visual Studio 2015.3. I performed a repair on my visual studio and Nuget is now functioning correctly.

@erich-wang - Can you try a repair on VS like @siobhanc tried?

I was facing the same issue. performing repair on visual studio did the job.

Same issue here. Repairing VS didn't help. Reinstalling didn't help too.
VS 2015 Enterprise Update 3 (v14.0.25425.01), NuGet 3.4.4

Repairing VS one more time fix problem. Very strange things happening here...

http://stackoverflow.com/questions/32344232/unable-to-install-any-package-in-visual-studio-2015
Go to this path: C:\Users{{username}}\AppData\Roaming\
Delete Nuget.config
Restart VS for good measure

Same issue.
Reinstalled - didn't work
Repair - didn't work
C:\Users{{username}}\AppData\Roaming - Delete Nuget.config - didn't work

Anymore suggestions?

We have not been able to reproduce this issue. If you are still able to reproduce this with the latest NuGet version, please provide additional steps.聽

Similar issue. Seems to be part of greater issues with Visual Studio. I just "repaired" Visual Studio. Could be Oracle related?

Unbound from TFS source control and the package successfully installed.

Install failed. Rolling back...
Removed package 'jQuery.1.4.4' from 'packages.config'
Removing package 'jQuery.1.4.4' from folder 'C:\Users\myname\Documents\TFS\IOTracker\Dev\packages'
Removed package 'jQuery.1.4.4' from folder 'C:\Users\myname\Documents\TFS\IOTracker\Dev\packages'
Executing nuget actions took 2.83 sec
System.NullReferenceException: Object reference not set to an instance of an object.
   at EnvDTE.SourceControl.IsItemUnderSCC(String ItemName)
   at NuGet.PackageManagement.VisualStudio.DTESourceControlUtility.EnsureCheckedOutIfExists(SourceControl sourceControl, String fullPath)
   at NuGet.PackageManagement.VisualStudio.EnvDTEProjectUtility.EnsureCheckedOutIfExists(Project envDTEProject, String root, String path)
   at NuGet.PackageManagement.VisualStudio.VsMSBuildProjectSystem.AddFileCoreAsync(String path, Action addFile)
   at NuGet.PackageManagement.VisualStudio.VsMSBuildProjectSystem.<>c__DisplayClass32_0.<<AddExistingFile>b__0>d.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Microsoft.VisualStudio.Threading.JoinableTask.CompleteOnCurrentThread()
   at NuGet.PackageManagement.VisualStudio.VsMSBuildProjectSystem.AddExistingFile(String path)
   at NuGet.ProjectManagement.MSBuildNuGetProject.<InstallPackageAsync>d__35.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteInstallAsync>d__83.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__74.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__74.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__74.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.NuGetPackageManager.<ExecuteNuGetProjectActionsAsync>d__73.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at NuGet.PackageManagement.UI.UIActionEngine.<ExecuteActionsAsync>d__11.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
   at NuGet.PackageManagement.UI.UIActionEngine.<>c__DisplayClass7_0.<<PerformActionImplAsync>b__0>d.MoveNext()
Time Elapsed: 00:00:03.5414975
========== Finished ==========
Was this page helpful?
0 / 5 - 0 ratings