Skip to content

Commit

Permalink
Comments; inline variable.
Browse files Browse the repository at this point in the history
  • Loading branch information
akonior committed Jun 10, 2024
1 parent 8ed5191 commit 79db2cb
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/circuits_e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
nargo compile --package is_dao_worthy --deny-warnings
nargo compile --package is_ape_owner --deny-warnings
# We cannot use the `--deny-warnings` option in `is_dao_worthy_recursive` because the `verify_proof` method generates warning
# We cannot use the `--deny-warnings` option in `is_dao_worthy_recursive` because the `verify_proof` method generates warnings
# that are actually informational messages from the compiler and cannot be ignored.
nargo compile --package is_dao_worthy_recursive
Expand All @@ -70,8 +70,8 @@ jobs:
- name: Generate verification key for recursive proof
working-directory: ethereum/oracles
run: |
# To generate the verification key, the following file is required: ~/.nargo/backends/acvm-backend-barretenberg/backend_binary.
# This file is automatically installed during the execution of the `nargo prove` command in previous step.
# Verification key generation uses Barretenberg backend located at ~/.nargo/backends/acvm-backend-barretenberg/backend_binary.
# It is automatically installed during the execution of the `nargo prove` command in previous step.
yarn generate-get-storage-vk
- name: Generate Recursive Proof
Expand Down
3 changes: 1 addition & 2 deletions ethereum/circuits/lib/src/account_with_storage_recursive.nr
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,11 @@ pub fn get_account_with_storage_recursive(
public_inputs.extend_back(address.serialize());
public_inputs.extend_back(storage_key.serialize());
public_inputs.extend_back(storage_within_block.serialize());
let public_inputs_array: [Field; NUM_PUBLIC_INPUTS] = public_inputs.to_array();

verify_proof(
verification_key.as_slice(),
proof.as_slice(),
public_inputs_array.as_slice(),
public_inputs.to_array::<NUM_PUBLIC_INPUTS>().as_slice(),
key_hash
);

Expand Down
3 changes: 1 addition & 2 deletions vlayer/examples/circuits/is_dao_worthy_recursive/src/main.nr
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ global MIN_BALANCE = U128::from_integer(100_000_000_000); // $100k

fn main(wallet_address: Address, block_number: pub u64) {
let wallet_balance = USDC.get_balance(wallet_address, block_number, true);
let is_balance_greater_or_equal = MIN_BALANCE <= wallet_balance;

assert(is_balance_greater_or_equal, "Insufficient USDC balance");
assert(MIN_BALANCE <= wallet_balance, "Insufficient USDC balance");
}

0 comments on commit 79db2cb

Please sign in to comment.