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

Problem: Missing support for Group module messages #799

Open
davcrypto opened this issue Jan 4, 2023 · 1 comment
Open

Problem: Missing support for Group module messages #799

davcrypto opened this issue Jan 4, 2023 · 1 comment

Comments

@davcrypto
Copy link
Contributor

ref: https://docs.cosmos.network/v0.46/modules/group/03_messages.html

@vincentysc
Copy link
Contributor

vincentysc commented Jan 16, 2023

Roles

  • Admin - add, update, remove group members (not necessary to be a member of the group)
  • Members - submit proposal, vote
  • Group policy account - could be an admin of a group

Decision policy types

  • Threshold decision policy
// policy.json for create group policy
{
    "@type": "/cosmos.group.v1.ThresholdDecisionPolicy",
    "threshold": "1",
    "windows": {
        "voting_period": "120h",
        "min_execution_period": "0s"
    }
}
  • Percentage decision policy
// policy.json for create group policy
{
    "@type": "/cosmos.group.v1.PercentageDecisionPolicy",
    "percentage": "0.5",
    "windows": {
        "voting_period": "120h",
        "min_execution_period": "0s"
    }
}

Proposal

  • withdraw proposal (executed by admin or proposer)
  • aborted proposal

Group msg type list

// Policy
/cosmos.group.v1.MsgCreateGroupWithPolicy
/cosmos.group.v1.MsgCreateGroupPolicy
/cosmos.group.v1.MsgUpdateGroupDecisionPolicy
/cosmos.group.v1.MsgUpdateGroupPolicyMetadata
/cosmos.group.v1.ThresholdDecisionPolicy
/cosmos.group.v1.PercentageDecisionPolicy

// Manage group
/cosmos.group.v1.MsgCreateGroup
/cosmos.group.v1.MsgUpdateGroupMembers
/cosmos.group.v1.MsgUpdateGroupAdmin
/cosmos.group.v1.MsgUpdateGroupPolicyAdmin
/cosmos.group.v1.MsgUpdateGroupMetadata
/cosmos.group.v1.MsgLeaveGroup

// Proposal and voting
/cosmos.group.v1.MsgSubmitProposal
/cosmos.group.v1.MsgWithdrawProposal
/cosmos.group.v1.MsgVote
/cosmos.group.v1.MsgExec

Note

The pattern that is recommended is to have a single master group policy for a given group, and then to create separate group policies with different decision policies and delegate the desired permissions from the master account to those "sub-accounts" using the x/authz module.

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

2 participants