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

Standardize guest Input format #38

Open
1 of 4 tasks
CeciliaZ030 opened this issue Feb 26, 2024 · 1 comment
Open
1 of 4 tasks

Standardize guest Input format #38

CeciliaZ030 opened this issue Feb 26, 2024 · 1 comment
Assignees

Comments

@CeciliaZ030
Copy link
Contributor

CeciliaZ030 commented Feb 26, 2024

Describe the feature request

All guests should start building from the same input struct, currently we have Input which is responsible for block-building and TaikoSystemInfo which contains the current state of L1 & L2.

pub struct Input<E: TxEssence> {
    pub parent_header: Header,
    pub beneficiary: Address,
    pub gas_limit: U256,
    pub timestamp: U256,
    pub extra_data: Bytes,
    pub mix_hash: B256,
    pub transactions: Vec<Transaction<E>>,
    pub withdrawals: Vec<Withdrawal>,
    pub parent_state_trie: MptNode,
    pub parent_storage: HashMap<Address, StorageEntry>,
    pub contracts: Vec<Bytes>,
    pub ancestor_headers: Vec<Header>,
    pub base_fee_per_gas: U256,
}

pub struct TaikoSystemInfo {
    pub l1_hash: B256,
    pub l1_height: u64,
    pub l2_tx_list: Vec<u8>,
    pub prover: Address,
    pub graffiti: B256,
    pub l1_signal_root: B256,
    pub l2_signal_root: B256,
    pub l2_withdrawals: Vec<Withdrawal>,
    pub block_proposed: BlockProposed,
    pub l1_next_block: Block<EthersTransaction>,
    pub l2_block: Block<EthersTransaction>,
}
  • Collapse them to one struct, make sys_info as a field or the other way around
  • Change all guests instance to adapt to new input format
  • Also fix Powdr Input Deserialization #37 on the way :)
Screen Shot 2024-02-27 at 1 43 02 AM

Spam policy

  • I verify that this issue is NOT SPAM and understand SPAM issues will be closed and reported to GitHub, resulting in ACCOUNT TERMINATION.
@petarvujovic98
Copy link
Contributor

@CeciliaZ030 Should the PR be against the multi-guest branch on your repo?

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

No branches or pull requests

2 participants