An Error Occurred While Trying To Restore Packages
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn an error occurred while trying to restore packages the underlying connection was closed more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags an error occurred while trying to restore packages nuget Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, an error occurred while trying to restore packages unable to find version helping each other. Join them; it only takes a minute: Sign up An error occurred while trying to restore packages. Please try again up vote 14 down vote favorite I am trying to restore the missing nuget packages an error occurred while trying to restore packages unable to connect to the remote server and it keeps giving me this Error: An error occurred while trying to restore packages. Please try again. Any experience solving this? How can I find out what exactly is causing the error? c# nuget nuget-package nuget-package-restore share|improve this question asked Mar 3 '14 at 17:38 user3311522 8032924 add a comment| 3 Answers 3 active oldest votes up vote 15 down vote accepted Make sure you upgrade to the latest NuGet (http://docs.nuget.org/docs/start-here/installing-nuget). Make sure you're doing
An Error Occurred While Trying To Restore Packages. Please Try Again
package restore "The Right Way" http://blog.davidebbo.com/2014/01/the-right-way-to-restore-nuget-packages.html That should resolve the issue. share|improve this answer edited Jan 9 '15 at 15:47 BenAdler 678712 answered Mar 4 '14 at 19:01 Haacked 39.2k1175105 3 Just check for Updates via Tools > Extensions and Updates –Jowen Oct 23 '15 at 9:28 add a comment| up vote 3 down vote I resolved the same issue by downloading the latest version of NuGet (really easy install, quick download): http://docs.nuget.org/docs/start-here/installing-nuget share|improve this answer answered Jan 9 '15 at 15:17 BenAdler 678712 add a comment| up vote 1 down vote If you don't want the package, just double-click your packages.config, find the line which refers to the package you want to get rid of, and delete that line. Then, if you do want the package you could probably just redownload it using nuget and it'd probably resolve itself. share|improve this answer answered Aug 12 '14 at 18:13 Jared Beach 507616 add a comment| Your Answer draft saved draft discarded Sign up or log in Sign up using Google Sign up using Facebook Sign up using Email and Password Post as a guest Name Email Post as a guest Name Email discard By posting your answer, you agree to the privacy policy and terms of service. Not the answer you're looking for? Browse other questions tagged c# nuget nuget-package nuget-package-restore or ask y
Heath Stewart Application Lifecycle Management Application Insights Release Management Team Foundation Server Testing Visual Studio Team Services All Languages Visual C++ Visual F# JavaScript TypeScript Python .NET .NET .NET with Beth Massi
An Error Occurred While Configuring The Solution To Restore Nuget Packages On Build
ASP.NET by Scott Hanselman OData Team WPF Platform Development Apps for Windows Bing Edge error occurred while restoring nuget packages the method or operation is not implemented Microsoft Azure Office 365 Development Web Data Development SQL Server SQL Server Data Tools DocumentDB .NET Blog A first-hand look from error occurred while restoring nuget packages unable to locate the solution directory the .NET engineering teams NuGet Package Restore Issues ★★★★★★★★★★★★★★★ June 12, 2013July 7, 2015 by Immo Landwerth [MSFT] // 23 Comments 0 0 0 We’ve received several reports that our NuGet packages broke the NuGet http://stackoverflow.com/questions/22153474/an-error-occurred-while-trying-to-restore-packages-please-try-again package restore feature. In this post, I’ll explain what the issue is, how you can work around it, and finally how we plan on fixing this issue in the long term. The problem and solution Microsoft.Bcl.Build and Microsoft.Bcl.Compression require custom target files, which do not work well with NuGet’s package restore feature. The easiest way to fix the package restore issues is by checking in any .targets files that https://blogs.msdn.microsoft.com/dotnet/2013/06/12/nuget-package-restore-issues/ are stored under the packages directory. What’s package restore? When you add a NuGet package to your project, NuGet essentially does two things: It downloads the package and puts it in your solution under a directory called “packages”. It installs the package to your project. This will add references to additional framework assemblies, references to assemblies provided by the NuGet package, add additional content to your project and last, but not least, import any custom target files. Of course, not all NuGet packages use all those features. In order to build your project on a build server you have to check in all sources as well as all 3rd party libraries. Many developers cringe when binaries need to be checked in to version control as they typically aren’t stored very efficiently and cause bloat over time. This is especially problematic for distributed version control systems (DVCS) like git or Mercurial where developers have to download the repository with the entire history (typically referred to as “cloning”). For that reason NuGet has a feature called package restore. You need to enable that feature explicitly by right-clicking your solution and invoking the Enable NuGet Package Restore menu item: After package restore is enabled you can delete the “packages”
feature is built in, so you no longer need to http://blog.davidebbo.com/2011/08/easy-way-to-set-up-nuget-to-restore.html use the NuGetPowerTools. Just right click on the Solution and choose ‘Enable NuGet Package Restore’. A few months ago, I described a workflow that lets you use NuGet without committing the packages to source control. This has been a very popular workflow, and generally works quite well. The down side error occurred is that it’s a bit painful to set up: you have to get NuGet.exe and add it to your tree, then you have to add a pre-build event for every project that uses NuGet. The good news is that the ever-resourceful David Fowler has come up with a much easier error occurred while way to set that up, using his NuGetPowerTools package. Here is the way to do it: Let’s assume that you have a solution that is either already using NuGet, or planning to use it, and that you want to set up the no-commit workflow. Now, you just need to go to the Package Manager Console and run a couple commands: PM> Install-Package NuGetPowerTools Successfully installed 'NuGetPowerTools 0.28'. ********************************************************************************** INSTRUCTIONS ********************************************************************************** - To enable building a package from a project use the Enable-PackageBuild command - To enable restoring packages on build use the Enable-PackageRestore command. - When using one of the above commands, a .nuget folder will been added to your solution root. Make sure you check it in! - For for information, see https://github.com/davidfowl/NuGetPowerTools ********************************************************************************** PM> Enable-PackageRestore Attempting to resolve dependency 'NuGet.CommandLine (≥ 1.4)'. Successfully installed 'NuGet.CommandLine 1.4.20615.182'. Successfully installed 'NuGet.Build 0.16'. Copying nuget.exe and msbuild scripts to D:\Code\StarterApps\