Skip to content
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

--print-calldata for later proof submission #125

Merged
merged 5 commits into from
Aug 13, 2024
Merged

Conversation

jbrower95
Copy link
Contributor

@jbrower95 jbrower95 commented Aug 12, 2024

Summary

  • If --print-calldata is specified during the credentials or checkpoint command, we will prepare the transaction(s) without sending, and print the calldata as structured JSON.
  • For checkpoint proofs, we will print the calldata to start the checkpoint if one is not active yet. if one is already active, we will print the calldata for the proofs, batched according to --batchSize.

The proofs will be printed with (TO) and (CALLDATA) fields, all hex encoded. Credential proofs include validator_indices, which is an array of validator indices to be attested in that proof. You should submit the sequentially to network, taking care of your nonces as needed. They may be submitted by either the Eigenpod's owner, or an approved proof submitter (see assign-submitter command).

Approach

We use the NoSend option in abigen, and combine it with a burner ETH wallet. I've hardcoded the PK of an eth wallet into the script -- the signed data is never used anyways.

Data Format

You should expect either an array of Transaction, or an array of CredentialProofTransaction

image

Example Command

./cli checkpoint --podAddress $EIGENPOD_ADDRESS --beaconNode $NODE_BEACON --execNode $NODE_ETH --print-calldata

Submitting to network

You can use the cast tool to submit these proofs to network.

cast send $TO $CALLDATA --rpc-url $NODE_ETH --private-key $EIGENPOD_PK

Testing

checkpoint

image ## credentials image

Test transactions

@jbrower95 jbrower95 marked this pull request as ready for review August 12, 2024 14:36
@jbrower95 jbrower95 changed the title Print calldata information for later submission [WIP] Print calldata information for later submission Aug 13, 2024
cli/main.go Outdated Show resolved Hide resolved
Copy link
Contributor

@wadealexc wadealexc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It may be time to start compiling some of this config into structs. The parameter lists for these methods are getting big :D

@jbrower95 jbrower95 changed the title [WIP] Print calldata information for later submission Print calldata information for later submission Aug 13, 2024
@jbrower95
Copy link
Contributor Author

yeah most of this is going to be structs next week

@jbrower95 jbrower95 requested a review from wadealexc August 13, 2024 19:45
@jbrower95 jbrower95 changed the title Print calldata information for later submission --print-calldata for later proof submission Aug 13, 2024
@jbrower95 jbrower95 merged commit dd69d47 into master Aug 13, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants