Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to initialize "pending" blocks in a specific way (add runtime api pending_initialize_block) #1253

Conversation

librelois
Copy link
Contributor

At moonbeam, we necessarily need to initialize "pending" bloks in a different way to classic blocks, because our pallet randomness panics at on_initialize hook if the node doesn't have a VRF key in its keystore.
We need to tell our pallet that we're in the context of a "pending" block built by an RPC provider, and not a normal block. Somehow, we need to modify the client/runtime interface to tell the runtime that we're in the context of a "pending" block, the simplest solution we've found is to add a new method to the runtime API EthereumRuntimeRPCApi.

@librelois
Copy link
Contributor Author

@sorpaas @boundless-forest can someone merge this PR?

@boundless-forest boundless-forest merged commit cacdfd7 into polkadot-evm:master Aug 1, 2024
4 checks passed
@librelois librelois deleted the elois-pending-runtime-api branch August 1, 2024 09:17
ipapandinas pushed a commit to AstarNetwork/frontier that referenced this pull request Sep 4, 2024
magecnion added a commit to freeverseio/laos that referenced this pull request Sep 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants