Zecale - Reconciling Privacy and Scalability on Smart-Contract Chains  0.5
Reference implementation of the Zecale protocol by Clearmatics
Functions | Variables
zecale.cli.zecale_check_batch Namespace Reference

Functions

None check_batch (Context ctx, str batch_file, int batch_size)
 

Variables

 type
 
 required
 
 help
 

Function Documentation

◆ check_batch()

None zecale.cli.zecale_check_batch.check_batch ( Context  ctx,
str  batch_file,
int  batch_size 
)
Exit with error if result is not 1 for any nested proof

Definition at line 18 of file zecale_check_batch.py.

18 def check_batch(ctx: Context, batch_file: str, batch_size: int) -> None:
19  """
20  Exit with error if result is not 1 for any nested proof
21  """
22  cmd_ctx: CommandContext = ctx.obj
23  aggregated_tx = load_aggregated_transaction(
24  cmd_ctx.get_wrapper_snark(), batch_file)
25  inputs = aggregated_tx.ext_proof.inputs
26  results = int(inputs[1], 16)
27  print(f"results={hex(results)}")
28 
29  expect_results = (1 << batch_size) - 1
30  if expect_results != results:
31  raise ClickException("at least one nested proof judged as invalid")
Here is the call graph for this function:

Variable Documentation

◆ help

zecale.cli.zecale_check_batch.help

Definition at line 16 of file zecale_check_batch.py.

◆ required

zecale.cli.zecale_check_batch.required

Definition at line 15 of file zecale_check_batch.py.

◆ type

zecale.cli.zecale_check_batch.type

Definition at line 14 of file zecale_check_batch.py.

zecale.cli.zecale_check_batch.check_batch
None check_batch(Context ctx, str batch_file, int batch_size)
Definition: zecale_check_batch.py:18
zecale.cli.utils.load_aggregated_transaction
AggregatedTransaction load_aggregated_transaction(IZKSnarkProvider zksnark, str agg_tx_file)
Definition: utils.py:29
zecale.dummy_app.get.int
int
Definition: get.py:20