I find a similar question here, but it's for code running in a para chain.
My question is how can we get the relay chain block number by a para chain block? There are code like this in polkadot sdk.
let latest = RCBlockNumberProviderOf::<T::Coretime>::current_block_number();
How can we get the code work like this in fronted? I checked the coretime block 1363778.
- Should we use the
relay_parent_number
in theparachainsystem(set_validation_data)
extrinsic? - Is every block in a para chain has a
parachainsystem(set_validation_data)
extrinsic?