Skip to content
Snippets Groups Projects
Unverified Commit 3ea497b5 authored by asynchronous rob's avatar asynchronous rob Committed by GitHub
Browse files

expose the last relay chain block number as an API from parachain-system (#1761)

re:
https://forum.polkadot.network/t/blocknumber-vs-timestamps-should-we-abandon-blocktimes-altogether/4077

This exposes the `LastRelayChainBlockNumber` storage member of
`cumulus-pallet-parachain-system` with a getter and alters the behavior
of this storage item to only be updated in `on_finalize` to ensure a
consistent value throughout `on_initialize` and within transactions.

Parachains, especially with features such as asynchronous backing and
agile coretime, should not use the parachain block number as a clock.
Any feature of Polkadot intended to optimize core utilization and
parachain coretime consumption is likely to worsen this clock as it is
practically applied.
parent db3fd687
Branches
No related merge requests found
Pipeline #397021 passed with stages
in 1 hour, 29 minutes, and 9 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment