nim-lang / choosenim

Official tool for easily installing and managing multiple versions of the Nim programming language.
BSD 3-Clause "New" or "Revised" License
36 stars 8 forks source link

Can't install choosenim via init.sh - curl: (22) The requested URL returned error: 404 #11

Closed air3ijai closed 3 months ago

air3ijai commented 3 months ago

We can't install choosenim on Unix

curl https://nim-lang.org/choosenim/init.sh -sSf | sh

choosenim-init: Downloading choosenim-0.8.4_linux_amd64
curl: (22) The requested URL returned error: 404

Looks like init.sh (choosenim-unix-init.sh?) is looking for an artifact which does not exist

curl -sSfL https://github.com/nim-lang/choosenim/releases/download/v0.8.4/choosenim-0.8.4_linux_amd64 -o /tmp/choosenim-0.8.4_linux_amd64

which is returned by the request

curl -sSfL https://nim-lang.org/choosenim/stable
0.8.4
smk762 commented 3 months ago

I've temporarily sidestepped this with sed to use the old url https://github.com/KomodoPlatform/komodo-wallet-desktop/commit/a3db7f3eaaa229ac307f6a27c1b59b076b5c5b25

PMunch commented 3 months ago

You caught us in the middle of the update, if instead of using the old URL you force the version to 0.8.5 it should work and now be tied to this version so that choosenim update self will work in the future.

ringabout commented 3 months ago

@air3ijai @smk762

Hi, would you mind trying again? I pushed a hot fix for a transition period. The version will be updated correctly later

image

Though you might need to use latest choosenim versions namely: 0.8.4 and 0.8.5

air3ijai commented 3 months ago

@ringabout, did a check on clean Ubuntu

apt update
apt install build-essential

curl https://nim-lang.org/choosenim/init.sh -sSf | sh

All works as expected, CI is green now - thank you for the quick fix!

cipig commented 3 months ago

doesn't work any more with ubuntu-20.04:

choosenim-init: Downloading choosenim-0.8.5_linux_amd64
/tmp/choosenim-0.8.5_linux_amd64: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.33' not found (required by /tmp/choosenim-0.8.5_linux_amd64)
/tmp/choosenim-0.8.5_linux_amd64: /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found (required by /tmp/choosenim-0.8.5_linux_amd64)
Error: Process completed with exit code 1.
ringabout commented 2 months ago

@cipig Hello, I have downgraded the built environment to ubuntu 20.04 as a workaround => https://github.com/nim-lang/choosenim/pull/15 Would you mind trying again?

air3ijai commented 2 months ago

Did a test on clean Ubuntu 20.04 VM

Ubuntu version ```shell cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=20.04 DISTRIB_CODENAME=focal DISTRIB_DESCRIPTION="Ubuntu 20.04.6 LTS" ``` ```shell uname -a Linux ubuntu-20-04 5.4.0-189-generic #209-Ubuntu SMP Fri Jun 7 14:05:13 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux ```
choosenim installation ```shell apt update && apt install -y gcc ``` ```shell curl https://nim-lang.org/choosenim/init.sh -sSf | sh choosenim-init: Downloading choosenim-0.8.5_linux_amd64 Downloading Nim 2.0.8 from nim-lang.org [##################################################] 100.0% 0kb/s Extracting nim-2.0.8-linux_x64.tar.xz Extracting nim-2.0.8-linux_x64.tar Building Nim 2.0.8 Compiler: Already built Installed component 'nim' Installed component 'nimble' Installed component 'nimgrep' Installed component 'nimpretty' Installed component 'nimsuggest' Installed component 'testament' Installed component 'nim-gdb' Switched to Nim 2.0.8 choosenim-init: ChooseNim installed in /root/.nimble/bin choosenim-init: You must now ensure that the Nimble bin dir is in your PATH. choosenim-init: Place the following line in the ~/.profile or ~/.bashrc file. choosenim-init: export PATH=/root/.nimble/bin:$PATH export PATH=/root/.nimble/bin:$PATH ```
GLIBC version ```shell ldd --version ldd (Ubuntu GLIBC 2.31-0ubuntu9.16) 2.31 Copyright (C) 2020 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Written by Roland McGrath and Ulrich Drepper. ```
choosenim --version

choosenim v0.8.5 (2024-08-26 14:07:45) [linux/amd64]