fix: restrict wasm-bindgen to browser wasm, fixing wasip1 builds#7208
Merged
fix: restrict wasm-bindgen to browser wasm, fixing wasip1 builds#7208
Conversation
wasm-bindgen 0.2.115 changed its cfg guard from `cfg(all(target_arch = "wasm32", target_os = "unknown"))` to `cfg(target_family = "wasm")`, causing `__wbindgen_*` imports to be emitted for all wasm targets including wasm32-wasip1. Combined with wasm-test/Cargo.lock being untracked (deleted in #6187), CI picked up the new version and the wasmer integration test broke. Narrow the `wasm-bindgen-futures` dependency and the wasm runtime module in vortex-io from `cfg(target_arch = "wasm32")` to `cfg(all(target_arch = "wasm32", target_os = "unknown"))`, which matches only wasm32-unknown-unknown (browser) and excludes WASI targets. For the fuzz crate's wasip1 target, provide a session without an async runtime handle since the fuzz workloads are synchronous. Signed-off-by: lx <lx@lx.com> Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> Signed-off-by: Alexander Droste <alexander.droste@protonmail.com>
AdamGS
approved these changes
Mar 30, 2026
Contributor
|
🚢 |
Merging this PR will degrade performance by 15.51%
Performance Changes
Comparing Footnotes
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
wasm-bindgen 0.2.115 changed its cfg guard from
cfg(all(target_arch = "wasm32", target_os = "unknown"))tocfg(target_family = "wasm"), causing__wbindgen_*imports to be emitted for all wasm targets including wasm32-wasip1. Combined with wasm-test/Cargo.lock being untracked (deleted in #6187), CI picked up the new version and the wasmer integration test broke.Narrow the
wasm-bindgen-futuresdependency and the wasm runtime module in vortex-io fromcfg(target_arch = "wasm32")tocfg(all(target_arch = "wasm32", target_os = "unknown")), which matches only wasm32-unknown-unknown (browser) and excludes WASI targets. For the fuzz crate's wasip1 target, provide a session without an async runtime handle since the fuzz workloads are synchronous.