Skip to main content

espresso_types/v0/v0_3/
mod.rs

1use vbs::version::Version;
2
3#[cfg(feature = "node")]
4pub use super::v0_1::L1Client;
5// Re-export types which haven't changed since the last minor version.
6pub use super::v0_1::{
7    ADVZNsProof, ADVZTxProof, AccountQueryData, BLOCK_MERKLE_TREE_HEIGHT, BlockMerkleCommitment,
8    BlockMerkleTree, BlockSize, BuilderSignature, ChainId, FEE_MERKLE_TREE_HEIGHT, FeeAccount,
9    FeeAccountProof, FeeAmount, FeeInfo, FeeMerkleCommitment, FeeMerkleProof, FeeMerkleTree, Index,
10    Iter, L1BlockInfo, L1ClientOptions, L1SafetyMargin, L1Snapshot, NS_ID_BYTE_LEN,
11    NS_OFFSET_BYTE_LEN, NUM_NSS_BYTE_LEN, NUM_TXS_BYTE_LEN, NamespaceId, NsIndex, NsIter,
12    NsPayload, NsPayloadBuilder, NsPayloadByteLen, NsPayloadOwned, NsPayloadRange, NsTable,
13    NsTableBuilder, NsTableValidationError, NumNss, NumTxs, NumTxsRange, NumTxsUnchecked, Payload,
14    PayloadByteLen, TX_OFFSET_BYTE_LEN, TimeBasedUpgrade, Transaction, TxIndex, TxIter, TxPayload,
15    TxPayloadRange, TxTableEntries, TxTableEntriesRange, Upgrade, UpgradeMode, UpgradeType,
16    ViewBasedUpgrade,
17};
18#[cfg(feature = "node")]
19pub(crate) use super::v0_1::{L1ClientMetrics, L1Event, L1State, L1UpdateTask};
20
21pub const VERSION: Version = Version { major: 0, minor: 3 };
22
23/// Maximum number of active validators in the stake table.
24///
25/// `select_active_validator_set()` picks the top `MAX_VALIDATORS` validators
26/// by stake. Only these validators participate in consensus and can be elected
27/// leader.
28pub const MAX_VALIDATORS: usize = 100;
29
30mod chain_config;
31mod header;
32mod nsproof;
33mod stake_table;
34mod state;
35mod state_cert;
36mod txproof;
37
38pub use chain_config::*;
39pub use header::*;
40pub use nsproof::*;
41pub use stake_table::*;
42pub use state::*;
43pub use state_cert::*;
44pub use txproof::*;