crates/wasm-compose/example/service
❯ cargo component build
Compiling bitflags v2.4.1
Compiling wit-bindgen v0.13.1
Compiling cargo-component-bindings v0.4.0
Compiling svc v0.1.0 (/home/tomas/work/workspaces/workflow/simple-wit/wasm-tools/crates/wasm-compose/example/service)
error[E0432]: unresolved import `bindings::exports::example::service::handler::Handler`
--> src/lib.rs:3:59
|
3 | use bindings::exports::example::service::handler::{Error, Handler, Request, Response};
| ^^^^^^^ no `Handler` in `bindings::exports::example::service::handler`
For more information about this error, try `rustc --explain E0432`.
error: could not compile `svc` (lib) due to previous error
Replacing Handler with Guest in both service and middleware sources fixes the issue.
The wasm-componse example seems to be broken:
Replacing
Handler
withGuest
in bothservice
andmiddleware
sources fixes the issue.