Skip to content

Adding HTTP2 support by using rustls#73

Open
leo-ars wants to merge 1 commit intohuggingface:mainfrom
leo-ars:main
Open

Adding HTTP2 support by using rustls#73
leo-ars wants to merge 1 commit intohuggingface:mainfrom
leo-ars:main

Conversation

@leo-ars
Copy link
Copy Markdown

@leo-ars leo-ars commented Apr 30, 2025

HTTP2 seems not to be supported with the current implementation of hf_transfer because it's using native-tls without native-tls-alpn.
I am adding rustls-tls and use_rustls_tls() to be sure we negotiate ALPN correctly and allow HTTP2 protocol.

According to this seanmonstar/reqwest#2350, rustls-tls is better than native-tls for compatibility across platform.

@leo-ars leo-ars changed the title Adding ALPN and HTTP2 support by using rustls Adding HTTP2 support by using rustls Apr 30, 2025
@leo-ars leo-ars mentioned this pull request Apr 30, 2025
@michaelfeil
Copy link
Copy Markdown

rusttls would work, but requires come hacks to cross-compile to arm, where you need to add different manylinux to build for newer than 2014 compilers.
On manylinux-2014, this pr would otherwise break the crypto backend of rustls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants