Stream: git-wasmtime

Topic: wasmtime / PR #12250 feat(p3)!: vendor 0.3.0-rc-2026-01-06


view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:17):

ricochet opened PR #12250 from ricochet:p3-rc-01-6 to bytecodealliance:main:

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).

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:17):

ricochet requested wasmtime-wasi-reviewers for a review on PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:17):

ricochet requested fitzgen for a review on PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:17):

ricochet requested wasmtime-core-reviewers for a review on PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:17):

ricochet requested wasmtime-default-reviewers for a review on PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:29):

ricochet updated PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton created PR review comment:

If you'd like, an output file of $path/$pkg_name.wit would also work to avoid the $pkg_name/$pkg_name

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton created PR review comment:

This top-level of addition of a wit directory might be accidental?

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton created PR review comment:

How come here (and a number of other locations in this PR) are now specifying features? Would it be possible to omit them?

The annotations in the adapter, for example, I think are load bearing in the sense that we don't want to activate them there ideally.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton created PR review comment:

Was this a stray addition? Most of the other folders don't have wkg.lock and given that we're already pinning versions I'd imagine that we could probably eschew having this entirely, but I'm also not too too familiar with wkg.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 06 2026 at 19:44):

alexcrichton requested alexcrichton for a review on PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:01):

ricochet submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:01):

ricochet created PR review comment:

I think generally wkg.lock should always be included like a Cargo.lock. We could add a gitignore but when running wkg and the vendor step it will always create this.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:16):

ricochet submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:16):

ricochet created PR review comment:

I may need some help diagnosing. It seems like bindgen here is either configured for all features or previously relied on not receiving wit with unstable.

When not specifying features:

cargo test --package wasmtime-wasi --test all -- p2_api_reactor
   Compiling test-programs-artifacts v0.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/test-programs/artifacts)
error: failed to run custom build command for `test-programs-artifacts v0.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/test-programs/artifacts)`

Caused by:
  process didn't exit successfully: `/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-09b249d84a25b153/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/cli.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/clocks.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/filesystem.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/io.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/random.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/sockets.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/test.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/world.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter/build.rs
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter/byte-array-literals/src/lib.rs
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter/src/descriptors.rs
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter/src/lib.rs
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter/src/macros.rs
  wasi reactor adapter: "/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out/wasi_snapshot_preview1.reactor.wasm"
  wasi command adapter: "/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out/wasi_snapshot_preview1.command.wasm"
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/cli.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/clocks.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/filesystem.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/http.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/io.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/random.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/deps/sockets.wit
  cargo:rerun-if-changed=/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-http/wit/world.wit
  wasi proxy adapter: "/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out/wasi_snapshot_preview1.proxy.wasm"
  cargo:rerun-if-env-changed=MIRI_TEST_CWASM_DIR

  --- stderr
  running: env -u CARGO_ENCODED_RUSTFLAGS CARGO_TARGET_DIR="/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out" RUSTFLAGS="" "cargo" "build" "--release" "--package=wasi-preview1-component-adapter" "--target=wasm32-unknown-unknown"
     Compiling wasi-preview1-component-adapter v41.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter)
      Finished `release` profile [optimized] target(s) in 1.10s
  running: env -u CARGO_ENCODED_RUSTFLAGS CARGO_TARGET_DIR="/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out" RUSTFLAGS="" "cargo" "build" "--release" "--package=wasi-preview1-component-adapter" "--target=wasm32-unknown-unknown" "--no-default-features" "--features=command"
     Compiling wasi-preview1-component-adapter v41.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter)
      Finished `release` profile [optimized] target(s) in 0.93s
  running: env -u CARGO_ENCODED_RUSTFLAGS CARGO_TARGET_DIR="/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out" RUSTFLAGS="" "cargo" "build" "--release" "--package=wasi-preview1-component-adapter" "--target=wasm32-unknown-unknown" "--no-default-features" "--features=proxy"
     Compiling wasi-preview1-component-adapter v41.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi-preview1-component-adapter)
      Finished `release` profile [optimized] target(s) in 0.40s
  running: env -u CARGO_ENCODED_RUSTFLAGS CARGO_PROFILE_DEV_DEBUG="2" CARGO_TARGET_DIR="/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out" RUSTFLAGS="" "cargo" "build" "--target=wasm32-wasip1" "--package=test-programs"
     Compiling test-programs v0.0.0 (/Users/bhayes/repos/bytecodealliance/wasmtime/crates/test-programs)
  error: failed to resolve directory while parsing WIT for path [/Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit]

         Caused by:
           interface not found in package
              --> /Users/bhayes/repos/bytecodealliance/wasmtime/crates/wasi/src/p2/wit/deps/cli.wit:174:22
               |
           174 |   import wasi:clocks/timezone@0.2.6;
               |                      ^-------
   --> crates/test-programs/src/bin/p2_api_reactor.rs:3:1
    |
  3 | / wit_bindgen::generate!({
  4 | |     world: "test-reactor",
  5 | |     path: "../wasi/src/p2/wit",
  6 | |     generate_all,
  7 | | });
    | |__^
    |
    = note: this error originates in the macro `wit_bindgen::generate` (in Nightly builds, run with -Z macro-backtrace for more info)

  error: cannot find macro `export` in this scope
    --> crates/test-programs/src/bin/p2_api_reactor.rs:11:1
     |
  11 | export!(T);
     | ^^^^^^

  error[E0405]: cannot find trait `Guest` in this scope
    --> crates/test-programs/src/bin/p2_api_reactor.rs:18:6
     |
  18 | impl Guest for T {
     |      ^^^^^ not found in this scope
     |
  help: consider importing one of these traits
     |
   1 + use test_programs::p3::exports::wasi::cli::run::Guest;
     |
   1 + use test_programs::p3::proxy::exports::wasi::http::handler::Guest;
     |
   1 + use test_programs::proxy::exports::wasi::http::incoming_handler::Guest;
     |
   1 + use wasip2::exports::cli::run::Guest;
     |
     = and 1 other candidate

  error[E0412]: cannot find type `OutputStream` in this scope
    --> crates/test-programs/src/bin/p2_api_reactor.rs:36:28
     |
  36 |     fn write_strings_to(o: OutputStream) -> Result<(), ()> {
     |                            ^^^^^^^^^^^^ not found in this scope
     |
  help: consider importing one of these items
     |
   1 + use test_programs::wasi::cli::stderr::OutputStream;
     |
   1 + use test_programs::wasi::cli::stdout::OutputStream;
     |
   1 + use test_programs::wasi::filesystem::types::OutputStream;
     |
   1 + use test_programs::wasi::http::types::OutputStream;
     |
     = and 9 other candidates

  error[E0433]: failed to resolve: use of unresolved module or unlinked crate `wasi`
    --> crates/test-programs/src/bin/p2_api_reactor.rs:67:38
     |
  67 |     fn pass_an_imported_record(stat: wasi::filesystem::types::DescriptorStat) -> String {
     |                                      ^^^^ use of unresolved module or unlinked crate `wasi`
     |
     = help: if you wanted to use a crate named `wasi`, use `cargo add wasi` to add it to your `Cargo.toml`
  help: consider importing one of these modules
     |
   1 + use test_programs::p3::wasi::filesystem::types;
     |
   1 + use test_programs::wasi::filesystem::types;
     |
   1 + use wasip2::filesystem::types;
     |
  help: if you import `types`, refer to it directly
     |
  67 -     fn pass_an_imported_record(stat: wasi::filesystem::types::DescriptorStat) -> String {
  67 +     fn pass_an_imported_record(stat: types::DescriptorStat) -> String {
     |

  Some errors have detailed explanations: E0405, E0412, E0433.
  For more information about an error, try `rustc --explain E0405`.
  error: could not compile `test-programs` (bin "p2_api_reactor") due to 5 previous errors

  thread 'main' (480942390) panicked at crates/test-programs/artifacts/build.rs:156:9:
  assertion failed: status.success()
  note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

With just the clocks-timezone feature:

  creating a component from "/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out/wasm32-wasip1/debug/p2_api_reactor.wasm"

  --- stderr
  running: env -u CARGO_ENCODED_RUSTFLAGS CARGO_TARGET_DIR="/Users/bhayes/repos/bytecodealliance/wasmtime/target/debug/build/test-programs-artifacts-eba4d8530bb0b1ec/out" RUSTFLAGS="" "cargo" "build" "--release" "--package=wasi-preview1-component-adapter" "--target=wasm32-unknown-unknown"
     Compiling wasi-preview1-co
[message truncated]

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:20):

ricochet updated PR #12250.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:26):

ricochet created PR review comment:

Thanks that deletes a line too :+1:

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 18:26):

ricochet submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jan 08 2026 at 19:00):

ricochet updated PR #12250.


Last updated: Jan 09 2026 at 13:15 UTC