aspnet / live.asp.net

Code for live.asp.net, which hosts the ASP.NET Community Stand-up
https://live.asp.net/
MIT License
289 stars 114 forks source link

Unable to restore packages #28

Closed hishamco closed 9 years ago

hishamco commented 9 years ago

I'm facing an issue when I run dnu restore it show unable to locate [dependency]

Eilon commented 9 years ago

Screenshot?

hishamco commented 9 years ago

bug

DamianEdwards commented 9 years ago

Can you show the part where it reports what nuget.config and feeds were used?

hishamco commented 9 years ago

NuGet Config files used: C:\Users\Hisham\AppData\Roaming\NuGet\NuGet.Config C:\Users\Hisham\Source\Repos\live.asp.net\NuGet.Config

hishamco commented 9 years ago

Seems we need to change the NuGet.config to read the online feed, shall I made a PR for that?

DamianEdwards commented 9 years ago

Not sure what you mean. It's working fine for me and during deployment to azure, so it should work everywhere.

hishamco commented 9 years ago

It works now after i add the following feeds:

<add key="AspNetVNext" value="https://www.myget.org/F/aspnetvnext/api/v2" />
<add key="NuGet" value="https://nuget.org/api/v2/" />

if you notice in NuGet.config there's a which causes the issue, I think we need to change the NuGet.config, so let me know if can submit a PR now

hishamco commented 9 years ago

Perhaps all the packages needed is already there in your end?!!

DamianEdwards commented 9 years ago

This project shouldn't be using any packages from the AspNetVNext feed, and everything on the nuget v2 feed should also be on the nuget v3 feed (which is the one this project is using). So we need to figure out the root cause rather than add more feeds.

DamianEdwards commented 9 years ago

Can you try running a restore with --no-cache, e.g. dnu restore --no-cache? With the original nuget.config in the repo.

hishamco commented 9 years ago

I already restore them after adding AspNetVNext feed, is there a way to revert that using command line?

Eilon commented 9 years ago

If you use the --no-cache flag it will ignore any previously installed package. Do a git clean -xdf first, though.

hishamco commented 9 years ago

They restore them without --no-cache?!! shall i remove the packages folder entries?

Eilon commented 9 years ago

Please revert any local changes to the repo, run git clean -xdf and then run dnu restore --no-cache, and then build.

hishamco commented 9 years ago

I already ran git clean -xdf and dnu restore --no-cache, seems restore them quickly from my local packages, strange!! Let me clean the packages & dnu cache folders and try again

hishamco commented 9 years ago

I already did, I got the error that I post in my first thread, but whenever I add the feeds that I mentioned before everything works as excepted. FYI I upgrade the dnvm to 1.0.0-beta7-12302

Eilon commented 9 years ago

Can you run dnu feeds list and show the output? I have a feeling that some feeds are disabled...

hishamco commented 9 years ago

There's a feed named api.nuget.org/v3 which is disabled as you said, believe it or not this is the first time i see this command, please let me know how can I enable it

Eilon commented 9 years ago

Please run the command and show us the output.

hishamco commented 9 years ago

As I told you before, here is a screenshot capture

Eilon commented 9 years ago

Can you run it from within the project folder? The NuGet feeds depend on the exact location of the project.

hishamco commented 9 years ago

capture

DamianEdwards commented 9 years ago

Is there any chance the v3 feed is blocked from your location? Can you browse to that URL?

hishamco commented 9 years ago

Whenever I write that url, json file popups into the browser

DamianEdwards commented 9 years ago

Can you ensure you have the latest VS tooling installed (the beta6 update) as well SSD the latest NuGet VS client. If so, open the feeds config dialog from Tools -> NuGet Package Manager -> Settings and then hit OK.

hishamco commented 9 years ago

I already installed the latest DVNM version, I will check the NuGet version and i will follow your instructions

hishamco commented 9 years ago

Well done :) thanks @DamianEdwards

JimiC commented 9 years ago

The VS tooling for beta 6 is not updating the dnvm.ps1 file and it remains at beta5. I have already left a comment at the VS tooling site about it. You need to manually update the dnvm.ps1 file from the dev branch or execute dnvm update-self (this will update DNVM to beta7 when this is written).

hishamco commented 9 years ago

I already update it myself, but I follow the @DamianEdwards instructions it works fine, thanks @JimiC