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::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§
- Types relevant for approval.
 - Disputes related types.
 
Macros§
- Create a new checked
SessionWindowSizewhich cannot be 0. 
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
CollatorFninvocation. - Signal that is being returned when a collation was seconded by a validator.
 - 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.
 - Parameters for
CollationGenerationMessage::SubmitCollation. 
Enums§
- Types of allowed slots.
 - Candidate invalidity details
 - A type that represents a maybe compressed
PoV. - Possible errors when converting from
Vec<Vec<u8>>intoProof. - A statement, where the candidate receipt is included in the
Secondedvariant. - A statement, exactly the same as
Statementbut where seconded messages carry thePersistedValidationData. - Result of the validation of the candidate.
 
Constants§
- How many blocks after finalization an information about backed/included candidate should be pre-loaded (when scraping onchain votes) and kept locally (when pruning).
 - 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_LAGin relay chain selection,MAX_HEADS_LOOK_BACKinapproval-votingandMAX_BATCH_SCRAPE_ANCESTORSindispute-coordinator - 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. - 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 Aliases§
- The cumulative weight of a block in a fork-choice rule.
 - Collation function.
 - A statement, the corresponding signature, and the index of the sender.
 - A statement, the corresponding signature, and the index of the sender.
 - Variant of
SignedFullStatementwhere the signature has not yet been verified.