Freeze note on SessionInfo. (#6818)

* Add note about frozen `SessionInfo`.

* Better comment.

---------

Co-authored-by: eskimor <eskimor@no-such-url.com>
This commit is contained in:
eskimor
2023-03-03 21:50:42 +01:00
committed by GitHub
parent d98d948bfc
commit 7d9a0b7cc3
+3
View File
@@ -1603,6 +1603,9 @@ pub fn supermajority_threshold(n: usize) -> usize {
}
/// Information about validator sets of a session.
///
/// NOTE: `SessionInfo` is frozen. Do not include new fields, consider creating a separate runtime
/// API. Reasoning and further outlook [here](https://github.com/paritytech/polkadot/issues/6586).
#[derive(Clone, Encode, Decode, RuntimeDebug, TypeInfo)]
#[cfg_attr(feature = "std", derive(PartialEq))]
pub struct SessionInfo {