-
Notifications
You must be signed in to change notification settings - Fork 342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Operator: Bump SP1 and Risc0 version + Retro-Compatible Operator #1208
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested on my machine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks OK, will test later today.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works on my machine.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Operators should have retrocompatibility. So we should have 2 ffis and each operator check with both
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need to push old proof generators. To test we can checkout previous branch. I would avoid pushing this because this pr is 87 files, and a very big portion of these are the old proof generators
@mv scripts/test_files/sp1/fibonacci_proof_generator/program/elf/riscv32im-succinct-zkvm-elf scripts/test_files/sp1/sp1_fibonacci.elf | ||
@mv scripts/test_files/sp1/fibonacci_proof_generator/script/sp1_fibonacci.proof scripts/test_files/sp1/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use risc0_zkvm::{InnerReceipt, Receipt}; | ||
|
||
#[no_mangle] | ||
pub extern "C" fn verify_risc_zero_receipt_old_ffi( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should add the try-catch
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See #1174.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If it is too much work now, maybe don't.
} | ||
|
||
#[no_mangle] | ||
pub extern "C" fn verify_sp1_proof_old_ffi( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you uploaded this by err.
@MarcosNicolau @uri-99 I am closing this in favor or #1307 due to merge issues |
closes #1205
This PR:
risc0
andsp1
verifier versions of operators.dialoguer
->inquire
to accomodate a dependency conflict.To Test:
Verify network bindings works on a local network:
make test_risc_zero_go_bindings_macos
make test_sp1_go_bindings_macos
make batcher_send_risc0_task
make batcher_send_sp1_task
cd examples/zkquiz/quiz/script && cargo run -r
cd examples/validating-public-input/risc_zero/fibonacci_proof_generator && cargo run -r
Verify Retro Compatiblility of Operator Verifiers:
To verify operator retro-compatibility we deploy the rest of infrastructure of Aligned and boot the retro-compatible operator. This tests that network retro-compatible operator can verify SP1/Risc0 proofs from both verifier versions.
Note:
Commands suffixed with
_old
indicate the deprecated version of the SP1/Risc0 verifier that is currently running ontestnet
To test this have two repos of aligned_layer one set to
testnet
and one to1205-bump-sp1-and-risc0-version
.In
testnet
repo:In
1205-bump-sp1-and-risc0-version
repo:testnet
repo.Observe the
Risc0 proof verification failed.
andSP1 proof verification failed.
logs are emitted and the operator successfully verifying the proofs from the old SP1/Risc0 verifiers. If you send a proof from the latest version of SP1/Risc0 you should notice its verification fails in the batcher.1205-bump-sp1-and-risc0-version
repo.testnet
repo, kill the batcher.1205-bump-sp1-and-risc0-version
and start the batcher within the repo.1205-bump-sp1-and-risc0-version
repo.Observe the operator successfully verifying the proofs from the new SP1/Risc0 verifiers. If you send a proof from the older version of SP1/Risc0 you should notice its verification fails in the batcher.