Skip to content
Merged

v0.15.3 #1940

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
2e8796f
feat(agg-mode): support risc0 stark proofs (#1874)
MarcosNicolau Apr 24, 2025
42c7549
infra(aggregation_mode): add setup files (#1866)
JuArce Apr 24, 2025
83576e3
feat: proof aggregator upgrade scripts (#1888)
MarcosNicolau Apr 25, 2025
3ef2976
feat: deploy risc0 groth16 verifier contracts in anvil (#1876)
MarcosNicolau Apr 28, 2025
5d78e56
refactor(agg-mode): reduce types, abstractions and double merkle root…
MarcosNicolau Apr 28, 2025
d5235ed
feat(explorer): show aggregation mode componentes on testnet only (#1…
MarcosNicolau Apr 28, 2025
0656d2b
Pull fixes from testnet (#1903)
MauroToscano Apr 28, 2025
a132bf0
fix(aggregation_mode): invert variables order and add setter for risc…
JuArce Apr 29, 2025
d9e91f6
Merge
MauroToscano Apr 29, 2025
b31292e
feat: risc0 for sdk and cli (#1886)
MarcosNicolau Apr 29, 2025
99b447d
fix(aggregation_mode): add testnet contract address to SDK (#1909)
JuArce Apr 30, 2025
d2c297b
infra(alerts): add alerts for aggregation mode (#1906)
JuArce May 6, 2025
c4b5f75
feat: explorer show aggregtor (risc0, sp1) on aggregation mode views …
MarcosNicolau May 6, 2025
83b1750
feat(aggregation_mode): use deterministic build for SP1 (#1916)
JuArce May 6, 2025
c8ace7b
fix: explorer aggregated proofs pagination (#1899)
MarcosNicolau May 6, 2025
d003201
infra(aggregation_mode): add Risc0 setup (#1898)
JuArce May 6, 2025
252cb52
fix(aggregation_mode): reset `proof-aggregator.last_aggregated_block.…
JuArce May 6, 2025
2ff8262
feat(aggregation_mode): use deterministic build for Risc0 (#1918)
JuArce May 6, 2025
c10d89b
fix(explorer): show unknown if no aggregator set in aggregated proof …
JuArce May 7, 2025
3b38eb5
script to send proofs with random addresses (#1865)
Mechanix97 May 7, 2025
0a6419f
fix(aggregation-mode): hardcode image_id and vk_hash from solidity co…
MarcosNicolau May 8, 2025
0eab47e
refactor(aggregation_mode): migrate merkle tree to lambdaworks (#1911)
MarcosNicolau May 8, 2025
fbc0b96
fix(aggregation_mode: update `vk hash` and `image id` (#1927)
JuArce May 9, 2025
9fcdd63
fix(explorer): update aggregation mode functions (#1929)
JuArce May 12, 2025
5607821
Add missing functions and events (#1930)
MauroToscano May 12, 2025
68089e0
docs: add missing proof aggregator address (#1933)
MarcosNicolau May 14, 2025
57d3209
fix: update eigenlayer contracts for devnet (#1932)
JuArce May 14, 2025
1eac88a
fix(explorer): redesign aggregator badges design (#1935)
MarcosNicolau May 14, 2025
f8db023
feat(batcher): add queue limit (#1875)
Mechanix97 May 15, 2025
10f3048
fix(CI): set rust version to 1.86.0 (#1939)
JuArce May 15, 2025
a90fd3a
fix(ethereum_package): fix localnet/devnet on Ethereum package (#1937)
JuArce May 15, 2025
adc5793
fix(aggregation_mode): merkle-tree backend openzeppelin compliant (#1…
MarcosNicolau May 15, 2025
c01526e
Refactor sdk modules (#1941)
MauroToscano May 16, 2025
124eba8
feat(aggregation_mode): verify aggregated proof on chain (#1915)
MarcosNicolau May 20, 2025
deecb46
Pull from testnet to staging (#1952)
MauroToscano May 27, 2025
12e0642
feat(examples): full example and docs for aggregation mode (#1942)
MarcosNicolau May 29, 2025
b39a038
feat(aggregation_mode): aggregate proofs in chunks (#1896)
MarcosNicolau May 29, 2025
703f766
feat(aggregation-mode): limit number of proofs to fetch (#1956)
MarcosNicolau Jun 3, 2025
c94d77c
fix(batcher): non paying proofs are ignored when queue is full (#1958)
JuArce Jun 3, 2025
52d5c8c
docs: update to v0.15.3 (#1954)
JuArce Jun 3, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 16 additions & 3 deletions .github/workflows/build-and-test-rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
paths:
- "batcher/**"
- "aggregation_mode/**"
- ".github/workflows/build-rust.yml"
- ".github/workflows/build-and-test-rust.yml"

jobs:
build:
Expand All @@ -20,7 +20,7 @@ jobs:
- name: Set up Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.86.0
components: rustfmt, clippy
override: true

Expand All @@ -31,6 +31,12 @@ jobs:
source /home/runner/.bashrc
~/.sp1/bin/sp1up

- name: Install risc0 toolchain
run: |
curl -L https://risczero.com/install | bash
source ~/.bashrc
~/.risc0/bin/rzup install

- name: Cache Rust dependencies
uses: actions/cache@v3
with:
Expand Down Expand Up @@ -70,7 +76,8 @@ jobs:
- name: Run Clippy on AggregationMode
run: |
cd aggregation_mode
cargo clippy --all -- -D warnings
# We need to skip the build as clippy does not support the riscv32im-risc0-zkvm-elf target
RISC0_SKIP_BUILD=1 cargo clippy --all -- -D warnings

test:
runs-on: aligned-runner
Expand All @@ -89,6 +96,12 @@ jobs:
source /home/runner/.bashrc
~/.sp1/bin/sp1up

- name: Install risc0 toolchain
run: |
curl -L https://risczero.com/install | bash
source ~/.bashrc
~/.risc0/bin/rzup install

- name: Cache Rust dependencies
uses: actions/cache@v3
with:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,6 @@ nonce_*.bin

infra/ansible/playbooks/ini/**.ini
infra/ansible/playbooks/files/**.pem

examples/l2/crates/l2/db
examples/l2/crates/l2/zkvm_programs/sp1/elf/sp1_state_transition_program
9 changes: 9 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,12 @@
[submodule "contracts/lib/sp1-contracts"]
path = contracts/lib/sp1-contracts
url = https://github.com/succinctlabs/sp1-contracts
[submodule "contracts/lib/risc0-ethereum"]
path = contracts/lib/risc0-ethereum
url = https://github.com/risc0/risc0-ethereum
[submodule "contracts/eigenlayer_contracts/eigenlayer-contracts"]
path = contracts/eigenlayer_contracts/eigenlayer-contracts
url = https://github.com/Layr-Labs/eigenlayer-contracts.git
[submodule "examples/l2/contracts/lib/forge-std"]
path = examples/l2/contracts/lib/forge-std
url = https://github.com/foundry-rs/forge-std
95 changes: 82 additions & 13 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ CONFIG_FILE?=config-files/config.yaml
export OPERATOR_ADDRESS ?= $(shell yq -r '.operator.address' $(CONFIG_FILE))
AGG_CONFIG_FILE?=config-files/config-aggregator.yaml

OPERATOR_VERSION=v0.15.2
EIGEN_SDK_GO_VERSION_DEVNET=v0.1.13
OPERATOR_VERSION=v0.15.3
EIGEN_SDK_GO_VERSION_DEVNET=v0.2.0-beta.1
EIGEN_SDK_GO_VERSION_TESTNET=v0.2.0-beta.1
EIGEN_SDK_GO_VERSION_MAINNET=v0.2.0-beta.1

Expand Down Expand Up @@ -73,12 +73,18 @@ install_foundry:
curl -L https://foundry.paradigm.xyz | bash

install_eigenlayer_cli_devnet: ## Install Eigenlayer CLI v0.11.3 (Devnet compatible)
curl -sSfL https://raw.githubusercontent.com/layr-labs/eigenlayer-cli/master/scripts/install.sh | sh -s -- v0.11.3
curl -sSfL https://raw.githubusercontent.com/layr-labs/eigenlayer-cli/master/scripts/install.sh | sh -s -- v0.13.0

anvil_deploy_all_contracts: anvil_deploy_eigen_contracts anvil_deploy_risc0_contracts anvil_deploy_sp1_contracts anvil_deploy_aligned_contracts

anvil_deploy_eigen_contracts:
@echo "Deploying Eigen Contracts..."
. contracts/scripts/anvil/deploy_eigen_contracts.sh

anvil_deploy_risc0_contracts:
@echo "Deploying RISC0 Contracts..."
. contracts/scripts/anvil/deploy_risc0_contracts.sh

anvil_deploy_sp1_contracts:
@echo "Deploying SP1 Contracts..."
. contracts/scripts/anvil/deploy_sp1_contracts.sh
Expand Down Expand Up @@ -155,11 +161,64 @@ anvil_start_with_more_prefunded_accounts:
anvil --load-state contracts/scripts/anvil/state/alignedlayer-deployed-anvil-state.json --block-time 7 -a 2000

__AGGREGATION_MODE__: ## ____
start_proof_aggregator_local: ## Start the proof aggregator locally using Mock Verifier Contract
cargo run --manifest-path ./aggregation_mode/Cargo.toml --release -- config-files/config-proof-aggregator-mock.yaml

start_proof_aggregator_local_with_proving: ## Start the proof aggregator locally using SP1 Verifier Contract
cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --features prove -- config-files/config-proof-aggregator.yaml
is_aggregator_set:
@if [ -z "$(AGGREGATOR)" ]; then \
echo "Error: AGGREGATOR is not set. Please provide arg AGGREGATOR='sp1' or 'risc0'."; \
exit 1; \
fi

reset_last_aggregated_block:
@echo "Resetting last aggregated block..."
@echo '{"last_aggregated_block":0}' > config-files/proof-aggregator.last_aggregated_block.json

start_proof_aggregator_dev: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with mock proofs (DEV mode)
AGGREGATOR=$(AGGREGATOR) RISC0_DEV_MODE=1 cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --bin proof_aggregator -- config-files/config-proof-aggregator-mock.yaml

start_proof_aggregator: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with proving activated
AGGREGATOR=$(AGGREGATOR) cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --features prove --bin proof_aggregator -- config-files/config-proof-aggregator.yaml

start_proof_aggregator_dev_ethereum_package: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with mock proofs (DEV mode) in ethereum package
AGGREGATOR=$(AGGREGATOR) RISC0_DEV_MODE=1 cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --bin proof_aggregator -- config-files/config-proof-aggregator-mock-ethereum-package.yaml

start_proof_aggregator_ethereum_package: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with proving activated in ethereum package
AGGREGATOR=$(AGGREGATOR) cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --features prove --bin proof_aggregator -- config-files/config-proof-aggregator-ethereum-package.yaml

start_proof_aggregator_gpu: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with proving + GPU acceleration (CUDA)
AGGREGATOR=$(AGGREGATOR) SP1_PROVER=cuda cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --features prove,gpu --bin proof_aggregator -- config-files/config-proof-aggregator.yaml

start_proof_aggregator_gpu_ethereum_package: is_aggregator_set reset_last_aggregated_block ## Starts proof aggregator with proving activated in ethereum package
AGGREGATOR=$(AGGREGATOR) SP1_PROVER=cuda cargo run --manifest-path ./aggregation_mode/Cargo.toml --release --features prove,gpu --bin proof_aggregator -- config-files/config-proof-aggregator-ethereum-package.yaml

verify_aggregated_proof_sp1_holesky_stage:
@echo "Verifying SP1 in aggregated proofs on holesky..."
@cd batcher/aligned/ && \
cargo run verify-agg-proof \
--network holesky-stage \
--from-block $(FROM_BLOCK) \
--proving_system SP1 \
--public_input ../../scripts/test_files/sp1/sp1_fibonacci_4_1_3.pub \
--program-id-file ../../scripts/test_files/sp1/sp1_fibonacci_4_1_3.vk \
--beacon_url $(BEACON_URL) \
--rpc_url https://ethereum-holesky-rpc.publicnode.com

verify_aggregated_proof_risc0_holesky_stage:
@echo "Verifying RISC0 in aggregated proofs on holesky..."
@cd batcher/aligned/ && \
cargo run verify-agg-proof \
--network holesky-stage \
--from-block $(FROM_BLOCK) \
--proving_system Risc0 \
--program-id-file ../../scripts/test_files/risc_zero/fibonacci_proof_generator/fibonacci_id_2_0.bin \
--public_input ../../scripts/test_files/risc_zero/fibonacci_proof_generator/risc_zero_fibonacci_2_0.pub \
--beacon_url $(BEACON_URL) \
--rpc_url https://ethereum-holesky-rpc.publicnode.com

install_aggregation_mode: ## Install the aggregation mode with proving enabled
cargo install --path aggregation_mode --features prove,gpu --bin proof_aggregator

agg_mode_write_program_ids: ## Write proof aggregator zkvm programs ids
@cd aggregation_mode && ./scripts/build_programs.sh

_AGGREGATOR_:

Expand Down Expand Up @@ -297,7 +356,7 @@ operator_remove_from_whitelist:

operator_deposit_into_mock_strategy:
@echo "Depositing into mock strategy"
$(eval STRATEGY_ADDRESS = $(shell jq -r '.addresses.strategies.MOCK' contracts/script/output/devnet/eigenlayer_deployment_output.json))
$(eval STRATEGY_ADDRESS = $(shell jq -r '.addresses.strategies.WETH' contracts/script/output/devnet/eigenlayer_deployment_output.json))
@go run operator/cmd/main.go deposit-into-strategy \
--config $(CONFIG_FILE) \
--strategy-address $(STRATEGY_ADDRESS) \
Expand Down Expand Up @@ -527,6 +586,11 @@ batcher_send_burst_groth16: batcher/target/release/aligned
@mkdir -p scripts/test_files/gnark_groth16_bn254_infinite_script/infinite_proofs
@./batcher/aligned/send_burst_tasks.sh $(BURST_SIZE) $(START_COUNTER)

batcher_send_proof_with_random_address:
@cd batcher/aligned/ && ./send_proof_with_random_address.sh

batcher_send_burst_with_random_address:
@cd batcher/aligned/ && ./send_burst_with_random_address.sh

__TASK_SENDER__:
BURST_TIME_SECS ?= 3
Expand Down Expand Up @@ -704,12 +768,16 @@ deploy_proof_aggregator:
@echo "Deploying ProofAggregator contract on $(NETWORK) network..."
@. contracts/scripts/.env.$(NETWORK) && . contracts/scripts/deploy_proof_aggregator.sh

upgrade_proof_aggregator:
@echo "Upgrading ProofAggregator Contract on $(NETWORK) network..."
@. contracts/scripts/.env.$(NETWORK) && . contracts/scripts/upgrade_proof_aggregator.sh

build_aligned_contracts:
@cd contracts/src/core && forge build
@cd contracts/src/core && forge build --via-ir

show_aligned_error_codes:
@echo "\nAlignedLayerServiceManager errors:"
@cd contracts && forge inspect src/core/IAlignedLayerServiceManager.sol:IAlignedLayerServiceManager errors
@cd contracts && forge inspect src/core/IAlignedLayerServiceManager.sol:IAlignedLayerServiceManager errors
@echo "\nBatcherPaymentService errors:"
@cd contracts && forge inspect src/core/BatcherPaymentService.sol:BatcherPaymentService errors

Expand Down Expand Up @@ -1259,6 +1327,7 @@ ethereum_package_inspect: ## Prints detailed information about the net

ethereum_package_rm: ## Stops and removes the ethereum_package environment and used resources
kurtosis enclave rm aligned -f
kurtosis engine stop

batcher_start_ethereum_package: user_fund_payment_service
@echo "Starting Batcher..."
Expand All @@ -1269,11 +1338,11 @@ aggregator_start_ethereum_package:
$(MAKE) aggregator_start AGG_CONFIG_FILE=config-files/config-aggregator-ethereum-package.yaml

operator_start_ethereum_package:
$(MAKE) operator_start OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml
$(MAKE) operator_start ENVIRONMENT=devnet OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml

operator_register_start_ethereum_package:
$(MAKE) operator_full_registration OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml \
$(MAKE) operator_start OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml
$(MAKE) operator_full_registration OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml
$(MAKE) operator_start ENVIRONMENT=devnet OPERATOR_ADDRESS=0x70997970C51812dc3A010C7d01b50e0d17dc79C8 CONFIG_FILE=config-files/config-operator-1-ethereum-package.yaml


install_spamoor: ## Instal spamoor to spam transactions
Expand Down
Loading
Loading