Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* update contracts * etherman updated * synchronizer * Synchronizer with AddSequence * aggregator and txmanager working * smc latest version * linter * genesis + test fixed * Extra check * Update/executor proto (0xPolygonHermez#1384) * Adapt to newest executor proto * Bump github.com/spf13/viper from 1.13.0 to 1.14.0 (0xPolygonHermez#1369) Bumps [github.com/spf13/viper](https://github.com/spf13/viper) from 1.13.0 to 1.14.0. - [Release notes](https://github.com/spf13/viper/releases) - [Commits](spf13/viper@v1.13.0...v1.14.0) --- updated-dependencies: - dependency-name: github.com/spf13/viper dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Bump github.com/ethereum/go-ethereum from 1.10.25 to 1.10.26 (0xPolygonHermez#1368) Bumps [github.com/ethereum/go-ethereum](https://github.com/ethereum/go-ethereum) from 1.10.25 to 1.10.26. - [Release notes](https://github.com/ethereum/go-ethereum/releases) - [Commits](ethereum/go-ethereum@v1.10.25...v1.10.26) --- updated-dependencies: - dependency-name: github.com/ethereum/go-ethereum dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * WIP * WIP * rever prover proto * Add acc_input_hash * linter * linter * Use new executor image Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * linter * Disable prover * Update/executor proto (0xPolygonHermez#1403) * Adapt to newest executor proto * WIP * WIP * rever prover proto * Add acc_input_hash * linter * linter * Use new executor image * update files * db test * linter * names modification * fixes * Feature/latest smc (0xPolygonHermez#1412) * latest smc * Code addapted * update smc * linter * extra events * fix tests * update broadcast proto * sequencer fix due to trusted reorg * Lastes smc version * linter * genesis * fix: update SCs addresses in config Signed-off-by: Paolo Grisoli <[email protected]> * check verified state root + genesis * fix state root check when proofs are aggregated * Recursive Aggregator (0xPolygonHermez#1419) * New recursive aggregator2 * fix: update sequences table name * fix: handle errors properly * replace "sequence_group" table for "sequences". Set OldAccInputHash in buildInputProver function * feat: replace the old aggregator with the new one This commit wires the new aggregator in place of the old one. Everithing related to the old aggregato has been wiped out. * fix: wait to be synced after sending final proof This commit fixes a bug that was causing the aggregato to start generating a duplicated proof. The problem was that after sending the final proof to L1, the aggregator was not waiting for it to be seen by the synchronizer. Instead it was checking immediately for batches to prove. Since the synchronizer didn't update the verified batches yet, the aggregator was picking up again the first virtual batch which followed the previous verified batch. This commit adds a signal emitted after a final proof is sent. The next aggregator iteration will get the signal and wait for the synchronizer to sync. Signed-off-by: Paolo Grisoli <[email protected]> * Added EthTxManager.VerifyBatches. Use this instead of Rthman.VerifyBatches * fix: send final proof in a separate goroutine This commit moves the logic to send the final proof in its own goroutine. This allows to immediately free the prover and at the same time way for the synchronizer to catch up. The `recursive_proof` table is now cleared only after the network is up to date. * fix: clear proofs cache if no final proof ready This commit makes the proofs cache to be cleared when a final proof is not ready. This avoids the cache to grow up until a final proof is sent. * fix: rebasing dust * feat: use etherman addresses in batchsender script * fix: don't fill block twice in verifyBatchesEvent This commit fixes a problem in etherman that was causing the synchronizer to crash on a VerifyBatches event. Credits to @ARR552 for the fix * chore: update prover image in test/docker-compose * fix: linter and simplify prover interface This commit addresses linter complaints and simplifies the prover interface by unwrapping proof responses types. * fix: remove unused parameter for prover clients * chore: move table schema in 0001.sql * fix: remove old proof table and rename the new one * fix: fix some linter problems * test: fix TestSequenceTooBig * fix: remove old Provers config * feat: better error handling in aggregator/prover * test: fix executor tests using new prover image * chore: add migration for state proof table * style: return typed errors in aggregator/prover * style: make prover field private * initial implementation checkProofReadyToVerify * style: timer mutex, fix duplication, logs/errcheck This commit elaborates more the changes introduced to send a final proof at a given point in time, without a proof in generating: - Added a mutex to guard the timer to send the final proof. - Removed some code duplication. In particular the two functions `checkVerifyProof` and `checkProofReadyToVerify` have been merged into the `tryBuildFinalProof` function. - Some logs were not correct, in particular the one informing about the last verified batch number was using the wrong value. - Some errors were not checked like the one returned from `checkProofReadyToVerify` (now `tryBuildFinalProof`). - Few variables renaming for better readability. Signed-off-by: Paolo Grisoli <[email protected]> * fix: update SCs addresses * fix: add check on mocked LER and SR This commit adds a check (similar to the one in the old aggregator) to check if we are using a mocked prover. In this case the `NewStateRoot` and `NewLocalExitRoot` values returned by the mock prover are not valid and need to be replaced with the ones returned by the executor. * fix:unlock underlying proofs if VerifyBatches err This commit fixes the bug happening when an error is returned calling `VerifyBatches`. We were unlocking the wrong proof and the correct one/ones was/were stuck in the `generating` status. * fix: better fix for VerifyBatches error This commit implements a better fix for the case an error is returned by VerifyBatches. In case of a proof coming from an aggregation job, it stores it, making it available for the other provers to be taken again. * fix: update leftover SCs addresses * Rename interval/time agggregator config parameters * fix: adjust config files to new Aggregator names * refac: store aggregated proof in any case This commit changes the behavior when an aggregated proof is crafted. Now the poof is always stored (and the two aggregated proofs deleted) regardless if a final proof needs to be sent or not. * refac: return string pointer for proof ID This commit changes the returned type to be `*string` for the prover functions that return the proof ID. Since the proof ID is stored as `*string` inside the `state.Proof` struct, this change makes more convenient to pass the pointer around and finally store it. * style: use alias for ugly grpc health package name * fix: replace bad Matic SC address * test: fix TestSequenceTooBig Signed-off-by: Paolo Grisoli <[email protected]> Co-authored-by: agnusmor <[email protected]> Co-authored-by: Alonso <[email protected]> * fix merge Signed-off-by: dependabot[bot] <[email protected]> Signed-off-by: Paolo Grisoli <[email protected]> Co-authored-by: Toni Ramírez <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: ToniRamirezM <[email protected]> Co-authored-by: Paolo Grisoli <[email protected]> Co-authored-by: agnusmor <[email protected]>
- Loading branch information