-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: send GER
inclusion proofs to aggchain prover
#204
feat: send GER
inclusion proofs to aggchain prover
#204
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.
If I remember well, the lastgersync
only stores the GERs that are "latest" in terms of index, but not necessarily all the injections...
Please review if the logic of this sycner does what you expect.
We may need to heavily change how the syncer works, if this is the case just go ahead and simplify the syncer to "just" index the GERs injections, and we will figure out later how we deal with the birdge service, as this syncer was meant to be used by it originally
@arnaubennassar I think we are good here. What the |
444e9b4
to
e62fba4
Compare
4c1b33c
to
67ea09b
Compare
66f859f
to
6f7e97c
Compare
6f7e97c
to
0057047
Compare
e9a4f75
to
1c9543c
Compare
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.
Some comments:
- Make sense to store on DB the L1InfoTreeRoot choosen for proves.. may be it can be extracted from certificate, I'm not sure
feat: add GetGERsByBlockRange function feat: get injected GERs proofs and send to prover fix: lint fix: revert usage of lastGER syncer
09787ea
to
e47f778
Compare
I mean we could, but we would only use it for resending the |
In which DB do you mean? I think that for debug can be useful to known the choosen root.. WDYT? |
I agree, I will add it. |
|
Description
This PR adds the functionality of sending
GlobalExitRoot
inclusion proofs to theaggchain prover
since it is needed to generate a correctauth
proof.To do this, when
aggsender
is inAggchainProof
mode, we collect injectedGER
s inL2
by directly calling theL2
contract to collectInsertGlobalExitRoot
events in a given block range.Before calling the
aggchain prover
to generate theauth
proof,aggsender
will get the last finalizedl1 info tree root
. After that, it will get the all injectedGERs
from theL2
contracts for the block range for which it is building the certificate, and it will generate the inclusion proofs for each injectedGER
based on the last finalizedl1 info tree root
.Also, it will provide the prover with imported bridge exits we are adding to the certificate, but only data in imported bridge exits like:
After that it will call the
aggchain prover
so that it can generate theauth
proof.Also, important note is, we now will use the last finalized
l1 info tree root
in theAggchainProof
mode to generate all the inclusion proofs for every claim (imported bridge exit
), since this is a prerequesite, since theaggchain prover
uses that root to generate the proof.This PR adds a new field called
custom_chain_data
to the certfificate. It is a random byte array returned by theaggchain prover
, and we need to send it to theagglayer
in the certificate.Fixes # (issue)