Pin wasm-bindgen test crate to an exact version - #27678
Merged
Merged
Conversation
A bare "0.2.N" requirement is a caret range, so cargo resolves any newer 0.2.x patch release, which then mismatches the wasm-bindgen-cli on PATH.
sbc100
approved these changes
Sep 5, 2026
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.
The wasm-bindgen tests pin the crate to the CLI version installed in CI, but
cargo add wasm-bindgen@0.2.Nwriteswasm-bindgen = "0.2.N", which cargo treats as the caret range^0.2.N. As soon as a newer 0.2.x patch is published, cargo resolves to it while the CLI on PATH stays at the older version, and wasm-bindgen rejects the crate/CLI mismatch at link time. This broke CI when 0.2.128 was released while the CLI was still at 0.2.127.=0.2.128) in thecargo addcalls intest_other.pytest/rust/bindgen_greeter/Cargo.tomlVerified that
cargo add wasm-bindgen@0.2.127locks to 0.2.128 whilecargo add wasm-bindgen@=0.2.127locks to 0.2.127, so future releases no longer affect the pinned tests.other.test_wasm_bindgen_*pass locally.Made with AI assistance under my review