Skip to content

fix(aztec-nr): replace deprecated BoundedVec::from_parts_unchecked with from_parts#23686

Closed
AztecBot wants to merge 1 commit into
merge-train/spartanfrom
cb/fix-aztec-nr-from-parts-unchecked
Closed

fix(aztec-nr): replace deprecated BoundedVec::from_parts_unchecked with from_parts#23686
AztecBot wants to merge 1 commit into
merge-train/spartanfrom
cb/fix-aztec-nr-from-parts-unchecked

Conversation

@AztecBot

Copy link
Copy Markdown
Collaborator

Problem

CI on merge-train/spartan is failing in the aztec-nr step (log, sub-log c145c929c2fbaaeb):

error: `BoundedVec::from_parts` no longer requires an extra loop, `BoundedVec::from_parts_unchecked` is no longer required
   ┌─ aztec/src/note/note_getter.nr:263:17
   ┌─ aztec/src/utils/array/subbvec.nr:26:17
Aborting due to 2 previous errors

The recent noir submodule sync (#23683) deprecated BoundedVec::from_parts_unchecked. from_parts no longer zeroes elements past len in an extra loop, so the two functions are now behaviorally identical and from_parts_unchecked is marked #[deprecated]. The aztec-nr library is checked with nargo check --deny-warnings, so the deprecation warning fails the build.

Fix

Replaced every non-generated BoundedVec::from_parts_unchecked call site with BoundedVec::from_parts:

  • 2 sites in aztec-nr (note_getter.nr, subbvec.nr) — these are what broke CI. Removed the now-obsolete comments explaining why the _unchecked variant was safe.
  • 9 noir-protocol-circuits files (test helpers + one uniqueness-hint builder) — these only emit warnings today (those crates use plain check), migrated to clear the noise and complete the noir-sync follow-on.

The replacement is a pure behavioral no-op given the new stdlib definition (from_parts = assert(len <= MaxLen); BoundedVec { storage, len }).

Verification

Built nargo at the synced submodule commit (1.0.0-beta.21+4d0392685) and ran the same checks CI runs:

  • nargo check --deny-warnings in noir-projects/aztec-nr → exit 0, no warnings (previously aborted with 2 errors).
  • nargo check on private-kernel-lib, types, rollup-lib, blob → all exit 0.

The second failure in the run (bb-cpp-fuzzing) was a transient network flake — Could not resolve host: github.com while fetching msgpack-c — unrelated to this change.


Created by claudebox · group: slackbot

@AztecBot AztecBot added the claudebox Owned by claudebox. it can push to this PR. label May 29, 2026
@AztecBot

AztecBot commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator Author

Automatically closing this stale claudebox draft PR (no updates for 5+ days). Re-open if still needed.

@AztecBot AztecBot closed this Jun 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claudebox Owned by claudebox. it can push to this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant