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

Migrate pallet-aura to umbrella crate #6622

Open
wants to merge 18 commits into
base: master
Choose a base branch
from

Conversation

runcomet
Copy link
Contributor

@runcomet runcomet commented Nov 23, 2024

Part of #6504

Description

  • Includes sp-application-crypto in polkadot-sdk-frame crate, re-exports RuntimeAppPublic and BoundToRuntimeAppPublic as part of the cryptography module.
  • Adds a consensus module for commonly used consensus types.

@cla-bot-2021
Copy link

cla-bot-2021 bot commented Nov 23, 2024

User @runcomet, please sign the CLA here.

@runcomet runcomet marked this pull request as ready for review November 23, 2024 02:16
@runcomet runcomet requested a review from a team as a code owner November 23, 2024 02:16
BoundedSlice, BoundedVec, ConsensusEngineId, Parameter,
use frame::{
deps::{
frame_support::{ConsensusEngineId, Parameter},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please read the new checklist named in the issue, and update the PR to adhere to it. Thank you!

@re-gius re-gius added R0-silent Changes should not be mentioned in any release notes T1-FRAME This PR/Issue is related to core FRAME, the framework. labels Dec 9, 2024
Copy link
Contributor

@re-gius re-gius left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix failing CI jobs (missing imports)

@paritytech-review-bot paritytech-review-bot bot requested a review from a team January 25, 2025 23:10
@runcomet
Copy link
Contributor Author

please review @kianenigma @re-gius

@@ -363,6 +366,9 @@ pub mod runtime {
/// Consider using the new version of this [`frame_construct_runtime`].
pub use frame_support::construct_runtime;

/// Related to runtime construction.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This comment is not relevant for me

BoundedSlice, BoundedVec, ConsensusEngineId, Parameter,
use frame::{
runtime::prelude::*,
traits::{DisabledValidators, FindAuthor, IsMember, OnTimestampSet, OneSessionHandler},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would add IsMember to the main prelude of the umbrella crate

Copy link
Contributor Author

@runcomet runcomet Jan 30, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also moved OnTimestampSet to top level prelude, used in Babe and Aura pallets.

FindAuthor & DisableValidators to account mod

traits::{DisabledValidators, FindAuthor, Get, OnTimestampSet, OneSessionHandler},
BoundedSlice, BoundedVec, ConsensusEngineId, Parameter,
use frame::{
runtime::prelude::*,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use the main prelude frame::prelude::* instead of the runtime one

@@ -363,6 +366,9 @@ pub mod runtime {
/// Consider using the new version of this [`frame_construct_runtime`].
pub use frame_support::construct_runtime;

/// Related to runtime construction.
pub use frame_support::{BoundedSlice, BoundedVec};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you added them just to use the runtime prelude in the aura pallet, I think it's better to change it to the main prelude (see comment) and remove this from here

@paritytech-review-bot paritytech-review-bot bot requested a review from a team January 30, 2025 12:07
@acatangiu
Copy link
Contributor

please pause work on migrating polkadot-sdk pallets to umbrella crate until we come to a final decision here: #6504 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
R0-silent Changes should not be mentioned in any release notes T1-FRAME This PR/Issue is related to core FRAME, the framework.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants