zkopru-network / zkopru

Ethereum L2 scaling solution for private transactions using zk-SNARK and optimistic rollup.
https://zkopru.network
GNU General Public License v3.0
216 stars 28 forks source link

Circuits docker image not compiling #181

Closed chancehudson closed 3 years ago

chancehudson commented 3 years ago

The Circuits.light.dockerfile is failing to compile the circuits image. The Circuits.dockerfile is also failing with the same error below.

Step 14/17 : RUN /bin/bash /proj/script/compile_circuits.sh
 ---> Running in f19f67878fe4
Circuit compile result: zk_transaction_1_1
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 18570
[INFO]  snarkJS: # of Constraints: 18522
[INFO]  snarkJS: # of Private Inputs: 66
[INFO]  snarkJS: # of Public Inputs: 12
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_1_2
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 19670
[INFO]  snarkJS: # of Constraints: 19620
[INFO]  snarkJS: # of Private Inputs: 72
[INFO]  snarkJS: # of Public Inputs: 20
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_1_3
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 20776
[INFO]  snarkJS: # of Constraints: 20724
[INFO]  snarkJS: # of Private Inputs: 78
[INFO]  snarkJS: # of Public Inputs: 28
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_1_4
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 21888
[INFO]  snarkJS: # of Constraints: 21834
[INFO]  snarkJS: # of Private Inputs: 84
[INFO]  snarkJS: # of Public Inputs: 36
[INFO]  snarkJS: # of Outputs: 0
/proj/script/compile_circuits.sh: line 9:   383 Killed                  node --stack-size=8192 $(which circom) "$circuit" -r "$prefix.r1cs"
/proj/script/compile_circuits.sh: line 19:   331 Killed                  node --stack-size=8192 $(which circom) "$circuit" -c "$prefix.c"
/proj/script/compile_circuits.sh: line 9:   472 Killed                  node --stack-size=8192 $(which circom) "$circuit" -r "$prefix.r1cs"
/proj/script/compile_circuits.sh: line 9:   601 Killed                  node --stack-size=8192 $(which circom) "$circuit" -r "$prefix.r1cs"
/proj/script/compile_circuits.sh: line 9:   481 Killed                  node --stack-size=8192 $(which circom) "$circuit" -r "$prefix.r1cs"
Circuit compile result: zk_transaction_2_1
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 36075
[INFO]  snarkJS: # of Constraints: 35983
[INFO]  snarkJS: # of Private Inputs: 126
[INFO]  snarkJS: # of Public Inputs: 14
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_2_2
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 37201
[INFO]  snarkJS: # of Constraints: 37107
[INFO]  snarkJS: # of Private Inputs: 132
[INFO]  snarkJS: # of Public Inputs: 22
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_2_3
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 38333
[INFO]  snarkJS: # of Constraints: 38237
[INFO]  snarkJS: # of Private Inputs: 138
[INFO]  snarkJS: # of Public Inputs: 30
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_2_4
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 39471
[INFO]  snarkJS: # of Constraints: 39373
[INFO]  snarkJS: # of Private Inputs: 144
[INFO]  snarkJS: # of Public Inputs: 38
[INFO]  snarkJS: # of Outputs: 0
/proj/script/compile_circuits.sh: line 19:   280 Killed                  node --stack-size=8192 $(which circom) "$circuit" -c "$prefix.c"
/proj/script/compile_circuits.sh: line 19:   361 Killed                  node --stack-size=8192 $(which circom) "$circuit" -c "$prefix.c"
/proj/script/compile_circuits.sh: line 19:   451 Killed                  node --stack-size=8192 $(which circom) "$circuit" -c "$prefix.c"
/proj/script/compile_circuits.sh: line 19:   452 Killed                  node --stack-size=8192 $(which circom) "$circuit" -w "$prefix.wasm"
/proj/script/compile_circuits.sh: line 19:   483 Killed                  node --stack-size=8192 $(which circom) "$circuit" -c "$prefix.c"
/proj/script/compile_circuits.sh: line 19:   484 Killed                  node --stack-size=8192 $(which circom) "$circuit" -w "$prefix.wasm"
/proj/script/compile_circuits.sh: line 19:   485 Killed                  node --stack-size=8192 $(which circom) "$circuit" -s "$prefix.sym"
Circuit compile result: zk_transaction_3_1
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 53586
[INFO]  snarkJS: # of Constraints: 53450
[INFO]  snarkJS: # of Private Inputs: 186
[INFO]  snarkJS: # of Public Inputs: 16
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_3_2
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 54738
[INFO]  snarkJS: # of Constraints: 54600
[INFO]  snarkJS: # of Private Inputs: 192
[INFO]  snarkJS: # of Public Inputs: 24
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_4_3
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 73465
[INFO]  snarkJS: # of Constraints: 73281
[INFO]  snarkJS: # of Private Inputs: 258
[INFO]  snarkJS: # of Public Inputs: 34
[INFO]  snarkJS: # of Outputs: 0
Circuit compile result: zk_transaction_4_1
[INFO]  snarkJS: Curve: bn-128
[INFO]  snarkJS: # of Wires: 71103
[INFO]  snarkJS: # of Constraints: 70923
[INFO]  snarkJS: # of Private Inputs: 246
[INFO]  snarkJS: # of Public Inputs: 18
[INFO]  snarkJS: # of Outputs: 0
[ERROR] snarkJS: [Error: ENOENT: no such file or directory, open 'build/circuits/zk_transaction_3_3.r1cs'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: 'build/circuits/zk_transaction_3_3.r1cs'
}
[ERROR] snarkJS: [Error: ENOENT: no such file or directory, open 'build/circuits/zk_transaction_3_4.r1cs'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: 'build/circuits/zk_transaction_3_4.r1cs'
}
[ERROR] snarkJS: [Error: ENOENT: no such file or directory, open 'build/circuits/zk_transaction_4_2.r1cs'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: 'build/circuits/zk_transaction_4_2.r1cs'
}
[ERROR] snarkJS: [Error: ENOENT: no such file or directory, open 'build/circuits/zk_transaction_4_4.r1cs'] {
  errno: -2,
  code: 'ENOENT',
  syscall: 'open',
  path: 'build/circuits/zk_transaction_4_4.r1cs'
}
ERROR: Service 'circuits' failed to build: The command '/bin/sh -c /bin/bash /proj/script/compile_circuits.sh' returned a non-zero code: 1
chancehudson commented 3 years ago

This turned out to be processes getting killed in the container. Not sure if something changed or if I'm using a smaller server for compiling. Closing for now.