Upon a FinishEpochRequest, the server manager generates a FinishEpochResponse, which contains, amongst other things, proofs for each output generated by each input in the finished epoch. These proofs must be provided to the on-chain contracts in order to validate notices and execute vouchers.
In order to check the on-chain output validation code, we use a DApp that generates notices and vouchers for every input it receives, like the echo machines in rollups-examples. In order to generate specific types of outputs, we've built a system that allows proofs to be updated on-the-fly.
This system, however, has grown far too complex, and with more dependencies than we'd like to impose on users, and with more manual maintenance than we'd like to do as developers. We'll dive into each of the problems in the next sessions.
✔️ Solution
Reduce the number of dependencies the user has to install natively
Make it easier for new users to run upgrade-proofs.sh
Reduce the number of programs that write programs
Remove hard-coded constants whenever possible
Halt tests if compilation has failed
📈 Subtasks
[ ] Run pip, python, jq, and awk inside the Docker image
[ ] Add yarn scripts for running upgrade-proofs.sh (also in setup mode)
[ ] Remove genScript.ts, and add gen-proofs.sh back
[ ] Change get<OutputType><Index>Proof() to get<OutputType>Proof(<Index>)
[ ] Make get<OutputType>Proof revert if proof with such index doesn't exist
📚 Context
Upon a
FinishEpochRequest
, the server manager generates aFinishEpochResponse
, which contains, amongst other things, proofs for each output generated by each input in the finished epoch. These proofs must be provided to the on-chain contracts in order to validate notices and execute vouchers.In order to check the on-chain output validation code, we use a DApp that generates notices and vouchers for every input it receives, like the
echo
machines inrollups-examples
. In order to generate specific types of outputs, we've built a system that allows proofs to be updated on-the-fly.This system, however, has grown far too complex, and with more dependencies than we'd like to impose on users, and with more manual maintenance than we'd like to do as developers. We'll dive into each of the problems in the next sessions.
✔️ Solution
upgrade-proofs.sh
📈 Subtasks
pip
,python
,jq
, andawk
inside the Docker imageyarn
scripts for runningupgrade-proofs.sh
(also in setup mode)genScript.ts
, and addgen-proofs.sh
backget<OutputType><Index>Proof()
toget<OutputType>Proof(<Index>)
get<OutputType>Proof
revert if proof with such index doesn't existNINPUTS
constantforge build
to catch compilation errors