Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Github Action][QEMU][aarch64] Install fails #1292

Closed
AzHicham opened this issue Aug 14, 2023 · 11 comments · Fixed by #1308
Closed

[Github Action][QEMU][aarch64] Install fails #1292

AzHicham opened this issue Aug 14, 2023 · 11 comments · Fixed by #1308
Labels
Blocked: upstream Fix or feature is needed to be implemented upstream (in a dependency)

Comments

@AzHicham
Copy link

AzHicham commented Aug 14, 2023

Hello,

I have a simple docker image that fails to build (since last week). It fails when I try to install binstall, the probleme happens only on aarch64 with qemu on github action.
github action / amd64 -> OK
macbook m1 / aarch64 -> OK

My dockerfile:

RUN \
    # Rust Toolchain
    curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain $RUST_VERSION --no-modify-path --profile minimal && \
    # Rust packages
    rustup component add llvm-tools-preview clippy && \
    curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/v1.2.1/install-from-binstall-release.sh | bash && \
    cargo binstall cargo-llvm-cov --no-confirm --locked --version 0.5.26 && \
    cargo binstall cargo-nextest --no-confirm --locked --version 0.9.57 && \
    cargo binstall cargo-sonar --no-confirm --locked --version 0.20.0

Here is the error:

190.4 + target=aarch64-unknown-linux-musl
190.4 + '[' aarch64 == armv7 ']'
190.4 + url=https://github.com/cargo-bins/cargo-binstall/releases/latest/download/cargo-binstall-aarch64-unknown-linux-musl.tgz
190.4 + tar -xvzf -
190.4 + curl -L --proto =https --tlsv1.2 -sSf https://github.com/cargo-bins/cargo-binstall/releases/latest/download/cargo-binstall-aarch64-unknown-linux-musl.tgz
191.6 cargo-binstall
192.0 + ./cargo-binstall -y --force cargo-binstall
192.1 thread 'main' panicked at 'unable to create QUIC endpoint: Os *** code: 92, kind: Uncategorized, message: "Protocol not available" ***', /home/runner/.cargo/registry/src/index.crates.io-6f17d22bba15001f/reqwest-0.11.18/src/async_impl/h3_client/connect.rs:41:58
192.1 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
192.4 bash: line 28:  2776 Aborted                 (core dumped) ./cargo-binstall -y --force cargo-binstall

PS: Issue observed with version v1.1.2 and also v1.2.1

@AzHicham
Copy link
Author

I just found out that even if I want to install binstall v1.1.2 using curl + bash
ie curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/v1.1.2/install-from-binstall-release.sh | bash

It will install the latest release
in sh script -> base_url="https://github.com/cargo-bins/cargo-binstall/releases/latest/download/cargo-binstall-"

Also http3 support has been added recently > v1.2.0

@passcod
Copy link
Member

passcod commented Aug 14, 2023

Hmm reqwest really shouldn't try HTTP/3 if the support isn't available...

In the meantime you can install by downloading the binary directly instead of using the scripts.

@AzHicham
Copy link
Author

Nice!
I download manually the release v1.1.2 an it works :)

Thank you

Feel free to close the issue or wait for a fix :)

@passcod
Copy link
Member

passcod commented Aug 14, 2023

@NobodyXu do you think we could catch that error somehow and opt out of HTTP/3 at runtime or better to report upstream? Also may be a good idea to provide a flag to disable HTTP/3 even when supported.

@NobodyXu
Copy link
Member

@NobodyXu do you think we could catch that error somehow and opt out of HTTP/3 at runtime or better to report upstream? Also may be a good idea to provide a flag to disable HTTP/3 even when supported.

Didn't find anything related to this in reqwest doc, perhaps we should open an issue in upstream.

@NobodyXu NobodyXu added the Blocked: upstream Fix or feature is needed to be implemented upstream (in a dependency) label Aug 14, 2023
@NobodyXu
Copy link
Member

P.S. @AzHicham you could run

cargo binstall cargo-llvm-cov@0.5.26 cargo-nextest@0.9.57 cargo-sonar@020.0 --no-confirm --locked

to speedup installation by resolving and installing in parallel

@NobodyXu
Copy link
Member

@passcod @AzHicham I read the message again and realize that it's the udp protocol that isn't available, not that reqwest cannot fallback to http/2.

@AzHicham Can you try enabling udp support in ur docker and see if it will work?

@AzHicham
Copy link
Author

@NobodyXu Thank you for the tips !!

WDYM by enabling udp support ? base image is debian:11-slim should udp be already enabled ?

@NobodyXu
Copy link
Member

@NobodyXu Thank you for the tips !!

WDYM by enabling udp support ? base image is debian:11-slim should udp be already enabled ?

I think it's a docker issue, it's probably blocked using seccomp filters.

NobodyXu added a commit that referenced this issue Aug 22, 2023
Fixed #1292

Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
github-merge-queue bot pushed a commit that referenced this issue Aug 22, 2023
Fixed #1292

Signed-off-by: Jiahao XU <Jiahao_XU@outlook.com>
@NobodyXu
Copy link
Member

@AzHicham We have released cargo-binstall v1.3.0, which bumps reqwest to v0.11.20 and it should fix this.

@AzHicham
Copy link
Author

AzHicham commented Sep 1, 2023

@NobodyXu Thank you It's working now with version 1.3.0 :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Blocked: upstream Fix or feature is needed to be implemented upstream (in a dependency)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants