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

Add Auction Types #1726

Merged
merged 9 commits into from
Jul 18, 2024
Merged

Add Auction Types #1726

merged 9 commits into from
Jul 18, 2024

Conversation

tbro
Copy link
Contributor

@tbro tbro commented Jul 18, 2024

This PR:

Adds BidTx and friends to v0_3. The intention is to provide the necessary elements for first round of Marketplace integration. Since this is all hidden behind a version gate, our priority should be to satisfy integration necessities.

This PR does not:

Attempt to implement many changes necessary for sequencer v0_3 (alias Marketplace 0). We only need the basic types for now, and maybe some constructors and such.

Key places to review:

  • types/src/v0/v0_3/auction.rs
  • types/src/v0/impls/auction.rs is also included to provide constructors, but most of that logic will not be executed at this time.

Adds `BidTx` and friends to `v0_3`. The intention is to provide the
necessary elements for first round of Marketplace integration. Since
this is all hidden behind a version gate, our priority should be
to satisfy integration necessities
}

/// Sign `BidTxBody` and return the signature.
pub fn sign(&self, key: &EthKeyPair) -> Result<Signature, SigningError> {
Copy link
Member

Choose a reason for hiding this comment

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

Do we expect to use this function outside of this crate? If not, can it be a private function, or removed (i.e., signed would call sign_builder_message directly), to make it clearer that to get BidTx we just need to use signed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yea, I guess my preference is in early integration is to have too much rather than not enough. df255e6

Comment on lines 120 to 121
let signature = FeeAccount::sign_builder_message(&key, body.commit().as_ref()).unwrap();
Self { signature, body }
Copy link
Member

Choose a reason for hiding this comment

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

Nit: Can we replace these lines with the signed function?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Member

@shenkeyao shenkeyao left a comment

Choose a reason for hiding this comment

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

May need a second approval in case I'm not caught up with everything yet, but this looks good to me! I mainly focused on reviewing the bid tx part.

@tbro
Copy link
Contributor Author

tbro commented Jul 18, 2024

I'm going to go ahead and merge b/c eve

May need a second approval in case I'm not caught up with everything yet, but this looks good to me! I mainly focused on reviewing the bid tx part.

I'm going to go ahead and merge b/c everything is gated behind a version anyway.

@tbro tbro merged commit ea25667 into main Jul 18, 2024
14 checks passed
@tbro tbro deleted the tb/auction-types branch July 18, 2024 20:17
@tbro tbro mentioned this pull request Jul 24, 2024
4 tasks
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.

2 participants