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

Support wasm32-wasip2 on the stable channel #25

Closed
brooksmtownsend opened this issue Oct 18, 2024 · 4 comments · Fixed by #26
Closed

Support wasm32-wasip2 on the stable channel #25

brooksmtownsend opened this issue Oct 18, 2024 · 4 comments · Fixed by #26

Comments

@brooksmtownsend
Copy link

Hey! 👋🏻

First of all, I'm hugely inspired by how simple this crate makes wasi:http in Rust. It looks really nice, and your implementations feel nice and idiomatic. I was going to do something similar to this for https://wasmcloud.com/, but it looks like you've already done a lot of what I was hoping for 😄

Since this crate depends on url, I'm pretty familiar with one of the small hiccups that affected wasm32-wasip2 on the nightly toolchain servo/rust-url#960. I just filed an upstream PR to fix this for the stable toolchain as well servo/rust-url#983, but I want to be sensitive to how prevalent the url crate is and that this target just landed in Rust 1.82.0. I would love to use this library, selfishly for https://crates.io/crates/wasmcloud-component. To be clear, we're using the wasmcloud-component essentially as a stopgap for things that don't exist in the wasi crate and its wrappers are all wasi-p2 compatible.

Anyways, do you have any thoughts on ways we can support this crate for wasm32-wasip2 on the stable channel in the meantime?

@brooksmtownsend
Copy link
Author

I suppose another possible rabbit hole here is that the request code looks similarly structured to reqwest seanmonstar/reqwest#2294, what do you think about collaborating there to add support to that library, or are you more interested in having a wasi-first library here

@iawia002
Copy link
Member

Hi @brooksmtownsend, thanks for your interest in this project, I do want to have a wasi-first library here.

Actually, I have already been working on fixing this issue. Since the release of Rust 1.82, I have noticed the problem, and I have also seen your patch in the rust-url crate. I am planning to stop relying on the url crate. A new version will be released in the next few days.

@iawia002
Copy link
Member

I have released v0.4.0, please give it a try.

@brooksmtownsend
Copy link
Author

brooksmtownsend commented Oct 21, 2024

Amazing! I'll give it a shot today. Great Monday present @iawia002

This worked for me out of the box, which is great 🙂 This motivated me to pick back up working on the reqwest support

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 a pull request may close this issue.

2 participants