AztecProtocol / ab2

Alpha Build 2 project repository.
3 stars 27 forks source link

Aztec Nargo Compile Crashing #18

Open Envoy-VC opened 1 month ago

Envoy-VC commented 1 month ago

Issue Description

when I run aztec-nargo compile, it crashes after running for ~5mins, I have multiple crates in my workspace it only crashes for a specific crate where I am performing a zkemail verification and string search on a large body (14k length).

The Docker instance doesn't show any logs when compiling.

It may be time limit of resource limit because docker is accessing only one core of CPU. When i try to remove some lines of code like body hash check it is compiling after ~5m, so maybe this is some timeout problem.

Project Context

Project Name: Aztec Passport

Challenge: ZKEmail Guardian

GitHub Repository:

Environment

Aztec Version: 0.57.0

Noir Version (if applicable):

nargo version = 0.35.0
noirc version = 0.35.0+2a0d211b92d002fa75855d4ba27267f8892dd52c
(git version hash: 2a0d211b92d002fa75855d4ba27267f8892dd52c, is dirty: false)

Operating System: MacOS 15.0.1 (24A348)

Expected Behavior

Contract should compile successfully.

Actual Behavior

Compilation Crashes

Code Snippet

// If applicable, add a minimal code snippet that demonstrates the issue

Error Messages

No Logs in docker Image

NikolayKostadinov21 commented 1 month ago

Could you provide more information about the smart contracts and their dependencies that you’re trying to compile with aztec-nargo compile? A code snippet would be helpful, or even better, a link to the repository so I can run them on my Ubuntu 24 setup. The issue could be due to a variety of factors. it could be even related to the fact that you are using MacOS. Didn't see any commits to your ab2 fork, so that's why I am asking.

Envoy-VC commented 1 month ago

Hey @NikolayKostadinov21 I have pushed my code, this is the module where compile is crashing

https://github.com/Envoy-VC/ab2/tree/aztec-passport/Aztec-Passport/packages/l2-contracts/crates/modules/x_module

To reproduce uncomment lines on

https://github.com/Envoy-VC/ab2/blob/aztec-passport/Aztec-Passport/packages/l2-contracts/crates/modules/x_module/src/x.nr#L74

0xrafi commented 3 weeks ago

have you tried this after updating to the latest version of the sandbox?

Envoy-VC commented 2 weeks ago

Hey @0xrafi I tried the 0.62.0 version of sandbox but some packages needed for compilation such as noir_string_search and zkemailnr throw errors while compilation.