Expand description
Primitive types used on the node-side.
Unlike the polkadot-primitives
crate, these primitives are only used on the node-side,
not shared between the node and the runtime. This crate builds on top of the primitives defined
there.
Re-exports§
pub use disputes::dispute_is_inactive;
pub use disputes::CandidateVotes;
pub use disputes::DisputeMessage;
pub use disputes::DisputeMessageCheckError;
pub use disputes::DisputeStatus;
pub use disputes::InvalidDisputeVote;
pub use disputes::SignedDisputeStatement;
pub use disputes::Timestamp;
pub use disputes::UncheckedDisputeMessage;
pub use disputes::ValidDisputeVote;
pub use disputes::ACTIVE_DURATION_SECS;
Modules§
Macros§
- new_
session_ window_ size - Create a new checked
SessionWindowSize
which cannot be 0.
Structs§
- Available
Data - This is the data we keep available for each candidate included in the relay chain.
- Babe
Epoch - BABE epoch information
- Babe
Epoch Configuration - Configuration data used by the BABE consensus engine that may change with epochs.
- Block
Data - Parachain block data.
- Collation
- The output of a collator.
- Collation
Generation Config - Configuration for the collation generator
- Collation
Result - Result of the
CollatorFn
invocation. - Collation
Seconded Signal - Signal that is being returned when a collation was seconded by a validator.
- Erasure
Chunk - A chunk of erasure-encoded block data.
- PoV
- A Proof-of-Validity
- Proof
- This is a convenience type to allow the Erasure chunk proof to Decode into a nested BoundedVec
- Session
Window Size - Type of a session window size.
- Submit
Collation Params - Parameters for
CollationGenerationMessage::SubmitCollation
.
Enums§
- Babe
Allowed Slots - Types of allowed slots.
- Invalid
Candidate - Candidate invalidity details
- Maybe
Compressed PoV - A type that represents a maybe compressed
PoV
. - Merkle
Proof Error - Possible errors when converting from
Vec<Vec<u8>>
intoProof
. - Statement
- A statement, where the candidate receipt is included in the
Seconded
variant. - Statement
WithPVD - A statement, exactly the same as
Statement
but where seconded messages carry thePersistedValidationData
. - Validation
Result - Result of the validation of the candidate.
Constants§
- DISPUTE_
CANDIDATE_ LIFETIME_ AFTER_ FINALIZATION - How many blocks after finalization an information about backed/included candidate should be pre-loaded (when scraping onchain votes) and kept locally (when pruning).
- DISPUTE_
WINDOW - It would be nice to draw this from the chain state, but we have no tools for it right now. On Polkadot this is 1 day, and on Kusama it’s 6 hours.
- MAX_
FINALITY_ LAG - Linked to
MAX_FINALITY_LAG
in relay chain selection,MAX_HEADS_LOOK_BACK
inapproval-voting
andMAX_BATCH_SCRAPE_ANCESTORS
indispute-coordinator
- NODE_
VERSION - The current node version, which takes the basic SemVer form
<major>.<minor>.<patch>
. In general, minor should be bumped on every release while major or patch releases are relatively rare. - POV_
BOMB_ LIMIT - The bomb limit for decompressing PoV blobs.
- VALIDATION_
CODE_ BOMB_ LIMIT Deprecated - The bomb limit for decompressing code blobs.
Functions§
- maybe_
compress_ pov - Compress a PoV, unless it exceeds the
POV_BOMB_LIMIT
.
Type Aliases§
- Babe
Randomness - Randomness type required by BABE operations.
- Block
Weight - The cumulative weight of a block in a fork-choice rule.
- Collator
Fn - Collation function.
- Horizontal
Messages - Signed
Full Statement - A statement, the corresponding signature, and the index of the sender.
- Signed
Full Statement WithPVD - A statement, the corresponding signature, and the index of the sender.
- Unchecked
Signed Full Statement - Variant of
SignedFullStatement
where the signature has not yet been verified. - Upward
Messages