CLI options
This reference describes the command-line interface of the native zesu binary.
You can install the native binary and build it from
source to:
- Debug a failing block.
- Validate a zkVM integration's commitment against a known-correct value.
Zesu's standalone debug mode is being refactored. The options and behavior on this page may change.
Specify options
You can specify Zesu options on the command line:
zesu [OPTIONS]
The binary reads one environment variable, ZESU_INPUT,
which controls where it reads input bytes from when no input flag is provided.
Options
fork
- Syntax
- Example
--fork <NAME>
--fork Prague
Overrides the fork name declared in the input's
chain_config.
ssz
- Syntax
- Example
--ssz [<FILE>]
--ssz ./block.bin
Reads SSZ-encoded input from a binary file.
If supplied without an argument, Zesu falls back to standard input or
ZESU_INPUT.
json
- Syntax
- Example
--json <BLOCK_FILE> <WITNESS_FILE>
--json ./block.json ./witness.json
Reads input from two JSON files, one containing the block and one containing the witness. Both arguments are required.
The binary accepts two formats for each file:
| File | Accepted formats |
|---|---|
| Block file | {"result":"0x<rlp>"} (raw debug_getRawBlock response) or {"block":"0x<rlp>"} |
| Witness file | {"state":[...],"codes":[...],"keys":[...],"headers":[...]} (direct) or {"jsonrpc":"2.0","result":{...}} |
Environment variables
ZESU_INPUT
- Syntax
- Example
ZESU_INPUT=<FILE>
ZESU_INPUT=./block.bin zesu
Path to a file containing SSZ-encoded input bytes.
Used only when no --ssz or --json flag is present on the
command line.
If ZESU_INPUT is not set, Zesu reads from standard input.
Output streams
Zesu writes its public output (the 105-byte SSZ commitment, or the JSON summary
for --json input) to standard output.
Diagnostic messages go to standard error.
See Inputs and outputs for the output
format.
Exit codes
| Code | Meaning |
|---|---|
0 | Block executed successfully and the post-state root and receipts root match the expected values. |
1 | Argument parsing failed, the input could not be loaded, execution returned an error, or the resulting state root or receipts root did not match the expected values. |