aspnet / dnvm

OBSOLETE - see readme
Other
174 stars 61 forks source link

dmvm install does not inflate package #477

Closed tezli closed 6 years ago

tezli commented 8 years ago

Reproduction

OS : OS X "El Capitan 10.11"

dnvm install -r coreclr -arch x64 latest

downloads nuget package correctly to :

~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8/dnx-coreclr-darwin-x64.nupkg

but does not unzip, so no bin folder is available.

running :

dnvm use -r coreclr -arch x64 1.0.0-beta8

shows :

Cannot find dnx-coreclr-darwin-x64.1.0.0-beta8, do you need to run 'dnvm install 1.0.0-beta8'?

Workaround :

unzip ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8/dnx-coreclr-darwin-x64.nupkg -d \
~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8 && \
chmod +x ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8/bin/dnx && \
chmod +x ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8/bin/dnu
BrennanConroy commented 8 years ago

What version of dnvm?

satoryu commented 8 years ago

I'm facing with the same issue. My dnvm's version is 1.0.0-rc2-15546. I installed it with homebrew on Mac OS X El Capitan (10.11.4).

dnvm list shows

$ dnvm list
Active Version              Runtime Architecture OperatingSystem Alias
------ -------              ------- ------------ --------------- -----
       1.0.0-rc1-update2    coreclr x64          darwin
       1.0.0-rc1-update2    mono                 linux/osx

When trying to specify a runtime with dnvm use, it shows

$ dnvm use 1.0.0-rc1-update2 -r coreclr -a x64
Cannot find dnx-coreclr-darwin-x64.1.0.0-rc1-update2, do you need to run 'dnvm install 1.0.0-rc1-update2'?

When specifying -r mono, the same result is shown.

Do you have any idea?

BrennanConroy commented 8 years ago

Try dnvm list -detailed to show the location of the runtimes, then ls that folder to see what is actually there

satoryu commented 8 years ago

I did it. I found one nupkg file.

$ dnvm list -detailed

Active Version              Runtime Architecture OperatingSystem Alias Location
------ -------              ------- ------------ --------------- ----- --------
       1.0.0-rc1-update2    coreclr x64          darwin                ~/.dnx/runtimes
       1.0.0-rc1-update2    mono                 linux/osx             ~/.dnx/runtimes

$ ls -l ~/.dnx/runtimes/
total 0
drwxr-xr-x  3 tatsuya.b.sato  679754705  102 Apr  4 00:59 dnx-coreclr-darwin-x64.1.0.0-rc1-update2
drwxr-xr-x  3 tatsuya.b.sato  679754705  102 Apr  4 00:58 dnx-mono.1.0.0-rc1-update2
$ ls -l ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/
total 27888
-rw-r--r--  1 tatsuya.b.sato  679754705  14277178 Apr  4 00:59 dnx-coreclr-darwin-x64.1.0.0-rc1-update2.nupkg
BrennanConroy commented 8 years ago

Odd, was there an error while installing dnx? Delete the dnx-coreclr-darwin-x64.1.0.0-rc1-update2 folder and try again, it should unzip the nupkg instead of leaving it there

satoryu commented 8 years ago

umm, I removed the dir and did dnvm install -r coreclr again but still have the same problem...

$ rm -rf  ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/
$ ls  ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/
ls: /Users/tatsuya.b.sato/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/: No such file or directory
$ dnvm install latest -r coreclr
Determining latest version
Latest version is 1.0.0-rc1-update2
Downloading dnx-coreclr-darwin-x64.1.0.0-rc1-update2 from https://www.nuget.org/api/v2
Download: https://www.nuget.org/api/v2/package/dnx-coreclr-darwin-x64/1.0.0-rc1-update2
######################################################################## 100.0%
 fetching dnx-coreclr-darwin-x64.1.0.0-rc1-update2 from https://www.nuget.org/api/v2
$ dnvm list

Active Version              Runtime Architecture OperatingSystem Alias
------ -------              ------- ------------ --------------- -----
       1.0.0-rc1-update2    coreclr x64          darwin
       1.0.0-rc1-update2    mono                 linux/osx

$ ls ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/dnx-coreclr-darwin-x64.1.0.0-rc1-update2.nupkg
/Users/tatsuya.b.sato/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/dnx-coreclr-darwin-x64.1.0.0-rc1-update2.nupkg
$ ls -l  ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/
total 27888
-rw-r--r--  1 tatsuya.b.sato  679754705  14277178 Apr  5 01:02 dnx-coreclr-darwin-x64.1.0.0-rc1-update2.nupkg
BrennanConroy commented 8 years ago

fetching dnx-coreclr-darwin-x64.1.0.0-rc1-update2 from https://www.nuget.org/api/v2

There should be "HTTP Error " in front of that line, it means you didn't get a 200 or 302 result when getting the nupkg so it failed to install successfully.

You can do __dnvm_unpack ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/dnx-coreclr-darwin-x64.1.0.0-rc1-update2.nupkg ~/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-rc1-update2/

satoryu commented 8 years ago

I did it! now dnvm use works! thanks!

btw, what's the root cause?

BrennanConroy commented 8 years ago

For some reason you were getting an HTTP response code dnvm didn't like so it exited and it didn't clean-up the folders it partially created.

mbhoek commented 8 years ago

I had the same problem on a virgin Ubuntu installation.

Turns out I needed to install the unzip package before using dnvm.