-
Notifications
You must be signed in to change notification settings - Fork 1.6k
feat(p3)!: vendor 0.3.0-rc-2026-01-06 #12250
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
Conversation
eba6502 to
71eaef5
Compare
|
I did some splicing/editing/editorializing in #12327. I'm happy to land that (tried to make sure to perserve your authorship) but if you'd prefer to morph those changes back in here I'm happy to merge this as well. Whatever's easiest for you, let me know! |
Update wasmtime's WASI implementation from version 0.3.0-rc-2025-09-16 to 0.3.0-rc-2026-01-06, using wkg for WIT vendoring. This involves API changes in clocks and HTTP.
This can have a loss in precision so this shuffles around some types to ensure that `try_into` and friends are always used instead of `as`. This changes the source-of-truth for timestamps to be `i64` seconds so WASIp2 is the odd-one-out that can't represent negative timestamps.
71eaef5 to
e609d82
Compare
ricochet
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I debated making the as change myself since without that fix, we risk the conversion of seconds as i64 to silently truncate values, and a potential overflow in system_clock::Instant conversion.
Body of the changes LGTM although I see CI is failing.
* Rename `proxy` module to `service` to reflect the WIT world. * Adjust the middleware test to using the `middleware` world.
|
Actually, apologies for the notification overload Pat, I realized that due to the WASIp3 adjacent things @dicej would be a good candidate too, so I'm going to switch to Joel to confirm I didn't get anything wrong here |
dicej
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM; just one question inline.
| wit_bindgen::StreamResult, | ||
| }; | ||
|
|
||
| wit_bindgen::generate!({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the reason for generating the bindings locally here? I.e. what changed such that using the bindings generated in test_programs/src/p3/mod.rs is no longer feasible?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah I tried that initially but it's a wit-bindgen bug. The way the exported macros are generated, namespaced, etc, means that you can't generate, even in separate modules in the same crate, two worlds where the worlds overlap in exports. The middleware/service worlds overlap in their export of wasi:http/handler meaning that putting the two in the same crate would clash. I'll file a bug over on the wit-bindgen side of things for this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specifically, this issue
* feat(p3)!: vendor 0.3.0-rc-2026-01-06 Update wasmtime's WASI implementation from version 0.3.0-rc-2025-09-16 to 0.3.0-rc-2026-01-06, using wkg for WIT vendoring. This involves API changes in clocks and HTTP. * Handle some review comments * Update WASI implementations to avoid `as` This can have a loss in precision so this shuffles around some types to ensure that `try_into` and friends are always used instead of `as`. This changes the source-of-truth for timestamps to be `i64` seconds so WASIp2 is the odd-one-out that can't represent negative timestamps. * Flag expected WASI failures * Get wasi:http tests working again * Rename `proxy` module to `service` to reflect the WIT world. * Adjust the middleware test to using the `middleware` world. --------- Co-authored-by: Alex Crichton <alex@alexcrichton.com>
* Switch to using `wkg` for most WIT vendoring (#12327) * feat(p3)!: vendor 0.3.0-rc-2026-01-06 Update wasmtime's WASI implementation from version 0.3.0-rc-2025-09-16 to 0.3.0-rc-2026-01-06, using wkg for WIT vendoring. This involves API changes in clocks and HTTP. * ci: install wkg in monolith_checks * Revert back to original WIT versions Also refactor the script a bit to avoid too bash-isms and hopefully make it a bit more straightforward what's happening. --------- Co-authored-by: Bailey Hayes <bailey@cosmonic.com> * feat(p3)!: vendor 0.3.0-rc-2026-01-06 (#12250) * feat(p3)!: vendor 0.3.0-rc-2026-01-06 Update wasmtime's WASI implementation from version 0.3.0-rc-2025-09-16 to 0.3.0-rc-2026-01-06, using wkg for WIT vendoring. This involves API changes in clocks and HTTP. * Handle some review comments * Update WASI implementations to avoid `as` This can have a loss in precision so this shuffles around some types to ensure that `try_into` and friends are always used instead of `as`. This changes the source-of-truth for timestamps to be `i64` seconds so WASIp2 is the odd-one-out that can't represent negative timestamps. * Flag expected WASI failures * Get wasi:http tests working again * Rename `proxy` module to `service` to reflect the WIT world. * Adjust the middleware test to using the `middleware` world. --------- Co-authored-by: Alex Crichton <alex@alexcrichton.com> * Update wit-bindgen (#12329) Keeping up-to-date and looking to unblock #12327 --------- Co-authored-by: Bailey Hayes <bailey@cosmonic.com> Co-authored-by: Bailey Hayes <ricochet@users.noreply.github.com>
Update wasmtime's WASI implementation from version
0.3.0-rc-2025-09-16 to 0.3.0-rc-2026-01-06, using wkg for WIT vendoring.
This involves API changes in clocks and HTTP.
By using wkg here, we are also now pointing at the WASI monorepo (closes #9419).