Registry / other / sp-inherents

sp-inherents

JSON →
library41.0.0rscratesunverified

Provides types and traits for creating and checking inherents.

# Cargo.toml [dependencies] sp-inherents = "41.0.0"
INSTALL
IMPORT
SIG · SP-INHERENTS
S
sp-inherents
otherrustv41.0.0
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

InherentData
use sp_inherents::InherentData;

Creates and queries inherent data for blockchain runtime.

use sp_inherents::InherentData; let mut data = InherentData::new(); data.put_data("my_key", &42u32).unwrap(); let value: u32 = data.get_data("my_key").unwrap().unwrap(); println!("Value: {}", value);
Debug
Known issues
breakingPart of the Polkadot SDK; requires specific Substrate dependencies and may have breaking changes across versions.
fix
Pin to a specific version and follow Substrate release notes.
affects: >=40.0.0
Upgrade
Version history
41.0.0latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
7 hits · last 30 days
node
6
Resources
sp-inherents — cargo add sp-inherents · libregistry