Skip to content

break a lot of stuff to try and see what needs to be done for no_std#900

Draft
brandonros wants to merge 7 commits into
algesten:fix/no-stdfrom
brandonros:no-std-impl
Draft

break a lot of stuff to try and see what needs to be done for no_std#900
brandonros wants to merge 7 commits into
algesten:fix/no-stdfrom
brandonros:no-std-impl

Conversation

@brandonros

@brandonros brandonros commented Dec 1, 2024

Copy link
Copy Markdown

I'm just doing this to be silly/for fun. Not sure if I will finish it. It's kind of therapeutic... Not even sure if I'm doing it the right way... Is there a tool that can migrate this for us? :D

@algesten

algesten commented Dec 1, 2024

Copy link
Copy Markdown
Owner

Yeah. This is sort of the direction I think we need to explore.

I would opt for disabling stuff like gzip compression and the default transport behind the std flag.

It's also worth looking at the ureq-proto PR to see which imports I made and where I put them. I'm thinking of vec! and the order of imports that I try to keep consistent.

The heavy reliance on io::Read in body is a problem. Wonder if there is a
no-std crate to help with that?

Great start!

@brandonros

Copy link
Copy Markdown
Author

@algesten how about now in its current state, do you think it's something I could hand off to you / that you plan to take a deeper look into? I don't have a super pressing need for it, just thought it'd be fun :)

@algesten

algesten commented Dec 1, 2024

Copy link
Copy Markdown
Owner

Sure! Thanks!

@brandonros brandonros mentioned this pull request Dec 1, 2024
@brandonros

Copy link
Copy Markdown
Author

@algesten not sure if this is of any value: https://github.com/hyperium/http/pull/732/files

I was going to try to achieve std + no_std in the same repo in this toy client I made for fun here: https://github.com/brandonros/http_client

but I didn't realize AsyncRead + AsyncWrite trait are heavily tied to std

nrc/portable-interoperable#5

rust-lang/wg-async#23

rust-lang/futures-rs#860

I also don't think fetch (what no_std wasm will boil down to) actually needs async, so it sounds like overkill all around on my end and something you can probably avoid by being nice and simple with sync only

@algesten

algesten commented Dec 1, 2024

Copy link
Copy Markdown
Owner

Interesting! Yeah, async in no_std is a can of worms.

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