Crate polkadot_node_primitives
source ·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::CandidateVotes;
pub use disputes::InvalidDisputeVote;
pub use disputes::SignedDisputeStatement;
pub use disputes::ValidDisputeVote;
Modules
Macros
Create a new checked
SessionWindowSize
Structs
This is the data we keep available for each candidate included in the relay chain.
BABE epoch information
Configuration data used by the BABE consensus engine that may change with epochs.
Parachain block data.
The output of a collator.
Configuration for the collation generator
Result of the
CollatorFn
invocation.Signal that is being returned when a collation was seconded by a validator.
A dispute initiating/participating message that is guaranteed to have been built from signed
statements.
A chunk of erasure-encoded block data.
A Proof-of-Validity
This is a convenience type to allow the Erasure chunk proof to Decode into a nested BoundedVec
Type of a session window size.
A
DisputeMessage
where signatures of statements have not yet been checked.Enums
Types of allowed slots.
Things that can go wrong when constructing a
DisputeMessage
.Candidate invalidity details
A type that represents a maybe compressed
PoV
.Possible errors when converting from
Vec<Vec<u8>>
into Proof
.A statement, where the candidate receipt is included in the
Seconded
variant.Result of the validation of the candidate.
Constants
The amount of time to spend on execution during approval or disputes.
The amount of time to spend on execution during backing.
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.
Linked to
MAX_FINALITY_LAG
in relay chain selection,
MAX_HEADS_LOOK_BACK
in approval-voting
and
MAX_BATCH_SCRAPE_ANCESTORS
in dispute-coordinator
The bomb limit for decompressing PoV blobs.
The bomb limit for decompressing code blobs.
Functions
Compress a PoV, unless it exceeds the
POV_BOMB_LIMIT
.Type Definitions
The cumulative weight of a block in a fork-choice rule.
Collation function.
A statement, the corresponding signature, and the index of the sender.
Variant of
SignedFullStatement
where the signature has not yet been verified.