Skip to content

fix(nix): select wasm-bindgen CLI from Cargo.lock - #6031

Merged
kixelated merged 6 commits into
mainfrom
quest/m0/ci/wasm-bindgen-pin
Oct 20, 2026
Merged

kixelated merged 6 commits into
mainfrom
quest/m0/ci/wasm-bindgen-pin

Conversation

@kixelated

@kixelated kixelated commented Oct 20, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

A nixpkgs update can change the default wasm-bindgen CLI independently of the locked crate, breaking their required schema match.

Approach

Read the locked wasm-bindgen version and select nixpkgs' versioned CLI. Refuse unsupported, missing, or ambiguous lock entries during Nix evaluation. Update the matching comments and complete the quest.

Decisions

  • Which pin selects the CLI version: ✅ Cargo.lock (maintainer, 2026-10-19). Rejected: a CI step comparing the two versions (detects drift instead of removing it), and making Dependabot's auto-merge wait for WASM.

Impact

  • Public API and wire: none. No crate versions or flake pins change.

Validation

  • Reproduced the drift: locking 0.2.128 previously still selected CLI 0.2.129.
  • Real shell evaluation now selects 0.2.128 and 0.2.129 from the corresponding temporary lock entries; unsupported 0.2.999 fails with the locked version in its error. All probes restored Cargo.lock.
  • The executable reports wasm-bindgen 0.2.129, matching the actual lock.
  • Merged origin/main (conflict only in quest/m0/ci/README.md's Required list); scoped just check passes again in the pinned Nix shell after the merge.

Alternatives

A separate version-comparison CI step detects drift after it occurs. Selecting the matching CLI removes it, following the maintainer's decided quest plan.

Follow-ups

None identified.

🤖 Generated with Claude Code

(Written by Claude Opus 5.5)

kixelated and others added 2 commits October 19, 2026 19:02
Co-Authored-By: GPT-6.1-Sol <noreply@openai.com>
Co-Authored-By: GPT-6.1-Sol <noreply@openai.com>
@kixelated

Copy link
Copy Markdown
Collaborator Author

Completed the decided quest plan at fe4dfd2. Cargo.lock selects the matching versioned Nix CLI and unsupported versions fail during evaluation. The temporary-version probes, actual CLI version, WASM build/binding generation, and full scoped just check all pass. Public API, wire format, crate versions, and flake pins are unchanged.

No open decisions or follow-up quests identified. Keep this draft under the user's no-merge hold; /quest-ready is the recommended next action after that hold is lifted.

(written by GPT-6.1-Sol)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated
kixelated marked this pull request as ready for review October 20, 2026 04:55
@coderabbitai

coderabbitai Bot commented Oct 20, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 4d3af68a-d21a-4550-bd79-5a173c63f8f9
📥 Commits

Reviewing files that changed from the base of the PR and between 34a01e7 and ed72c43.

📒 Files selected for processing: 5
  • flake.nix
  • quest/m0/ci/README.md
  • quest/m0/ci/wasm-bindgen-pin.md
  • quest/m1/audit-test-cost.md
  • rs/moq-wasm/Cargo.toml
💤 Files with no reviewable changes: 2
  • quest/m0/ci/README.md
  • quest/m0/ci/wasm-bindgen-pin.md

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 0 remain after this review.

Walkthrough

The Nix development environment now selects the wasm-bindgen-cli version from the unique wasm-bindgen entry in Cargo.lock. Evaluation fails if the entry is missing or duplicated, or if nixpkgs does not provide the matching CLI package. Related comments and audit notes now describe this selection. The CI checklist item and pinning document have been removed.

Priority: ⬇️ Low

Merge Risk: ⚪ Minimal · up to ed72c

No actionable merge-blocking risk remains in the reviewed change.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly and concisely describes the main change: selecting the wasm-bindgen CLI version from Cargo.lock in Nix.
Description check Passed The description directly explains the version-drift problem, the Cargo.lock-based solution, validation results, and the absence of public API or wire-format changes.
Docstring Coverage Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0 files. (3 skipped: 3 unsupported.)

✨ Finishing Touches
✨ Simplify code
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-20T15:54:23.049399Z ed72c43 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kixelated
kixelated added this pull request to the merge queue Oct 20, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Oct 20, 2026

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ed72c438ad

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread flake.nix
(pkgs.lib.findSingle (package: package.name == "wasm-bindgen")
(throw "Cargo.lock has no wasm-bindgen package")
(throw "Cargo.lock has multiple wasm-bindgen versions")
(builtins.fromTOML (builtins.readFile ./Cargo.lock)).package

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep the benchmark lockfile in step with the selected CLI

When the root Cargo.lock advances to another wasm-bindgen version, this switches the shell's global CLI while bench/ffi-gen/Cargo.lock remains independently pinned. bench/ffi-gen/run.sh builds its UniFFI WASM artifact with that second lockfile and then invokes the global wasm-bindgen, so the next root-only bump will make the benchmark fail with the same schema mismatch this change is intended to prevent. Either derive that build from the root lock too or add an explicit synchronization guard for the nested lockfile.

Useful? React with 👍 / 👎.

@kixelated
kixelated added this pull request to the merge queue Oct 20, 2026
Merged via the queue into main with commit 42c179f Oct 20, 2026
4 checks passed
@kixelated
kixelated deleted the quest/m0/ci/wasm-bindgen-pin branch October 20, 2026 16:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant