Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nargo compile fails with "Error: The backend encountered an error" #2790

Closed
harshnambiar opened this issue Sep 22, 2023 · 9 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@harshnambiar
Copy link

Aim

The goal was to compile a smart contract but whether the command is called directly or is called implicitly during the execution of 'aztec-cli compile .', the error is always the same:

Error: The backend encountered an error

Location:
tooling/nargo_cli/src/cli/mod.rs:90:5

Expected Behavior

The contract should compile

Bug

The contract does not compile and the above mentioned error shows up.

To Reproduce

  1. mkdir sample
  2. cd sample
  3. nargo new --contract test
  4. cd test
  5. nargo compile

Installation Method

None

Nargo Version

nargo 0.11.1-aztec.0

Additional Context

I have tried to do the same with noirup -v aztec, but that did not work either.
I tried to uninstall nargo and then reinstall that, but to no avail.

Would you like to submit a PR for this Issue?

No

Support Needs

No response

@harshnambiar harshnambiar added the bug Something isn't working label Sep 22, 2023
@github-project-automation github-project-automation bot moved this to 📋 Backlog in Noir Sep 22, 2023
@harshnambiar
Copy link
Author

Additional Context for device:
OS: ubuntu 22.04

result for lshw -short
WARNING: you should run this program as super-user.
H/W path Device Class Description

                           system         Computer

/0 bus Motherboard
/0/0 memory 4GiB System memory
/0/1 processor Intel(R) Core(TM) i5-2410M CPU @ 2
/0/100 bridge 2nd Generation Core Processor Fami
/0/100/1 bridge Xeon E3-1200/2nd Generation Core P
/0/100/1/0 /dev/fb0 display Seymour [Radeon HD 6400M/7400M Ser
/0/100/1/0.1 card1 multimedia Caicos HDMI Audio [Radeon HD 6450
/0/100/1/0.1/0 input17 input HDA ATI HDMI HDMI/DP,pcm=3
/0/100/16 communication 6 Series/C200 Series Chipset Famil
/0/100/19 enp0s25 network 82579LM Gigabit Network Connection
/0/100/1a bus 6 Series/C200 Series Chipset Famil
/0/100/1b card0 multimedia 6 Series/C200 Series Chipset Famil
/0/100/1b/0 input18 input HDA Intel PCH Mic
/0/100/1b/1 input19 input HDA Intel PCH Line
/0/100/1b/2 input20 input HDA Intel PCH Dock Line Out
/0/100/1b/3 input21 input HDA Intel PCH Headphone
/0/100/1c bridge 6 Series/C200 Series Chipset Famil
/0/100/1c.1 bridge 6 Series/C200 Series Chipset Famil
/0/100/1c.2 bridge 6 Series/C200 Series Chipset Famil
/0/100/1c.2/0 bus IEEE 1394 Host Controller
/0/100/1c.2/0.1 mmc0 bus SD/MMC Host Controller
/0/100/1c.2/0.2 generic Standard SD Host Controller
/0/100/1c.3 bridge 6 Series/C200 Series Chipset Famil
/0/100/1c.3/0 wlp37s0b1 network BCM4313 802.11bgn Wireless Network
/0/100/1c.7 bridge 6 Series/C200 Series Chipset Famil
/0/100/1c.7/0 bus uPD720200 USB 3.0 Host Controller
/0/100/1d bus 6 Series/C200 Series Chipset Famil
/0/100/1f bridge QM67 Express Chipset LPC Controlle
/0/100/1f/0 system PnP device PNP0c02
/0/100/1f/1 generic PnP device IFX0102
/0/100/1f/2 system PnP device PNP0c02
/0/100/1f/3 system PnP device PNP0b00
/0/100/1f/4 printer PnP device PNP0401
/0/100/1f/5 input PnP device PNP0303
/0/100/1f/6 generic PnP device SYN017b
/0/100/1f.2 scsi1 storage 6 Series/C200 Series Chipset Famil
/0/100/1f.2/0.0.0 /dev/cdrom disk DVDRAM GT80N
/1 input0 input Sleep Button
/2 input1 input Lid Switch
/3 input12 input SynPS/2 Synaptics TouchPad
/4 input14 input SIGMACHIP Usb Mouse
/5 input15 input ST LIS3LV02DL Accelerometer
/6 input16 input HP WMI hotkeys
/7 input2 input Power Button
/8 input22 input HP HD Webcam [Fixed]: HP HD Web
/9 input3 input AT Translated Set 2 keyboard
/a input8 input PS/2 Generic Mouse
/b input9 input Video Bus
WARNING: output may be incomplete or inaccurate, you should run this program as super-user.

@TomAFrench
Copy link
Member

Can you try running nargo backend uninstall acvm-backend-barretenberg and trying what you're doing again?

@harshnambiar
Copy link
Author

Can you try running nargo backend uninstall acvm-backend-barretenberg and trying what you're doing again?

I did presently. No changes. The entire error message is: "backend encountered an error"

@TomAFrench
Copy link
Member

TomAFrench commented Sep 26, 2023

Running on nightly should provide more information when this error occurs. This assumes you get similar errors when writing standard Noir programs (as nightly won't compile Aztec contracts).

@harshnambiar
Copy link
Author

harshnambiar commented Sep 26, 2023

Running on nightly should provide more information when this error occurs.

so i just do a noirup -n and retry? (Yes, the issue does replicate while doing a nargo prove and a nargo compile as well)

@TomAFrench
Copy link
Member

Yes, that's correct.

@harshnambiar
Copy link
Author

Yes, that's correct.

After doing that and running nargo prove, the error is:
The backend encountered an error: ""

@TomAFrench
Copy link
Member

@harshnambiar can you try with the latest nightly and see if this issue is resolved for you?

@Savio-Sou
Copy link
Collaborator

Closing this as stale for now. Feel free to comment / reopen if the issue is experienced with newer versions of Nargo.

@Savio-Sou Savio-Sou closed this as not planned Won't fix, can't repro, duplicate, stale Oct 31, 2023
@github-project-automation github-project-automation bot moved this from 📋 Backlog to ✅ Done in Noir Oct 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

3 participants