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

composability: refactor democracy using Origin instead of nested dependencies #402

Open
brenzi opened this issue Aug 28, 2024 · 0 comments

Comments

@brenzi
Copy link
Member

brenzi commented Aug 28, 2024

Our pallets have deeply nested dependencies which means that they are not composable. i.e. democracy logic can't be used by non-encointer runtimes. Moreover, coding gets trickier the more dependencies we add.

This should be avoided:

pub trait Config:
frame_system::Config
+ pallet_encointer_scheduler::Config
+ pallet_encointer_ceremonies::Config
+ pallet_encointer_communities::Config
+ pallet_encointer_reputation_commitments::Config

We could introduce a custom Origin per CommunityIdentifier (or global) which is allowed to enact proposals by calling specific dispatchables.

As we are in pragmatic mode currently, this can surely wait. But a cleanup is due sooner or later

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

No branches or pull requests

1 participant