Documentation
¶
Index ¶
- Constants
- func GenDowntimeJailDuration(r *rand.Rand) time.Duration
- func GenMinSignedPerWindow(r *rand.Rand) math.LegacyDec
- func GenSignedBlocksWindow(r *rand.Rand) int64
- func GenSlashFractionDoubleSign(r *rand.Rand) math.LegacyDec
- func GenSlashFractionDowntime(r *rand.Rand) math.LegacyDec
- func NewDecodeStore(cdc codec.BinaryCodec) func(kvA, kvB kv.Pair) string
- func ProposalMsgs() []simtypes.WeightedProposalMsg
- func RandomizedGenState(simState *module.SimulationState)
- func SimulateMsgUnjail(cdc *codec.ProtoCodec, txGen client.TxConfig, ak types.AccountKeeper, ...) simtypes.Operation
- func SimulateMsgUpdateParams(r *rand.Rand, _ sdk.Context, _ []simtypes.Account) sdk.Msg
- func WeightedOperations(registry codectypes.InterfaceRegistry, appParams simtypes.AppParams, ...) simulation.WeightedOperations
Constants ¶
const ( SignedBlocksWindow = "signed_blocks_window" MinSignedPerWindow = "min_signed_per_window" DowntimeJailDuration = "downtime_jail_duration" SlashFractionDoubleSign = "slash_fraction_double_sign" SlashFractionDowntime = "slash_fraction_downtime" )
Simulation parameter constants
const ( OpWeightMsgUnjail = "op_weight_msg_unjail" DefaultWeightMsgUnjail = 100 )
Simulation operation weights constants
const ( DefaultWeightMsgUpdateParams int = 100 OpWeightMsgUpdateParams = "op_weight_msg_update_params" )
Simulation operation weights constants
Variables ¶
This section is empty.
Functions ¶
func GenDowntimeJailDuration ¶ added in v0.50.9
GenDowntimeJailDuration randomized DowntimeJailDuration
func GenMinSignedPerWindow ¶ added in v0.50.9
GenMinSignedPerWindow randomized MinSignedPerWindow
func GenSignedBlocksWindow ¶ added in v0.50.9
GenSignedBlocksWindow randomized SignedBlocksWindow
func GenSlashFractionDoubleSign ¶ added in v0.50.9
GenSlashFractionDoubleSign randomized SlashFractionDoubleSign
func GenSlashFractionDowntime ¶ added in v0.50.9
GenSlashFractionDowntime randomized SlashFractionDowntime
func NewDecodeStore ¶ added in v0.50.9
func NewDecodeStore(cdc codec.BinaryCodec) func(kvA, kvB kv.Pair) string
NewDecodeStore returns a decoder function closure that unmarshals the KVPair's Value to the corresponding slashing type.
func ProposalMsgs ¶ added in v0.50.9
func ProposalMsgs() []simtypes.WeightedProposalMsg
ProposalMsgs defines the module weighted proposals' contents
func RandomizedGenState ¶ added in v0.50.9
func RandomizedGenState(simState *module.SimulationState)
RandomizedGenState generates a random GenesisState for slashing
func SimulateMsgUnjail ¶ added in v0.25.0
func SimulateMsgUnjail( cdc *codec.ProtoCodec, txGen client.TxConfig, ak types.AccountKeeper, bk types.BankKeeper, k keeper.Keeper, sk types.StakingKeeper, ) simtypes.Operation
SimulateMsgUnjail generates a MsgUnjail with random values
func SimulateMsgUpdateParams ¶ added in v0.50.9
SimulateMsgUpdateParams returns a random MsgUpdateParams
func WeightedOperations ¶ added in v0.50.9
func WeightedOperations( registry codectypes.InterfaceRegistry, appParams simtypes.AppParams, cdc codec.JSONCodec, txGen client.TxConfig, ak types.AccountKeeper, bk types.BankKeeper, k keeper.Keeper, sk types.StakingKeeper, ) simulation.WeightedOperations
WeightedOperations returns all the operations from the module with their respective weights
Types ¶
This section is empty.