Add dispatchable filtering for PoA mainnet launch#67
Merged
Conversation
brenzi
requested changes
Oct 5, 2021
runtime/src/lib.rs
Outdated
| pub struct BaseFilter; | ||
| impl Contains<Call> for BaseFilter { | ||
| fn contains(call: &Call) -> bool { | ||
| !matches!(call, Call::Balances(..) | Call::Treasury(..) | Call::Vesting(_)) |
Collaborator
There was a problem hiding this comment.
we need to also filter Teerex, Scheduler, Proxy, Multisig
brenzi
requested changes
Oct 5, 2021
| impl frame_system::Config for Runtime { | ||
| /// The basic call filter to use in dispatchable. | ||
| #[cfg(not(feature = "mainnet-launch"))] | ||
| type BaseCallFilter = frame_support::traits::Everything; |
Collaborator
There was a problem hiding this comment.
while we're on it, we could solve integritee-network/pallet-teerex#46 too
In that sense, there will only be BaseFilter here and the compiler flag would rather be inside the BaseFilter definition
Collaborator
There was a problem hiding this comment.
and please make a comment in the code why we filter it: integritee-network/pallet-teerex#7
added 4 commits
October 7, 2021 09:13
Add a compiler flag mainnet-launch to block calls only for the standalone mainnet Suppress all Vesting calls
…ig calls and filter shielding/unshielding calls from teerex
b38adcd to
9230fea
Compare
brenzi
approved these changes
Oct 7, 2021
brenzi
requested changes
Oct 7, 2021
Collaborator
brenzi
left a comment
There was a problem hiding this comment.
filtering unshield/shield will break our M6 CI, so please remove that filter again
brenzi
approved these changes
Oct 7, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Filter: vesting, balances and treasury call, when node compiled with
--features mainnet-launch