Looking into it but when I try to build hello-wasi-http with the latest release i get the following error several times
error[internal]: left behind trailing whitespace
--> <stdin>:6490:6490:1
|
6490 |
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
followed by
thread 'main' panicked at /Users/interpretations/.cargo/registry/src/index.crates.io-6f17d22bba15001f/wit-bindgen-rust-0.20.0/src/lib.rs:1107:13:
assertion failed: status.success()
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
From what I can tell it seems that wit-bindgen is struggling specifically with wasi:http/proxy... seems to handle the other wasi interfaces just fine.
Ugh, it's unfortunate we're not gracefully handling rustfmt
failure exit status in wit-bindgen-rust
. Not sure why rustfmt
is failing, but it's probably something that can be worked around if wit-bindgen
wasn't generating trailing whitespace; I'd start by filing an issue in wit-bindgen
.
You can work around this for now in cargo-component
by setting package.metadata.component.bindings.format
to false
in Cargo.toml
Did the trick. Thanks!
Will open that issue
It looks like Dan might have beat us to the punch: https://github.com/bytecodealliance/wit-bindgen/pull/878
awesome
@Peter Huene would it perhaps be an idea to switch from cargo fmt
to prettyplease for this?
ooh, that seems like the right thing to use for wit-bindgen
I've used it in html-bindgen
before, and it worked surprisingly well!
do you mind opening an issue in wit-bindgen
to switch it over?
yep, can do!
(or just putting up a PR)
thanks!
Filed: https://github.com/bytecodealliance/wit-bindgen/issues/880
Last updated: Nov 25 2024 at 19:03 UTC