Versions in this module Expand all Collapse all v1 v1.0.0 Sep 27, 2024 Changes in this version + const AttributeKeyOption + const AttributeKeyProposalID + const AttributeKeyProposalMessages + const AttributeKeyProposalResult + const AttributeKeyProposalType + const AttributeKeyVoter + const AttributeKeyVotingPeriodStart + const AttributeSignalDescription + const AttributeSignalTitle + const AttributeValueProposalDropped + const AttributeValueProposalFailed + const AttributeValueProposalPassed + const AttributeValueProposalQuorumCheckSkipped + const AttributeValueProposalQuorumMet + const AttributeValueProposalQuorumNotMet + const AttributeValueProposalRejected + const EventTypeActiveProposal + const EventTypeInactiveProposal + const EventTypeProposalDeposit + const EventTypeProposalVote + const EventTypeQuorumCheck + const EventTypeSignalProposal + const EventTypeSubmitProposal + const ModuleName + const RouterKey + const StoreKey + var ActiveProposalQueuePrefix = []byte + var DepositsKeyPrefix = []byte + var ErrAlreadyActiveProposal = sdkerrors.Register(ModuleName, 40, "proposal already active") + var ErrInactiveProposal = sdkerrors.Register(ModuleName, 30, "inactive proposal") + var ErrInvalidConstitutionAmendment = sdkerrors.Register(ModuleName, 170, "invalid constitution amendment") + var ErrInvalidGenesis = sdkerrors.Register(ModuleName, 80, "invalid genesis state") + var ErrInvalidProposalContent = sdkerrors.Register(ModuleName, 50, "invalid proposal content") + var ErrInvalidProposalMsg = sdkerrors.Register(ModuleName, 120, "invalid proposal message") + var ErrInvalidProposalType = sdkerrors.Register(ModuleName, 60, "invalid proposal type") + var ErrInvalidSignalMsg = sdkerrors.Register(ModuleName, 140, "signal message is invalid") + var ErrInvalidSigner = sdkerrors.Register(ModuleName, 130, "expected gov account as only signer for proposal message") + var ErrInvalidVote = sdkerrors.Register(ModuleName, 70, "invalid vote option") + var ErrMetadataTooLong = sdkerrors.Register(ModuleName, 150, "metadata too long") + var ErrMinDepositTooSmall = sdkerrors.Register(ModuleName, 160, "minimum deposit is too small") + var ErrNoProposalHandlerExists = sdkerrors.Register(ModuleName, 90, "no handler exists for proposal type") + var ErrNoProposalMsgs = sdkerrors.Register(ModuleName, 110, "no messages proposed") + var ErrUnknownProposal = sdkerrors.Register(ModuleName, 20, "unknown proposal") + var ErrUnroutableProposalMsg = sdkerrors.Register(ModuleName, 100, "proposal message not recognized by router") + var InactiveProposalQueuePrefix = []byte + var KeyConstitution = []byte + var ParamsKey = []byte + var ProposalIDKey = []byte + var ProposalsKeyPrefix = []byte + var QuorumCheckQueuePrefix = []byte + var VotesKeyPrefix = []byte + var VotingPeriodProposalKeyPrefix = []byte + func ActiveProposalByTimeKey(endTime time.Time) []byte + func ActiveProposalQueueKey(proposalID uint64, endTime time.Time) []byte + func ApplyUnifiedDiff(src, diffStr string) (string, error) + func DepositKey(proposalID uint64, depositorAddr sdk.AccAddress) []byte + func DepositsKey(proposalID uint64) []byte + func GetProposalIDBytes(proposalID uint64) (proposalIDBz []byte) + func GetProposalIDFromBytes(bz []byte) (proposalID uint64) + func InactiveProposalByTimeKey(endTime time.Time) []byte + func InactiveProposalQueueKey(proposalID uint64, endTime time.Time) []byte + func ProposalKey(proposalID uint64) []byte + func QuorumCheckByTimeKey(endTime time.Time) []byte + func QuorumCheckQueueKey(proposalID uint64, endTime time.Time) []byte + func SplitActiveProposalQueueKey(key []byte) (proposalID uint64, endTime time.Time) + func SplitInactiveProposalQueueKey(key []byte) (proposalID uint64, endTime time.Time) + func SplitKeyDeposit(key []byte) (proposalID uint64, depositorAddr sdk.AccAddress) + func SplitKeyVote(key []byte) (proposalID uint64, voterAddr sdk.AccAddress) + func SplitProposalKey(key []byte) (proposalID uint64) + func SplitQuorumQueueKey(key []byte) (proposalID uint64, endTime time.Time) + func VoteKey(proposalID uint64, voterAddr sdk.AccAddress) []byte + func VotesKey(proposalID uint64) []byte + func VotingPeriodProposalKey(proposalID uint64) []byte + type AccountKeeper interface + GetAccount func(ctx sdk.Context, addr sdk.AccAddress) types.AccountI + GetModuleAccount func(ctx sdk.Context, name string) types.ModuleAccountI + GetModuleAddress func(name string) sdk.AccAddress + SetModuleAccount func(sdk.Context, types.ModuleAccountI) + type BankKeeper interface + BurnCoins func(ctx sdk.Context, name string, amt sdk.Coins) error + GetAllBalances func(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + GetBalance func(ctx sdk.Context, addr sdk.AccAddress, denom string) sdk.Coin + LockedCoins func(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + SendCoinsFromAccountToModule func(ctx sdk.Context, senderAddr sdk.AccAddress, recipientModule string, ...) error + SendCoinsFromModuleToAccount func(ctx sdk.Context, senderModule string, recipientAddr sdk.AccAddress, ...) error + SpendableCoins func(ctx sdk.Context, addr sdk.AccAddress) sdk.Coins + type Config struct + MaxMetadataLen uint64 + func DefaultConfig() Config + type GovHooks interface + AfterProposalDeposit func(ctx sdk.Context, proposalID uint64, depositorAddr sdk.AccAddress) + AfterProposalFailedMinDeposit func(ctx sdk.Context, proposalID uint64) + AfterProposalSubmission func(ctx sdk.Context, proposalID uint64) + AfterProposalVote func(ctx sdk.Context, proposalID uint64, voterAddr sdk.AccAddress) + AfterProposalVotingPeriodEnded func(ctx sdk.Context, proposalID uint64) + type GovHooksWrapper struct + func (GovHooksWrapper) IsOnePerModuleType() + type Hunk struct + DstLine int + DstSpan int + Lines []string + SrcLine int + SrcSpan int + func ParseUnifiedDiff(diffStr string) ([]Hunk, error) + type MultiGovHooks []GovHooks + func NewMultiGovHooks(hooks ...GovHooks) MultiGovHooks + func (h MultiGovHooks) AfterProposalDeposit(ctx sdk.Context, proposalID uint64, depositorAddr sdk.AccAddress) + func (h MultiGovHooks) AfterProposalFailedMinDeposit(ctx sdk.Context, proposalID uint64) + func (h MultiGovHooks) AfterProposalSubmission(ctx sdk.Context, proposalID uint64) + func (h MultiGovHooks) AfterProposalVote(ctx sdk.Context, proposalID uint64, voterAddr sdk.AccAddress) + func (h MultiGovHooks) AfterProposalVotingPeriodEnded(ctx sdk.Context, proposalID uint64) + type ParamSubspace interface + Get func(ctx sdk.Context, key []byte, ptr interface{}) + Set func(ctx sdk.Context, key []byte, param interface{}) + type ProposalMetadata struct + Authors []string + Details string + ProposalForumUrl string + Summary string + Title string + VoteOptionContext string + type StakingKeeper interface + IterateBondedValidatorsByPower func(sdk.Context, func(index int64, validator stakingtypes.ValidatorI) (stop bool)) + IterateDelegations func(ctx sdk.Context, delegator sdk.AccAddress, ...) + TotalBondedTokens func(sdk.Context) math.Int