Skip to content

Libraries of zkmail.nr aren't updated with the latest breaking changes of the v0.36.0 compiler #21

@NikolayKostadinov21

Description

@NikolayKostadinov21

Issue Description

Compiling a Nargo program with the latest compiler version (v0.36.0) results in 8 errors when using zkmail.nr as a dependency (version v0.3.2). However, reverting to compiler version v0.35.0 allows the code to compile without issues.

Project Context

Project Name: ZeKshop

Challenge: ZKEmail Guardian

GitHub Repository: https://github.com/NikolayKostadinov21/ZeKshop

Environment

Aztec Version: 0.55.1 - Has no effect.

Noir Version (if applicable): nargo version = 0.36.0
noirc version = 0.36.0+3299c25cefb6e3eb4b55396b2f842138b658e42f
(git version hash: 3299c25cefb6e3eb4b55396b2f842138b658e42f, is dirty: false)

Operating System: Ubuntu 24

Steps to Reproduce

  1. Create new nargo project with nargo new dummy_project
  2. Add zkmail.nr as a dependency
  3. Run nargo compile

Expected Behavior

The code compiles

Actual Behavior

The compiler detected 8 errors.

Error Messages

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:179:9
    │
179 │         most_significant_byte.assert_max_bit_size(max_bits_in_most_significant_byte as u32);
    │         -----------------------------------------------------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:229:13
    │
229 │             self.limbs[i].assert_max_bit_size(120);
    │             --------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:232:9
    │
232 │         self.limbs[N - 1].assert_max_bit_size(final_limb_bits as u32);
    │         -------------------------------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:250:13
    │
250 │             self.limbs[i].assert_max_bit_size(120);
    │             --------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:254:9
    │
254 │         self.limbs[N - 1].assert_max_bit_size(final_limb_bits as u32);
    │         -------------------------------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:498:9
    │
498 │         borrow_flags[0].assert_max_bit_size(1);
    │         --------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:501:13
    │
501 │             borrow_flags[i].assert_max_bit_size(1);
    │             --------------------------------------
    │

error: Function expects 1 parameter but 2 were given
    ┌─ /home/anon/nargo/github.com/noir-lang/noir-bignumv0.3.5/src/runtime_bignum.nr:523:13
    │
523 │             product_limbs[i].assert_max_bit_size(126); // N.B. is this sufficient? going beyond 126 costs us 1 gate per limb
    │             -----------------------------------------
    │

Aborting due to 8 previous errors

Possible Solution

Update the libraries that require an update to be compatible with the newest version of Noir

Impact on Development

Minor

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions