chore: typos fixes by cosmos-sdk bot (#18689)

Co-authored-by: github-merge-queue <github-merge-queue@users.noreply.github.com>
Co-authored-by: Julien Robert <julien@rbrt.fr>
Co-authored-by: marbar3778 <marbar3778@yahoo.com>
This commit is contained in:
Cosmos SDK 2023-12-11 14:03:19 +01:00 committed by GitHub
parent 39865d852f
commit 8f0d5b15f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
113 changed files with 195 additions and 202 deletions

View File

@ -1,5 +1,4 @@
cips
pullrequest
keypair
stStr
pastTime

View File

@ -45,7 +45,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (client) [#18101](https://github.com/cosmos/cosmos-sdk/pull/18101) Add a `keyring-default-keyname` in `client.toml` for specifying a default key name, and skip the need to use the `--from` flag when signing transactions.
* (tests) [#17868](https://github.com/cosmos/cosmos-sdk/pull/17868) Added helper method `SubmitTestTx` in testutil to broadcast test txns to test e2e tests.
* (x/protocolpool) [#17657](https://github.com/cosmos/cosmos-sdk/pull/17657) Create a new `x/protocolpool` module that is responsible for handling community pool funds. This module is split out into a new module from x/distribution.
* (client) [#17513](https://github.com/cosmos/cosmos-sdk/pull/17513) Allow overwritting `client.toml`. Use `client.CreateClientConfig` in place of `client.ReadFromClientConfig` and provide a custom template and a custom config.
* (client) [#17513](https://github.com/cosmos/cosmos-sdk/pull/17513) Allow overwriting `client.toml`. Use `client.CreateClientConfig` in place of `client.ReadFromClientConfig` and provide a custom template and a custom config.
* (x/bank) [#17569](https://github.com/cosmos/cosmos-sdk/pull/17569) Introduce a new message type, `MsgBurn`, to burn coins.
* (x/auth/vesting) [#17810](https://github.com/cosmos/cosmos-sdk/pull/17810) Add the ability to specify a start time for continuous vesting accounts.
* (runtime) [#18475](https://github.com/cosmos/cosmos-sdk/pull/18475) Adds an implementation for core.branch.Service.
@ -155,7 +155,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (x/staking) [#17655](https://github.com/cosmos/cosmos-sdk/pull/17655) `QueryHistoricalInfo` was adjusted to return `HistoricalRecord` and marked `Hist` as deprecated.
* (types) [#17885](https://github.com/cosmos/cosmos-sdk/pull/17885) `InitGenesis` & `ExportGenesis` now take `context.Context` instead of `sdk.Context`
* (x/auth) [#17985](https://github.com/cosmos/cosmos-sdk/pull/17985) Remove `StdTxConfig`
* Remove depreacted `MakeTestingEncodingParams` from `simapp/params`
* Remove deprecated `MakeTestingEncodingParams` from `simapp/params`
* (x/group) [#17937](https://github.com/cosmos/cosmos-sdk/pull/17937) Groups module was moved to its own go.mod `cosmossdk.io/x/group`
* (x/gov) [#18197](https://github.com/cosmos/cosmos-sdk/pull/18197) Gov module was moved to its own go.mod `cosmossdk.io/x/gov`
* (x/distribution) [#18199](https://github.com/cosmos/cosmos-sdk/pull/18199) Distribution module was moved to its own go.mod `cosmossdk.io/x/distribution`
@ -276,7 +276,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (cli) [#16206](https://github.com/cosmos/cosmos-sdk/pull/16206) Make ABCI handshake profileable.
* (types) [#16076](https://github.com/cosmos/cosmos-sdk/pull/16076) Optimize `ChainAnteDecorators`/`ChainPostDecorators` to instantiate the functions once instead of on every invocation of the returned `AnteHandler`/`PostHandler`.
* (server) [#16071](https://github.com/cosmos/cosmos-sdk/pull/16071) When `mempool.max-txs` is set to a negative value, use a no-op mempool (effectively disable the app mempool).
* (types/query) [#16041](https://github.com/cosmos/cosmos-sdk/pull/16041) Change pagination max limit to a variable in order to be modifed by application devs.
* (types/query) [#16041](https://github.com/cosmos/cosmos-sdk/pull/16041) Change pagination max limit to a variable in order to be modified by application devs.
* (simapp) [#15958](https://github.com/cosmos/cosmos-sdk/pull/15958) Refactor SimApp for removing the global basic manager.
* (all modules) [#15901](https://github.com/cosmos/cosmos-sdk/issues/15901) All core Cosmos SDK modules query commands have migrated to [AutoCLI](https://docs.cosmos.network/main/core/autocli), ensuring parity between gRPC and CLI queries.
* (x/auth) [#15867](https://github.com/cosmos/cosmos-sdk/pull/15867) Support better logging for signature verification failure.
@ -303,7 +303,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (store) [#14439](https://github.com/cosmos/cosmos-sdk/pull/14439) Remove global metric gatherer from store.
* By default store has a no op metric gatherer, the application developer must set another metric gatherer or us the provided one in `store/metrics`.
* (store) [#14438](https://github.com/cosmos/cosmos-sdk/pull/14438) Pass logger from baseapp to store.
* (baseapp) [#14417](https://github.com/cosmos/cosmos-sdk/pull/14417) The store pacakge no longer has a dependency on baseapp.
* (baseapp) [#14417](https://github.com/cosmos/cosmos-sdk/pull/14417) The store package no longer has a dependency on baseapp.
* (module) [#14415](https://github.com/cosmos/cosmos-sdk/pull/14415) Loosen assertions in SetOrderBeginBlockers() and SetOrderEndBlockers().
* (store) [#14410](https://github.com/cosmos/cosmos-sdk/pull/14410) `rootmulti.Store.loadVersion` has validation to check if all the module stores' height is correct, it will error if any module store has incorrect height.
* [#14406](https://github.com/cosmos/cosmos-sdk/issues/14406) Migrate usage of `types/store.go` to `store/types/..`.
@ -353,7 +353,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (x/auth) [#16650](https://github.com/cosmos/cosmos-sdk/pull/16650) The *cli testutil* `QueryAccountExec` has been removed. Use the gRPC or REST query instead.
* (x/auth) [#16621](https://github.com/cosmos/cosmos-sdk/pull/16621) Pass address codec to auth new keeper constructor.
* (x/auth) [#16423](https://github.com/cosmos/cosmos-sdk/pull/16423) `helpers.AddGenesisAccount` has been moved to `x/genutil` to remove the cyclic dependency between `x/auth` and `x/genutil`.
* (baseapp) [#16342](https://github.com/cosmos/cosmos-sdk/pull/16342) NewContext was renamed to NewContextLegacy. The replacement (NewContext) now does not take a header, instead you should set the header via `WithHeaderInfo` or `WithBlockHeight`. Note that `WithBlockHeight` will soon be depreacted and its recommneded to use `WithHeaderInfo`.
* (baseapp) [#16342](https://github.com/cosmos/cosmos-sdk/pull/16342) NewContext was renamed to NewContextLegacy. The replacement (NewContext) now does not take a header, instead you should set the header via `WithHeaderInfo` or `WithBlockHeight`. Note that `WithBlockHeight` will soon be deprecated and its recommended to use `WithHeaderInfo`.
* (x/mint) [#16329](https://github.com/cosmos/cosmos-sdk/pull/16329) Use collections for state management:
* Removed: keeper `GetParams`, `SetParams`, `GetMinter`, `SetMinter`.
* (x/crisis) [#16328](https://github.com/cosmos/cosmos-sdk/pull/16328) Use collections for state management:
@ -386,7 +386,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (x/gov) [#16127](https://github.com/cosmos/cosmos-sdk/pull/16127) Use collections for deposit state management:
* The following methods are removed from the gov keeper: `GetDeposit`, `GetAllDeposits`, `IterateAllDeposits`.
* The following functions are removed from the gov types: `DepositKey`, `DepositsKey`.
* (x/gov) [#16118](https://github.com/cosmos/cosmos-sdk/pull/16118/) Use collections for constituion and params state management.
* (x/gov) [#16118](https://github.com/cosmos/cosmos-sdk/pull/16118/) Use collections for constitution and params state management.
* (x/gov) [#16106](https://github.com/cosmos/cosmos-sdk/pull/16106) Remove gRPC query methods from gov keeper.
* (x/*all*) [#16052](https://github.com/cosmos/cosmos-sdk/pull/16062) `GetSignBytes` implementations on messages and global legacy amino codec definitions have been removed from all modules.
* (sims) [#16052](https://github.com/cosmos/cosmos-sdk/pull/16062) `GetOrGenerate` no longer requires a codec argument is now 4-arity instead of 5-arity.
@ -423,7 +423,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* `MsgSendExec` test helper function now takes a address.Codec
* (x/auth) [#15520](https://github.com/cosmos/cosmos-sdk/pull/15520) `NewAccountKeeper` now takes a `KVStoreService` instead of a `StoreKey` and methods in the `Keeper` now take a `context.Context` instead of a `sdk.Context`.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) `runTxMode`s were renamed to `execMode`. `ModeDeliver` as changed to `ModeFinalize` and a new `ModeVoteExtension` was added for vote extensions.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) Writing of state to the multistore was moved to `FinalizeBlock`. `Commit` still handles the commiting values to disk.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) Writing of state to the multistore was moved to `FinalizeBlock`. `Commit` still handles the committing values to disk.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) Calls to BeginBlock and EndBlock have been replaced with core api beginblock & endblock.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) BeginBlock and EndBlock are now internal to baseapp. For testing, user must call `FinalizeBlock`. BeginBlock and EndBlock calls are internal to Baseapp.
* (baseapp) [#15519](https://github.com/cosmos/cosmos-sdk/pull/15519/files) All calls to ABCI methods now accept a pointer of the abci request and response types
@ -498,7 +498,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* `--count-total` -> `--page-count-total`
* (cli) [#17184](https://github.com/cosmos/cosmos-sdk/pull/17184) All json keys returned by the `status` command are now snake case instead of pascal case.
* (server) [#17177](https://github.com/cosmos/cosmos-sdk/pull/17177) Remove `iavl-lazy-loading` configuration.
* (x/gov) [#16987](https://github.com/cosmos/cosmos-sdk/pull/16987) In `<appd> query gov proposals` the proposal status flag have renamed from `--status` to `--proposal-status`. Additonally, that flags now uses the ENUM values: `PROPOSAL_STATUS_DEPOSIT_PERIOD`, `PROPOSAL_STATUS_VOTING_PERIOD`, `PROPOSAL_STATUS_PASSED`, `PROPOSAL_STATUS_REJECTED`, `PROPOSAL_STATUS_FAILED`.
* (x/gov) [#16987](https://github.com/cosmos/cosmos-sdk/pull/16987) In `<appd> query gov proposals` the proposal status flag have renamed from `--status` to `--proposal-status`. Additionally, that flags now uses the ENUM values: `PROPOSAL_STATUS_DEPOSIT_PERIOD`, `PROPOSAL_STATUS_VOTING_PERIOD`, `PROPOSAL_STATUS_PASSED`, `PROPOSAL_STATUS_REJECTED`, `PROPOSAL_STATUS_FAILED`.
* (x/bank) [#16899](https://github.com/cosmos/cosmos-sdk/pull/16899) With the migration to AutoCLI some bank commands have been split in two:
* Use `total-supply` (or `total`) for querying the total supply and `total-supply-of` for querying the supply of a specific denom.
* Use `denoms-metadata` for querying all denom metadata and `denom-metadata` for querying a specific denom metadata.
@ -608,7 +608,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
### Improvements
* (cli) [#16856](https://github.com/cosmos/cosmos-sdk/pull/16856) Improve `simd prune` UX by using the app default home directory and set pruning method as first variable argument (defaults to default). `pruning.PruningCmd` rest unchanged for API compability, use `pruning.Cmd` instead.
* (cli) [#16856](https://github.com/cosmos/cosmos-sdk/pull/16856) Improve `simd prune` UX by using the app default home directory and set pruning method as first variable argument (defaults to default). `pruning.PruningCmd` rest unchanged for API compatibility, use `pruning.Cmd` instead.
* (testutil) [#16704](https://github.com/cosmos/cosmos-sdk/pull/16704) Make app config configurator for testing configurable with external modules.
* (deps) [#16565](https://github.com/cosmos/cosmos-sdk/pull/16565) Bump CometBFT to [v0.37.2](https://github.com/cometbft/cometbft/blob/v0.37.2/CHANGELOG.md).
@ -617,7 +617,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (x/auth) [#16994](https://github.com/cosmos/cosmos-sdk/pull/16994) Fix regression where querying transactions events with `<=` or `>=` would not work.
* (server) [#16827](https://github.com/cosmos/cosmos-sdk/pull/16827) Properly use `--trace` flag (before it was setting the trace level instead of displaying the stacktraces).
* (x/auth) [#16554](https://github.com/cosmos/cosmos-sdk/pull/16554) `ModuleAccount.Validate` now reports a nil `.BaseAccount` instead of panicking.
* [#16588](https://github.com/cosmos/cosmos-sdk/pull/16588) Propogate snapshotter failures to the caller, (it would create an empty snapshot silently before).
* [#16588](https://github.com/cosmos/cosmos-sdk/pull/16588) Propagate snapshotter failures to the caller, (it would create an empty snapshot silently before).
* (x/slashing) [#16784](https://github.com/cosmos/cosmos-sdk/pull/16784) Emit event with the correct reason in `SlashWithInfractionReason`.
## [v0.47.3](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.47.3) - 2023-06-08
@ -709,7 +709,7 @@ Ref: https://keepachangelog.com/en/1.0.0/
* (x/genutil) [#14149](https://github.com/cosmos/cosmos-sdk/pull/14149) Add `genutilcli.GenesisCoreCommand` command, which contains all genesis-related sub-commands.
* (x/evidence) [#13740](https://github.com/cosmos/cosmos-sdk/pull/13740) Add new proto field `hash` of type `string` to `QueryEvidenceRequest` which helps to decode the hash properly while using query API.
* (core) [#13306](https://github.com/cosmos/cosmos-sdk/pull/13306) Add a `FormatCoins` function to in `core/coins` to format sdk Coins following the Value Renderers spec.
* (math) [#13306](https://github.com/cosmos/cosmos-sdk/pull/13306) Add `FormatInt` and `FormatDec` functiosn in `math` to format integers and decimals following the Value Renderers spec.
* (math) [#13306](https://github.com/cosmos/cosmos-sdk/pull/13306) Add `FormatInt` and `FormatDec` functions in `math` to format integers and decimals following the Value Renderers spec.
* (x/staking) [#13122](https://github.com/cosmos/cosmos-sdk/pull/13122) Add `UnbondingCanComplete` and `PutUnbondingOnHold` to `x/staking` module.
* [#13437](https://github.com/cosmos/cosmos-sdk/pull/13437) Add new flag `--modules-to-export` in `simd export` command to export only selected modules.
* [#13298](https://github.com/cosmos/cosmos-sdk/pull/13298) Add `AddGenesisAccount` helper func in x/auth module which helps adding accounts to genesis state.
@ -953,14 +953,14 @@ EOL notice. This is the last release of the `v0.46.x` line. Per this version, th
### Improvements
* (cli) [#16856](https://github.com/cosmos/cosmos-sdk/pull/16856) Improve `simd prune` UX by using the app default home directory and set pruning method as first variable argument (defaults to default). `pruning.PruningCmd` rest unchanged for API compability, use `pruning.Cmd` instead.
* (cli) [#16856](https://github.com/cosmos/cosmos-sdk/pull/16856) Improve `simd prune` UX by using the app default home directory and set pruning method as first variable argument (defaults to default). `pruning.PruningCmd` rest unchanged for API compatibility, use `pruning.Cmd` instead.
* (deps) [#16553](https://github.com/cosmos/cosmos-sdk/pull/16553) Bump CometBFT to [v0.34.29](https://github.com/cometbft/cometbft/blob/v0.34.29/CHANGELOG.md#v03429).
### Bug Fixes
* (x/auth) [#16994](https://github.com/cosmos/cosmos-sdk/pull/16994) Fix regression where querying transactions events with `<=` or `>=` would not work.
* (x/auth) [#16554](https://github.com/cosmos/cosmos-sdk/pull/16554) `ModuleAccount.Validate` now reports a nil `.BaseAccount` instead of panicking.
* [#16588](https://github.com/cosmos/cosmos-sdk/pull/16588) Propogate snapshotter failures to the caller, (it would create an empty snapshot silently before).
* [#16588](https://github.com/cosmos/cosmos-sdk/pull/16588) Propagate snapshotter failures to the caller, (it would create an empty snapshot silently before).
* (types) [#15433](https://github.com/cosmos/cosmos-sdk/pull/15433) Allow disabling of account address caches (for printing bech32 account addresses).
## [v0.46.13](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.46.13) - 2023-06-08
@ -1025,7 +1025,7 @@ EOL notice. This is the last release of the `v0.46.x` line. Per this version, th
* (deps) [#14846](https://github.com/cosmos/cosmos-sdk/pull/14846) Bump btcd.
* (deps) Bump Tendermint version to [v0.34.26](https://github.com/informalsystems/tendermint/releases/tag/v0.34.26).
* (store/cache) [#14189](https://github.com/cosmos/cosmos-sdk/pull/14189) Add config `iavl-lazy-loading` to enable lazy loading of iavl store, to improve start up time of archive nodes, add method `SetLazyLoading` to `CommitMultiStore` interface.
* A new field has been added to the app.toml. This alllows nodes with larger databases to startup quicker
* A new field has been added to the app.toml. This allows nodes with larger databases to startup quicker
```toml
# IAVLLazyLoading enable/disable the lazy loading of iavl store.
@ -1617,7 +1617,7 @@ replace github.com/confio/ics23/go => github.com/cosmos/cosmos-sdk/ics23/go v0.8
### Bug Fixes
* [#13588](https://github.com/cosmos/cosmos-sdk/pull/13588) Fix regression in distrubtion.WithdrawDelegationRewards when rewards are zero.
* [#13588](https://github.com/cosmos/cosmos-sdk/pull/13588) Fix regression in distribution.WithdrawDelegationRewards when rewards are zero.
* [#13564](https://github.com/cosmos/cosmos-sdk/pull/13564) - Fix `make proto-gen`.
* (server) [#13610](https://github.com/cosmos/cosmos-sdk/pull/13610) Read the pruning-keep-every field again.
@ -1645,7 +1645,7 @@ replace github.com/confio/ics23/go => github.com/cosmos/cosmos-sdk/ics23/go v0.8
* [#13323](https://github.com/cosmos/cosmos-sdk/pull/13323) Ensure `withdraw_rewards` rewards are emitted from all actions that result in rewards being withdrawn.
* [#13321](https://github.com/cosmos/cosmos-sdk/pull/13321) Add flag to disable fast node migration and usage.
* (store) [#13326](https://github.com/cosmos/cosmos-sdk/pull/13326) Implementation of ADR-038 file StreamingService, backport #8664.
* (store) [#13540](https://github.com/cosmos/cosmos-sdk/pull/13540) Default fastnode migration to false to prevent suprises. Operators must enable it, unless they have it enabled already.
* (store) [#13540](https://github.com/cosmos/cosmos-sdk/pull/13540) Default fastnode migration to false to prevent surprises. Operators must enable it, unless they have it enabled already.
### API Breaking Changes
@ -2356,7 +2356,7 @@ he Cosmos Hub) should not use this release or any release in the v0.41.x series.
* (x/ibc) [#8458](https://github.com/cosmos/cosmos-sdk/pull/8458) Add `packet_connection` attribute to ibc events to enable relayer filtering
* [#8396](https://github.com/cosmos/cosmos-sdk/pull/8396) Add support for ARM platform
* (x/bank) [#8479](https://github.com/cosmos/cosmos-sdk/pull/8479) Aditional client denom metadata validation for `base` and `display` denoms.
* (x/bank) [#8479](https://github.com/cosmos/cosmos-sdk/pull/8479) Additional client denom metadata validation for `base` and `display` denoms.
* (codec/types) [#8605](https://github.com/cosmos/cosmos-sdk/pull/8605) Avoid unnecessary allocations for NewAnyWithCustomTypeURL on error.
## [v0.41.0](https://github.com/cosmos/cosmos-sdk/releases/tag/v0.41.0) - 2021-01-26
@ -2479,7 +2479,7 @@ sure you are aware of any relevant breaking changes.
The `PruningOptions` type now only includes fields `KeepEvery` and `SnapshotEvery`, where `KeepEvery`
determines which committed heights are flushed to disk and `SnapshotEvery` determines which of these
heights are kept after pruning. The `IsValid` method should be called whenever using these options. Methods
`SnapshotVersion` and `FlushVersion` accept a version arugment and determine if the version should be
`SnapshotVersion` and `FlushVersion` accept a version argument and determine if the version should be
flushed to disk or kept as a snapshot. Note, `KeepRecent` is automatically inferred from the options
and provided directly the IAVL store.
* (types) [#5533](https://github.com/cosmos/cosmos-sdk/pull/5533) Refactored `AppModuleBasic` and `AppModuleGenesis`

View File

@ -102,7 +102,7 @@ When testing a function under a variety of different inputs, we prefer to use
[table driven tests](https://github.com/golang/go/wiki/TableDrivenTests).
Table driven test error messages should follow the following format
`<desc>, tc #<index>, i #<index>`.
`<desc>` is an optional short description of whats failing, `tc` is the
`<desc>` is an optional short description of what's failing, `tc` is the
index within the test case table that is failing, and `i` is when there
is a loop, exactly which iteration of the loop failed.
The idea is you should be able to see the

View File

@ -206,7 +206,7 @@ The **Stable Release Managers** evaluate and approve or reject updates and backp
according to the [stable release policy](#stable-release-policy) and [release procedure](#major-release-procedure).
Decisions are made by consensus.
Their responsibilites include:
Their responsibilities include:
* Driving the Stable Release Exception process.
* Approving/rejecting proposed changes to a stable release series.
@ -235,7 +235,7 @@ Note: The Cosmos SDK team is in an active process of limiting Go modules that de
The Cosmos SDK team should strive to release modules that depend on the Cosmos SDK at the same time or soon after a major version Cosmos SDK itself.
Those modules can be considered as part of the Cosmos SDK, but features and improvements are released at a different cadence.
* When a module is supposed to be used in an app (e.g `x/` modules), due to the dependency on the SDK, tagging a new version of a module must be done from a Cosmos SDK release branch. A compability matrix must be provided in the `README.md` of that module with the corresponding versions.
* When a module is supposed to be used in an app (e.g `x/` modules), due to the dependency on the SDK, tagging a new version of a module must be done from a Cosmos SDK release branch. A compatibility matrix must be provided in the `README.md` of that module with the corresponding versions.
* Modules that import the SDK but do not need to be imported in an app (`e.g. cosmovisor`) must be released from the `main` branch and follow the process defined below.
### Modules that do not depend on the Cosmos SDK

View File

@ -116,7 +116,7 @@ Issue: https://github.com/cosmos/iavl/issues/548
* Users should be able to pick between delayed execution and optimistic
* RFC/ADR is merged
* Implementation started.
* Progess:
* Progress:
* On pause till ABCI 2.0 is merged
### Client UX
@ -159,14 +159,14 @@ Issue: https://github.com/cosmos/iavl/issues/548
* KvStoreService is being added to all modules
* [ ] [Remove global bech32](https://github.com/cosmos/cosmos-sdk/issues/13140)
* Objective:
* Depreacte global bech32 setting
* Deprecate global bech32 setting
* Progress:
* All modules except bank use the `address.Codec`
* [ ] Make sdk.Msg only be `proto.message`
* Objectives:
* Reduce sdk.Msg to only be proto.message
* Reduce boilerplate in `msgs.go`
* Progess:
* Progress:
* [x] [Make ValidateBasic Optional](https://github.com/cosmos/cosmos-sdk/issues/15648)
* [ ] [Make GetSigners be optional](https://github.com/cosmos/cosmos-sdk/issues/15677)
* [ ] Remove GetsignBytes for legacy amino encoding

View File

@ -1130,7 +1130,7 @@ type EventGrant struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Msg type URL for which an autorization is granted
// Msg type URL for which an authorization is granted
MsgTypeUrl string `protobuf:"bytes,2,opt,name=msg_type_url,json=msgTypeUrl,proto3" json:"msg_type_url,omitempty"`
// Granter account address
Granter string `protobuf:"bytes,3,opt,name=granter,proto3" json:"granter,omitempty"`
@ -1185,7 +1185,7 @@ type EventRevoke struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Msg type URL for which an autorization is revoked
// Msg type URL for which an authorization is revoked
MsgTypeUrl string `protobuf:"bytes,2,opt,name=msg_type_url,json=msgTypeUrl,proto3" json:"msg_type_url,omitempty"`
// Granter account address
Granter string `protobuf:"bytes,3,opt,name=granter,proto3" json:"granter,omitempty"`

View File

@ -12271,7 +12271,7 @@ type AppDescriptor struct {
Codec *CodecDescriptor `protobuf:"bytes,3,opt,name=codec,proto3" json:"codec,omitempty"`
// configuration provides metadata information regarding the sdk.Config type
Configuration *ConfigurationDescriptor `protobuf:"bytes,4,opt,name=configuration,proto3" json:"configuration,omitempty"`
// query_services provides metadata information regarding the available queriable endpoints
// query_services provides metadata information regarding the available queryable endpoints
QueryServices *QueryServicesDescriptor `protobuf:"bytes,5,opt,name=query_services,json=queryServices,proto3" json:"query_services,omitempty"`
// tx provides metadata information regarding how to send transactions to the given application
Tx *TxDescriptor `protobuf:"bytes,6,opt,name=tx,proto3" json:"tx,omitempty"`
@ -13171,7 +13171,7 @@ func (x *GetTxDescriptorResponse) GetTx() *TxDescriptor {
return nil
}
// QueryServicesDescriptor contains the list of cosmos-sdk queriable services
// QueryServicesDescriptor contains the list of cosmos-sdk queryable services
type QueryServicesDescriptor struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache

View File

@ -38,7 +38,7 @@ var (
// algorithm used to generate the custom textual representation of the
// protobuf message where this annotation is applied. We recommend to use a
// short, versioned name as this identifier, e.g. "replace_with_username_v1".
// We also recommand providing a human-readable description as protobuf
// We also recommend providing a human-readable description as protobuf
// comments on this annotation, for example a short specification or a link
// to the relevant documentation.
//

View File

@ -14953,7 +14953,7 @@ type Validator struct {
MinSelfDelegation string `protobuf:"bytes,11,opt,name=min_self_delegation,json=minSelfDelegation,proto3" json:"min_self_delegation,omitempty"`
// strictly positive if this validator's unbonding has been stopped by external modules
UnbondingOnHoldRefCount int64 `protobuf:"varint,12,opt,name=unbonding_on_hold_ref_count,json=unbondingOnHoldRefCount,proto3" json:"unbonding_on_hold_ref_count,omitempty"`
// list of unbonding ids, each uniquely identifing an unbonding of this validator
// list of unbonding ids, each uniquely identifying an unbonding of this validator
UnbondingIds []uint64 `protobuf:"varint,13,rep,packed,name=unbonding_ids,json=unbondingIds,proto3" json:"unbonding_ids,omitempty"`
}

View File

@ -33273,7 +33273,7 @@ type ResponseFinalizeBlock struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// set of block events emmitted as part of executing the block
// set of block events emitted as part of executing the block
Events []*Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
// the result of executing each transaction including the events
// the particular transction emitted. This should match the order

View File

@ -2919,7 +2919,7 @@ func (x *DominoOp) GetOutput() string {
}
// ProofOp defines an operation used for calculating Merkle root
// The data could be arbitrary format, providing nessecary data
// The data could be arbitrary format, providing necessary data
// for example neighbouring node hash
type ProofOp struct {
state protoimpl.MessageState

View File

@ -889,7 +889,7 @@ func (app *BaseApp) FinalizeBlock(req *abci.RequestFinalizeBlock) (*abci.Respons
return res, err
}
// checkHalt checkes if height or time exceeds halt-height or halt-time respectively.
// checkHalt checks if height or time exceeds halt-height or halt-time respectively.
func (app *BaseApp) checkHalt(height int64, time time.Time) error {
var halt bool
switch {

View File

@ -153,7 +153,7 @@ type BaseApp struct {
// ResponseCommit.RetainHeight value during ABCI Commit. A value of 0 indicates
// that no blocks should be pruned.
//
// Note: CometBFT block pruning is dependant on this parameter in conjunction
// Note: CometBFT block pruning is dependent on this parameter in conjunction
// with the unbonding (safety threshold) period, state pruning and state sync
// snapshot parameters to determine the correct minimum value of
// ResponseCommit.RetainHeight.

View File

@ -82,7 +82,7 @@ func TestCustomTemplateAndConfig(t *testing.T) {
customClientConfigTemplate := config.DefaultClientConfigTemplate + `
# This is the gas adjustment factor used by the tx commands.
# Sets the default and can be overwriten by the --gas-adjustment flag in tx commands.
# Sets the default and can be overwritten by the --gas-adjustment flag in tx commands.
gas-adjustment = {{ .GasConfig.GasAdjustment }}
# Memo to include in all transactions.
note = "{{ .Note }}"

View File

@ -79,7 +79,7 @@ func getCodecInterfaces() *cobra.Command {
}
}
// getCodecInterfaceImpls creates and returns a new cmd used for listing all registered implemenations of a given interface on the application codec.
// getCodecInterfaceImpls creates and returns a new cmd used for listing all registered implementations of a given interface on the application codec.
func getCodecInterfaceImpls() *cobra.Command {
return &cobra.Command{
Use: "list-implementations [interface]",

View File

@ -14171,7 +14171,7 @@ paths:
vetoed. Default value: 1/3.
params:
description: |-
params defines all the paramaters of x/gov module.
params defines all the parameters of x/gov module.
Since: cosmos-sdk 0.47
type: object
@ -19195,7 +19195,7 @@ paths:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an
list of unbonding ids, each uniquely identifying an
unbonding of this validator
description: >-
Validator defines a validator, together with the total
@ -19819,7 +19819,7 @@ paths:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an
list of unbonding ids, each uniquely identifying an
unbonding of this validator
description: >-
Validator defines a validator, together with the total amount
@ -20458,7 +20458,7 @@ paths:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an
list of unbonding ids, each uniquely identifying an
unbonding of this validator
description: >-
Validator defines a validator, together with the total
@ -21517,7 +21517,7 @@ paths:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an
list of unbonding ids, each uniquely identifying an
unbonding of this validator
description: >-
Validator defines a validator, together with the total
@ -22139,7 +22139,7 @@ paths:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an
list of unbonding ids, each uniquely identifying an
unbonding of this validator
description: >-
Validator defines a validator, together with the total amount
@ -51844,7 +51844,7 @@ definitions:
vetoed. Default value: 1/3.
params:
description: |-
params defines all the paramaters of x/gov module.
params defines all the parameters of x/gov module.
Since: cosmos-sdk 0.47
type: object
@ -53712,7 +53712,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of
list of unbonding ids, each uniquely identifying an unbonding of
this validator
description: >-
Validator defines a validator, together with the total amount of the
@ -54309,7 +54309,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of
list of unbonding ids, each uniquely identifying an unbonding of
this validator
description: >-
Validator defines a validator, together with the total amount of the
@ -54631,7 +54631,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of
list of unbonding ids, each uniquely identifying an unbonding of
this validator
description: >-
Validator defines a validator, together with the total amount of the
@ -55060,7 +55060,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding
list of unbonding ids, each uniquely identifying an unbonding
of this validator
description: >-
Validator defines a validator, together with the total amount of
@ -55747,7 +55747,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of
list of unbonding ids, each uniquely identifying an unbonding of
this validator
description: >-
Validator defines a validator, together with the total amount of the
@ -56145,7 +56145,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of
list of unbonding ids, each uniquely identifying an unbonding of
this validator
description: >-
Validator defines a validator, together with the total amount of the
@ -56813,7 +56813,7 @@ definitions:
type: string
format: uint64
title: >-
list of unbonding ids, each uniquely identifing an unbonding of this
list of unbonding ids, each uniquely identifying an unbonding of this
validator
description: >-
Validator defines a validator, together with the total amount of the

View File

@ -43,7 +43,7 @@ func TestReadLineFromBuf(t *testing.T) {
require.ErrorIs(t, err, io.EOF)
})
t.Run("it returns the error if it's not EOF regardles if it read something or not", func(t *testing.T) {
t.Run("it returns the error if it's not EOF regardless if it read something or not", func(t *testing.T) {
expectedErr := errors.New("oh no")
fr.fnc = func(p []byte) (int, error) {
return copy(p, []byte("hello")), expectedErr

View File

@ -246,7 +246,7 @@ func checkMultipleSigners(tx authsigning.Tx) error {
// Sign signs a given tx with a named key. The bytes signed over are canconical.
// The resulting signature will be added to the transaction builder overwriting the previous
// ones if overwrite=true (otherwise, the signature will be appended).
// Signing a transaction with mutltiple signers in the DIRECT mode is not supprted and will
// Signing a transaction with mutltiple signers in the DIRECT mode is not supported and will
// return an error.
// An error is returned upon failure.
func Sign(ctx context.Context, txf Factory, name string, txBuilder client.TxBuilder, overwriteSig bool) error {

View File

@ -10,7 +10,7 @@ import (
type (
// Codec defines a functionality for serializing other objects.
// Users can defin a custom Protobuf-based serialization.
// Users can define a custom Protobuf-based serialization.
// Note, Amino can still be used without any dependency on Protobuf.
// SDK provides to Codec implementations:
//

View File

@ -604,7 +604,7 @@ we specified in the range.
Then we use again th `Values` method of the `Iterator` to collect all the results.
`collections.Range` also offers a `Prefix` API which is not appliable to all keys types,
`collections.Range` also offers a `Prefix` API which is not applicable to all keys types,
for example uint64 cannot be prefix because it is of constant size, but a `string` key
can be prefixed.
@ -796,7 +796,7 @@ in `Pair` keys iterations.
```
As we can see here we're passing the type parameters of the `collections.Pair` because golang type inference
with respect to generics is not as permissive as other languages, so we need to explitly say what are the types of the pair key.
with respect to generics is not as permissive as other languages, so we need to explicitly say what are the types of the pair key.
#### GetAllAddressesBalancesBetween

View File

@ -124,7 +124,7 @@ func (m mockValueCodec[T]) Decode(b []byte) (t T, err error) {
typ, exists := m.seenTypes[wrappedValue.TypeName]
if !exists {
return t, fmt.Errorf("uknown type %s, you're dealing with interfaces... in order to make the interface types known for the MockValueCodec, you need to first encode them", wrappedValue.TypeName)
return t, fmt.Errorf("unknown type %s, you're dealing with interfaces... in order to make the interface types known for the MockValueCodec, you need to first encode them", wrappedValue.TypeName)
}
newT := reflect.New(typ).Interface()

View File

@ -6,7 +6,7 @@
Cosmos-SDK provides you with a local network to bootstrap a chain in your machine, but how does one debug a node or module?
If we start a single node, we won't be able to debug transactions as the machine will be in bootstrapping phase trying to find peers to connect too, thats why we need to start a local network.
If we start a single node, we won't be able to debug transactions as the machine will be in bootstrapping phase trying to find peers to connect too, that's why we need to start a local network.
But the current `localnet-start` does not provide us with debugging tools so that's why there is a different image for debugging a local network, that is to avoid any issues in the future were debugging won't be needed.

View File

@ -262,7 +262,7 @@ func uint32ToBytes(i uint32) []byte {
return b[:]
}
// i64 returns the two halfs of the SHA512 HMAC of key and data.
// i64 returns the two halves of the SHA512 HMAC of key and data.
func i64(key, data []byte) (il, ir [32]byte) {
mac := hmac.New(sha512.New, key)
// sha512 does not err

View File

@ -1972,14 +1972,14 @@ func TestRenameKey(t *testing.T) {
},
},
{
name: "cant rename a key that doesnt exist",
name: "can't rename a key that doesnt exist",
run: func(kr Keyring) {
err := kr.Rename("bogus", "bogus2")
require.Error(t, err)
},
},
{
name: "cant rename a key to an already existing key name",
name: "can't rename a key to an already existing key name",
run: func(kr Keyring) {
key1, key2 := "existingKey", "existingKey2" // create 2 keys
newKeyRecord(t, kr, key1)
@ -1990,7 +1990,7 @@ func TestRenameKey(t *testing.T) {
},
},
{
name: "cant rename key to itself",
name: "can't rename key to itself",
run: func(kr Keyring) {
keyName := "keyName"
newKeyRecord(t, kr, keyName)

View File

@ -58,7 +58,7 @@ func TestConstantTimePubKeyGeneration(t *testing.T) {
func TestNonConstantTimePubKeyGeneration(t *testing.T) {
for i := 0; i < 500; i++ {
privKey := GenPrivKey()
nonConstantTimePk := secp256k1_dcrd.PrivKeyFromBytes(privKey.Key).PubKey().SerializeCompressed() // Legacy functionability from pubkey
nonConstantTimePk := secp256k1_dcrd.PrivKeyFromBytes(privKey.Key).PubKey().SerializeCompressed() // Legacy functionality from pubkey
pk := &PubKey{Key: nonConstantTimePk}
require.NotNil(t, pk)
}

View File

@ -456,7 +456,7 @@ func TestLegacyKeyGenerationAgainstConstantTime(t *testing.T) {
pubKey := privKey.PubKey()
nonConstantTimePk := secp.PrivKeyFromBytes(privKey.Key).PubKey().SerializeCompressed() // Legacy functionability from pubkey
nonConstantTimePk := secp.PrivKeyFromBytes(privKey.Key).PubKey().SerializeCompressed() // Legacy functionality from pubkey
legacyPubKey := &secp256k1.PubKey{Key: nonConstantTimePk}
require.Equal(t, legacyPubKey, pubKey)

View File

@ -8,7 +8,7 @@
## What is an ADR?
An ADR is a document to document an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchoronus communication in a distributed environment, an ADR is meant to document an already made decision. An ADR wont come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchoronus discussion then a short excerpt should be added to the ADR to explain the goals.
An ADR is a document to document an implementation and design that may or may not have been discussed in an RFC. While an RFC is meant to replace synchoronus communication in a distributed environment, an ADR is meant to document an already made decision. An ADR won't come with much of a communication overhead because the discussion was recorded in an RFC or a synchronous discussion. If the consensus came from a synchoronus discussion then a short excerpt should be added to the ADR to explain the goals.
## ADR life cycle

View File

@ -49,7 +49,7 @@ Griefing, the act of intentionally getting oneself slashed in order to make anot
### Implementation
In the slashing module, we will add two queues that will track all of the recent slash events. For double sign faults, we will define "recent slashes" as ones that have occurred within the last `unbonding period`. For liveness faults, we will define "recent slashes" as ones that have occurred withing the last `jail period`.
In the slashing module, we will add two queues that will track all of the recent slash events. For double sign faults, we will define "recent slashes" as ones that have occurred within the last `unbonding period`. For liveness faults, we will define "recent slashes" as ones that have occurred within the last `jail period`.
```go
type SlashEvent struct {

View File

@ -27,7 +27,7 @@ There is a new `Msg` type called `MsgExtendVotingPeriod`, which can be sent by a
So for example, if the `MaxVotingPeriodExtension` is set to 100 Days, then anyone with 1% of voting power can extend the voting power by 1 day. If 33% of voting power has sent the message, the voting period will be extended by 33 days. Thus, if absolutely everyone chooses to extend the voting period, the absolute maximum voting period will be `MinVotingPeriod + MaxVotingPeriodExtension`.
This system acts as a sort of distributed coordination, where individual stakers choosing to extend or not, allows the system the guage the conentiousness/complexity of the proposal. It is extremely unlikely that many stakers will choose to extend at the exact same time, it allows stakers to view how long others have already extended thus far, to decide whether or not to extend further.
This system acts as a sort of distributed coordination, where individual stakers choosing to extend or not, allows the system the gauge the conentiousness/complexity of the proposal. It is extremely unlikely that many stakers will choose to extend at the exact same time, it allows stakers to view how long others have already extended thus far, to decide whether or not to extend further.
### Dealing with Unbonding/Redelegation

View File

@ -176,7 +176,7 @@ service Query {
}
```
grpc-gateway will work direcly against the GRPC proxy described above which will
grpc-gateway will work directly against the GRPC proxy described above which will
translate requests to ABCI queries under the hood. grpc-gateway can also
generate Swagger definitions automatically.

View File

@ -40,7 +40,7 @@ in `x/gov`, `MsgSubmitProposal` returns the proposal ID as a big-endian `uint64
This isnt really documented anywhere and clients would need to know the internals
of the Cosmos SDK to parse that value and return it to users.
Also, there may be cases where we want to use these return values programatically.
Also, there may be cases where we want to use these return values programmatically.
For instance, https://github.com/cosmos/cosmos-sdk/issues/7093 proposes a method for
doing inter-module Ocaps using the `Msg` router. A well-defined return type would
improve the developer UX for this approach.
@ -82,7 +82,7 @@ the intent of the [protobuf spec](https://developers.google.com/protocol-buffers
With this approach, we would get an auto-generated `MsgServer` interface:
In addition to clearly specifying return types, this has the benefit of generating client and server code. On the server
side, this is almost like an automatically generated keeper method and could maybe be used intead of keepers eventually
side, this is almost like an automatically generated keeper method and could maybe be used instead of keepers eventually
(see [\#7093](https://github.com/cosmos/cosmos-sdk/issues/7093)):
```go
@ -118,7 +118,7 @@ We propose to add a `msg_service_router` in BaseApp. This router is a key/value
When a transaction is processed by BaseApp (in CheckTx or in DeliverTx), its `TxBody.messages` are decoded as `Msg`s. Each `Msg`'s `type_url` is matched against an entry in the `msg_service_router`, and the respective `Msg` service method handler is called.
For backward compatibility, the old handlers are not removed yet. If BaseApp receives a legacy `Msg` with no correspoding entry in the `msg_service_router`, it will be routed via its legacy `Route()` method into the legacy handler.
For backward compatibility, the old handlers are not removed yet. If BaseApp receives a legacy `Msg` with no corresponding entry in the `msg_service_router`, it will be routed via its legacy `Route()` method into the legacy handler.
### Module Configuration

View File

@ -22,7 +22,7 @@ Currently in the Cosmos SDK, events are defined in the handlers for each message
Currently in the Cosmos SDK, events are defined in the handlers for each message, meaning each module doesn't have a canonical set of types for each event. Above all else this makes these events difficult to consume as it requires a great deal of raw string matching and parsing. This proposal focuses on updating the events to use **typed events** defined in each module such that emitting and subscribing to events will be much easier. This workflow comes from the experience of the Akash Network team.
[Our platform](http://github.com/ovrclk/akash) requires a number of programatic on chain interactions both on the provider (datacenter - to bid on new orders and listen for leases created) and user (application developer - to send the app manifest to the provider) side. In addition the Akash team is now maintaining the IBC [`relayer`](https://github.com/ovrclk/relayer), another very event driven process. In working on these core pieces of infrastructure, and integrating lessons learned from Kubernetes development, our team has developed a standard method for defining and consuming typed events in Cosmos SDK modules. We have found that it is extremely useful in building this type of event driven application.
[Our platform](http://github.com/ovrclk/akash) requires a number of programmatic on chain interactions both on the provider (datacenter - to bid on new orders and listen for leases created) and user (application developer - to send the app manifest to the provider) side. In addition the Akash team is now maintaining the IBC [`relayer`](https://github.com/ovrclk/relayer), another very event driven process. In working on these core pieces of infrastructure, and integrating lessons learned from Kubernetes development, our team has developed a standard method for defining and consuming typed events in Cosmos SDK modules. We have found that it is extremely useful in building this type of event driven application.
As the Cosmos SDK gets used more extensively for apps like `peggy`, other peg zones, IBC, DeFi, etc... there will be an exploding demand for event driven applications to support new features desired by users. We propose upstreaming our findings into the Cosmos SDK to enable all Cosmos SDK applications to quickly and easily build event driven apps to aid their core application. Wallets, exchanges, explorers, and defi protocols all stand to benefit from this work.
@ -308,7 +308,7 @@ func PublishChainTxEvents(ctx context.Context, client cmtclient.EventsClient, bu
return err
})
// Exit on error or context cancelation
// Exit on error or context cancellation
return g.Wait()
}
```

View File

@ -50,7 +50,7 @@ An account that has had its pubkey changed cannot be automatically pruned from s
ctx.GasMeter().ConsumeGas(amount, "pubkey change fee")
```
Everytime a key for an address is changed, we will store a log of this change in the state of the chain, thus creating a stack of all previous keys for an address and the time intervals for which they were active. This allows dapps and clients to easily query past keys for an account which may be useful for features such as verifying timestamped off-chain signed messages.
Every time a key for an address is changed, we will store a log of this change in the state of the chain, thus creating a stack of all previous keys for an address and the time intervals for which they were active. This allows dapps and clients to easily query past keys for an account which may be useful for features such as verifying timestamped off-chain signed messages.
## Consequences

View File

@ -7,7 +7,7 @@
* 10/14/2022:
* Add `ListenCommit`, flatten the state writes in a block to a single batch.
* Remove listeners from cache stores, should only listen to `rootmulti.Store`.
* Remove `HaltAppOnDeliveryError()`, the errors are propagated by default, the implementations should return nil if don't want to propogate errors.
* Remove `HaltAppOnDeliveryError()`, the errors are propagated by default, the implementations should return nil if don't want to propagate errors.
* 26/05/2023: Update with ABCI 2.0
## Status
@ -354,7 +354,7 @@ var Handshake = plugin.HandshakeConfig{
MagicCookieValue: "ef78114d-7bdf-411c-868f-347c99a78345",
}
// ListenerPlugin is the base struc for all kinds of go-plugin implementations
// ListenerPlugin is the base struct for all kinds of go-plugin implementations
// It will be included in interfaces of different Plugins
type ABCIListenerPlugin struct {
// GRPCPlugin must still implement the Plugin interface

View File

@ -45,7 +45,7 @@ Applying it immediately can be viewed as offering greater consensus layer securi
* For threshold based cryptography, this setting will have the threshold cryptography use the original epoch weights, while consensus has an update that lets it more rapidly benefit from additional security. If the threshold based cryptography blocks liveness of the chain, then we have effectively raised the liveness threshold of the remaining validators for the rest of the epoch. (Alternatively, jailed nodes could still contribute shares) This plan will fail in the extreme case that more than 1/3rd of the validators have been jailed within a single epoch. For such an extreme scenario, the chain already have its own custom incident response plan, and defining how to handle the threshold cryptography should be a part of that.
* For light client efficiency, there can be a bit included in the header indicating an intra-epoch slash (ala https://github.com/tendermint/spec/issues/199).
* For fairness of deterministic leader election, applying a slash or jailing within an epoch would break the guarantee we were seeking to provide. This then re-introduces a new (but significantly simpler) problem for trying to provide fairness guarantees. Namely, that validators can adversarially elect to remove themself from the set of proposers. From a security perspective, this could potentially be handled by two different mechanisms (or prove to still be too difficult to achieve). One is making a security statement acknowledging the ability for an adversary to force an ahead-of-time fixed threshold of users to drop out of the proposer set within an epoch. The second method would be to parameterize such that the cost of a slash within the epoch far outweights benefits due to being a proposer. However, this latter criterion is quite dubious, since being a proposer can have many advantageous side-effects in chains with complex state machines. (Namely, DeFi games such as Fomo3D)
* For fairness of deterministic leader election, applying a slash or jailing within an epoch would break the guarantee we were seeking to provide. This then re-introduces a new (but significantly simpler) problem for trying to provide fairness guarantees. Namely, that validators can adversarially elect to remove themself from the set of proposers. From a security perspective, this could potentially be handled by two different mechanisms (or prove to still be too difficult to achieve). One is making a security statement acknowledging the ability for an adversary to force an ahead-of-time fixed threshold of users to drop out of the proposer set within an epoch. The second method would be to parameterize such that the cost of a slash within the epoch far outweighs benefits due to being a proposer. However, this latter criterion is quite dubious, since being a proposer can have many advantageous side-effects in chains with complex state machines. (Namely, DeFi games such as Fomo3D)
* For staking derivative design, there is no issue introduced. This does not increase the state size of staking records, since whether a slash has occurred is fully queryable given the validator address.
### Token lockup

View File

@ -134,7 +134,7 @@ app.UpgradeKeeper.SetUpgradeHandler("my-plan", func(ctx sdk.Context, plan upgrad
Assuming a chain upgrades at block `n`, the procedure should run as follows:
* the old binary will halt in `BeginBlock` when starting block `N`. In its store, the ConsensusVersions of the old binary's modules are stored.
* the new binary will start at block `N`. The UpgradeHandler is set in the new binary, so will run at `BeginBlock` of the new binary. Inside `x/upgrade`'s `ApplyUpgrade`, the `VersionMap` will be retrieved from the (old binary's) store, and passed into the `RunMigrations` functon, migrating all module stores in-place before the modules' own `BeginBlock`s.
* the new binary will start at block `N`. The UpgradeHandler is set in the new binary, so will run at `BeginBlock` of the new binary. Inside `x/upgrade`'s `ApplyUpgrade`, the `VersionMap` will be retrieved from the (old binary's) store, and passed into the `RunMigrations` function, migrating all module stores in-place before the modules' own `BeginBlock`s.
## Consequences

View File

@ -22,7 +22,7 @@ The legacy amino multi-signature mechanism of the Cosmos SDK has certain limitat
* It requires `legacy_amino` sign mode ([#8141](https://github.com/cosmos/cosmos-sdk/issues/8141)).
While the group module is not meant to be a total replacement for the current multi-signature accounts, it provides a solution to the limitations described above, with a more flexible key management system where keys can be added, updated or removed, as well as configurable thresholds.
It's meant to be used with other access control modules such as [`x/feegrant`](./adr-029-fee-grant-module.md) ans [`x/authz`](adr-030-authz-module.md) to simplify key management for individuals and organizations.
It's meant to be used with other access control modules such as [`x/feegrant`](./adr-029-fee-grant-module.md) and [`x/authz`](adr-030-authz-module.md) to simplify key management for individuals and organizations.
The proof of concept of the group module can be found in https://github.com/regen-network/regen-ledger/tree/master/proto/regen/group/v1alpha1 and https://github.com/regen-network/regen-ledger/tree/master/x/group.

View File

@ -72,7 +72,7 @@ This mechanism can be easily composed with prioritization mechanisms:
* we can add extra tiers out of a user control:
* Example 1: user can set tier 0, 10 or 20, but the protocol will create tiers 0, 1, 2 ... 29. For example IBC transactions will go to tier `user_tier + 5`: if user selected tier 1, then the transaction will go to tier 15.
* Example 2: we can reserve tier 4, 5, ... only for special transaction types. For example, tier 5 is reserved for evidence tx. So if submits a bank.Send transaction and set tier 5, it will be delegated to tier 3 (the max tier level available for any transaction).
* Example 3: we can enforce that all transactions of a sepecific type will go to specific tier. For example, tier 100 will be reserved for evidence transactions and all evidence transactions will always go to that tier.
* Example 3: we can enforce that all transactions of a specific type will go to specific tier. For example, tier 100 will be reserved for evidence transactions and all evidence transactions will always go to that tier.
### `min-gas-prices`

View File

@ -31,7 +31,7 @@ acting as a delimiter between extensions. As the chunk hashes should be able to
a delimiter to mark the end of the snapshot stream.
Besides, we provide `Snapshotter` and `ExtensionSnapshotter` interface for modules to implement snapshotters, which will handle both taking
snapshot and the restoration. Each module could have mutiple snapshotters, and for modules with additional state, they should
snapshot and the restoration. Each module could have multiple snapshotters, and for modules with additional state, they should
implement `ExtensionSnapshotter` as extension snapshotters. When setting up the application, the snapshot `Manager` should call
`RegisterExtensions([]ExtensionSnapshotter…)` to register all the extension snapshotters.

View File

@ -72,7 +72,7 @@ or needs to be present only for signature integrity (see below).
We require that the rendering of the transaction be invertible:
there must be a parsing function such that for every transaction,
when rendered to the textual representation,
parsing that representation yeilds a proto message equivalent
parsing that representation yields a proto message equivalent
to the original under proto equality.
Note that this inverse function does not need to perform correct
@ -145,7 +145,7 @@ type SignDocTextual struct {
```
We do not plan to use protobuf serialization to form the sequence of bytes
that will be tranmitted and signed, in order to keep the decoder simple.
that will be transmitted and signed, in order to keep the decoder simple.
We will use [CBOR](https://cbor.io) ([RFC 8949](https://www.rfc-editor.org/rfc/rfc8949.html)) instead.
The encoding is defined by the following CDDL ([RFC 8610](https://www.rfc-editor.org/rfc/rfc8610)):

View File

@ -81,7 +81,7 @@ The Cosmos SDK also provides a couple of other sign modes for particular use cas
#### `SIGN_MODE_DIRECT_AUX`
`SIGN_MODE_DIRECT_AUX` is a sign mode released in the Cosmos SDK v0.46 which targets transactions with multiple signers. Whereas `SIGN_MODE_DIRECT` expects each signer to sign over both `TxBody` and `AuthInfo` (which includes all other signers' signer infos, i.e. their account sequence, public key and mode info), `SIGN_MODE_DIRECT_AUX` allows N-1 signers to only sign over `TxBody` and _their own_ signer info. Morever, each auxiliary signer (i.e. a signer using `SIGN_MODE_DIRECT_AUX`) doesn't
`SIGN_MODE_DIRECT_AUX` is a sign mode released in the Cosmos SDK v0.46 which targets transactions with multiple signers. Whereas `SIGN_MODE_DIRECT` expects each signer to sign over both `TxBody` and `AuthInfo` (which includes all other signers' signer infos, i.e. their account sequence, public key and mode info), `SIGN_MODE_DIRECT_AUX` allows N-1 signers to only sign over `TxBody` and _their own_ signer info. Moreover, each auxiliary signer (i.e. a signer using `SIGN_MODE_DIRECT_AUX`) doesn't
need to sign over the fees:
```protobuf reference

View File

@ -71,7 +71,7 @@ https://github.com/cosmos/cosmos-sdk/blob/v0.50.0-alpha.0/simapp/simd/cmd/root_v
:::tip
Use the `EnhanceRootCommand()` from the AutoCLI options to automatically add auto-generated commands from the modules to the root command.
Additionnally it adds all manually defined modules commands (`tx` and `query`) as well.
Additionally it adds all manually defined modules commands (`tx` and `query`) as well.
Read more about [AutoCLI](https://docs.cosmos.network/main/core/autocli) in its dedicated section.
:::

View File

@ -4,7 +4,7 @@ sidebar_position: 1
# RunTx recovery middleware
`BaseApp.runTx()` function handles Go panics that might occur during transactions execution, for example, keeper has faced an invalid state and paniced.
`BaseApp.runTx()` function handles Go panics that might occur during transactions execution, for example, keeper has faced an invalid state and panicked.
Depending on the panic type different handler is used, for instance the default one prints an error log message.
Recovery middleware is used to add custom panic recovery for Cosmos SDK application developers.

View File

@ -16,7 +16,7 @@ With the separation of CometBFT and Cosmos-SDK, there is a lack of control of wh
The acceptance of this RFC would move validation within `ValidateBasic` to the message server in modules, update tutorials and docs to remove mention of using `ValidateBasic` in favour of handling all validation for a message where it is executed.
We can and will still support the `Validatebasic` function for users and provide an extension interface of the function once `sdk.Msg` is depreacted.
We can and will still support the `Validatebasic` function for users and provide an extension interface of the function once `sdk.Msg` is deprecated.
> Note: This is how messages are handled in VMs like Ethereum and CosmWasm.

View File

@ -32,7 +32,7 @@
> path and fall into the same pitfalls that we've since matured from. Abandoned ideas are a way to recognize that path
> and explain the pitfalls and why they were abandoned.
## Descision
## Decision
> This section describes alternative designs to the chosen design. This section
> is important and if an adr does not have any alternatives then it should be

View File

@ -16,6 +16,6 @@ In the Cosmos network, keys and addresses may refer to a number of different rol
While all user facing interfaces to Cosmos software should exposed Bech32 interfaces, many internal interfaces encode binary value in hex or base64 encoded form.
To covert between other binary representation of addresses and keys, it is important to first apply the Amino encoding process before Bech32 encoding.
To convert between other binary representation of addresses and keys, it is important to first apply the Amino encoding process before Bech32 encoding.
A complete implementation of the Amino serialization format is unnecessary in most cases. Simply prepending bytes from this [table](https://github.com/cometbft/cometbft/blob/main/spec/blockchain/encoding.md) to the byte string payload before Bech32 encoding will sufficient for compatible representation.

View File

@ -110,7 +110,7 @@ When there are multiple slashes, you just account for the accumulated slash fact
In practice this will not really be an efficiency hit, as the number of slashes is expected to be 0 or 1 for most validators.
Validators that get slashed more will naturally lose their delegators.
A malicious validator that gets itself slashed many times would increase the gas to withdraw linearly, but the economic loss of funds due to the slashes is expected to far out-weigh the extra overhead the honest withdrawer must pay for due to the gas.
(TODO: frame that above sentence in terms of griefing factors, as thats more correct)
(TODO: frame that above sentence in terms of griefing factors, as that's more correct)
\subsection{Inflation}
Inflation is the idea that we want every staked coin to create more staking tokens as time progresses.

View File

@ -1,2 +1,2 @@
// Package conv provides internal functions for convertions and data manipulation
// Package conv provides internal functions for conversions and data manipulation
package conv

View File

@ -725,7 +725,7 @@ func (d LegacyDec) TruncateDec() LegacyDec {
return LegacyNewDecFromBigInt(chopPrecisionAndTruncateNonMutative(d.i))
}
// Ceil returns the smallest interger value (as a decimal) that is greater than
// Ceil returns the smallest integer value (as a decimal) that is greater than
// or equal to the given decimal.
func (d LegacyDec) Ceil() LegacyDec {
tmp := new(big.Int).Set(d.i)

View File

@ -269,9 +269,9 @@ type BalanceTable interface {
Update(ctx context.Context, balance *Balance) error
Save(ctx context.Context, balance *Balance) error
Delete(ctx context.Context, balance *Balance) error
Has(ctx context.Context, acocunt []byte, denom string) (found bool, err error)
Has(ctx context.Context, account []byte, denom string) (found bool, err error)
// Get returns nil and an error which responds true to ormerrors.IsNotFound() if the record was not found.
Get(ctx context.Context, acocunt []byte, denom string) (*Balance, error)
Get(ctx context.Context, account []byte, denom string) (*Balance, error)
List(ctx context.Context, prefixKey BalanceIndexKey, opts ...ormlist.Option) (BalanceIterator, error)
ListRange(ctx context.Context, from, to BalanceIndexKey, opts ...ormlist.Option) (BalanceIterator, error)
DeleteBy(ctx context.Context, prefixKey BalanceIndexKey) error

View File

@ -8,7 +8,7 @@ option go_package = "cosmossdk.io/x/authz";
// EventGrant is emitted on Msg/Grant
message EventGrant {
// Msg type URL for which an autorization is granted
// Msg type URL for which an authorization is granted
string msg_type_url = 2;
// Granter account address
string granter = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"];
@ -18,7 +18,7 @@ message EventGrant {
// EventRevoke is emitted on Msg/Revoke
message EventRevoke {
// Msg type URL for which an autorization is revoked
// Msg type URL for which an authorization is revoked
string msg_type_url = 2;
// Granter account address
string granter = 3 [(cosmos_proto.scalar) = "cosmos.AddressString"];

View File

@ -17,7 +17,7 @@ message AppDescriptor {
CodecDescriptor codec = 3;
// configuration provides metadata information regarding the sdk.Config type
ConfigurationDescriptor configuration = 4;
// query_services provides metadata information regarding the available queriable endpoints
// query_services provides metadata information regarding the available queryable endpoints
QueryServicesDescriptor query_services = 5;
// tx provides metadata information regarding how to send transactions to the given application
TxDescriptor tx = 6;
@ -190,7 +190,7 @@ message GetTxDescriptorResponse {
TxDescriptor tx = 1;
}
// QueryServicesDescriptor contains the list of cosmos-sdk queriable services
// QueryServicesDescriptor contains the list of cosmos-sdk queryable services
message QueryServicesDescriptor {
// query_services is a list of cosmos-sdk QueryServiceDescriptor
repeated QueryServiceDescriptor query_services = 1;

View File

@ -9,7 +9,7 @@ extend google.protobuf.MessageOptions {
// algorithm used to generate the custom textual representation of the
// protobuf message where this annotation is applied. We recommend to use a
// short, versioned name as this identifier, e.g. "replace_with_username_v1".
// We also recommand providing a human-readable description as protobuf
// We also recommend providing a human-readable description as protobuf
// comments on this annotation, for example a short specification or a link
// to the relevant documentation.
//

View File

@ -144,7 +144,7 @@ message Validator {
// strictly positive if this validator's unbonding has been stopped by external modules
int64 unbonding_on_hold_ref_count = 12;
// list of unbonding ids, each uniquely identifing an unbonding of this validator
// list of unbonding ids, each uniquely identifying an unbonding of this validator
repeated uint64 unbonding_ids = 13;
}

View File

@ -346,7 +346,7 @@ message ResponseVerifyVoteExtension {
}
message ResponseFinalizeBlock {
// set of block events emmitted as part of executing the block
// set of block events emitted as part of executing the block
repeated Event events = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"];
// the result of executing each transaction including the events
// the particular transction emitted. This should match the order

View File

@ -27,7 +27,7 @@ message DominoOp {
}
// ProofOp defines an operation used for calculating Merkle root
// The data could be arbitrary format, providing nessecary data
// The data could be arbitrary format, providing necessary data
// for example neighbouring node hash
message ProofOp {
string type = 1;

View File

@ -69,7 +69,7 @@ type BaseConfig struct {
// It has no bearing on application state pruning which is determined by the
// "pruning-*" configurations.
//
// Note: CometBFT block pruning is dependant on this parameter in conjunction
// Note: CometBFT block pruning is dependent on this parameter in conjunction
// with the unbonding (safety threshold) period, state pruning and state sync
// snapshot parameters to determine the correct minimum value of
// ResponseCommit.RetainHeight.

View File

@ -58,7 +58,7 @@ halt-time = {{ .BaseConfig.HaltTime }}
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: CometBFT block pruning is dependant on this parameter in conjunction
# Note: CometBFT block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.

View File

@ -39,7 +39,7 @@ type AppDescriptor struct {
Codec *CodecDescriptor `protobuf:"bytes,3,opt,name=codec,proto3" json:"codec,omitempty"`
// configuration provides metadata information regarding the sdk.Config type
Configuration *ConfigurationDescriptor `protobuf:"bytes,4,opt,name=configuration,proto3" json:"configuration,omitempty"`
// query_services provides metadata information regarding the available queriable endpoints
// query_services provides metadata information regarding the available queryable endpoints
QueryServices *QueryServicesDescriptor `protobuf:"bytes,5,opt,name=query_services,json=queryServices,proto3" json:"query_services,omitempty"`
// tx provides metadata information regarding how to send transactions to the given application
Tx *TxDescriptor `protobuf:"bytes,6,opt,name=tx,proto3" json:"tx,omitempty"`
@ -1156,7 +1156,7 @@ func (m *GetTxDescriptorResponse) GetTx() *TxDescriptor {
return nil
}
// QueryServicesDescriptor contains the list of cosmos-sdk queriable services
// QueryServicesDescriptor contains the list of cosmos-sdk queryable services
type QueryServicesDescriptor struct {
// query_services is a list of cosmos-sdk QueryServiceDescriptor
QueryServices []*QueryServiceDescriptor `protobuf:"bytes,1,rep,name=query_services,json=queryServices,proto3" json:"query_services,omitempty"`

View File

@ -217,7 +217,7 @@ func (kv kvStore) Prefix(prefix []byte) storetypes.KVStore {
}
func (kv kvStore) Gas(meter storetypes.GasMeter, config storetypes.GasConfig) storetypes.KVStore {
panic("not implmeneted")
panic("not implemented")
}
func (kv kvStore) Iterator(start, end []byte) storetypes.Iterator {

View File

@ -184,7 +184,7 @@ var (
Name: stakingtypes.ModuleName,
Config: appconfig.WrapAny(&stakingmodulev1.Module{
// NOTE: specifying a prefix is only necessary when using bech32 addresses
// If not specfied, the auth Bech32Prefix appended with "valoper" and "valcons" is used by default
// If not specified, the auth Bech32Prefix appended with "valoper" and "valcons" is used by default
Bech32PrefixValidator: "cosmosvaloper",
Bech32PrefixConsensus: "cosmosvalcons",
}),

View File

@ -61,7 +61,7 @@ func initClientConfig() (string, interface{}) {
// And we set the default config to the custom app template.
customClientConfigTemplate := clientconfig.DefaultClientConfigTemplate + strings.TrimSpace(`
# This is default the gas adjustment factor used in tx commands.
# It can be overwriten by the --gas-adjustment flag in each tx command.
# It can be overwritten by the --gas-adjustment flag in each tx command.
gas-adjustment = {{ .GasConfig.GasAdjustment }}
`)

View File

@ -128,7 +128,7 @@ make install
* Longer running pods or infra without issues.
### Testing/Infra
* Add more tests based on requirements, port all exsiting adhoc tests to Starship
* Add more tests based on requirements, port all existing adhoc tests to Starship
* Add build system into starship (premetive exists) to be able to build the current simapp from the branch
* Start from non-empty genesis
* Add the concept of `jobs` into Starship config, where we can run predefined jobs against the infra

View File

@ -13,7 +13,7 @@ chains:
# todo: faucet seems to throw error with sdk version 0.50, still seems to work
image: ghcr.io/cosmology-tech/starship/cosmjs-faucet:v0.31.0
# provide more resources to faucet since the number of validators is higher
# only a single faucet is spun up with the genesis node, so resources wont multiply
# only a single faucet is spun up with the genesis node, so resources won't multiply
# with the number of validators
resources:
cpu: "0.5"

View File

@ -8,7 +8,7 @@ import (
sdk "github.com/cosmos/cosmos-sdk/types"
)
// GenerateCoinKey generates a new key mnemonic along with its addrress.
// GenerateCoinKey generates a new key mnemonic along with its address.
func GenerateCoinKey(algo keyring.SignatureAlgo, cdc codec.Codec) (sdk.AccAddress, string, error) {
// generate a private key, with mnemonic
info, secret, err := keyring.NewInMemory(cdc).NewMnemonic(
@ -28,7 +28,7 @@ func GenerateCoinKey(algo keyring.SignatureAlgo, cdc codec.Codec) (sdk.AccAddres
return addr, secret, nil
}
// GenerateSaveCoinKey generates a new key mnemonic with its addrress.
// GenerateSaveCoinKey generates a new key mnemonic with its address.
// If mnemonic is provided then it's used for key generation.
// The key is saved in the keyring. The function returns error if overwrite=true and the key
// already exists.

View File

@ -602,7 +602,7 @@ func New(l Logger, baseDir string, cfg Config) (NetworkI, error) {
l.Log("started test network at height:", height)
// Ensure we cleanup incase any test was abruptly halted (e.g. SIGINT) as any
// Ensure we cleanup in case any test was abruptly halted (e.g. SIGINT) as any
// defer in a test would not be called.
trapSignal(network.Cleanup)

View File

@ -27,7 +27,7 @@ func TestMigrateCmd(t *testing.T) {
_, err = clitestutil.ExecTestCLICmd(clientCtx, cmd.MigrateCommand(), []string{"v0.46", filepath.Join(clientCtx.HomeDir, "config", "unsupported.toml")})
assert.ErrorContains(t, err, "failed to migrate config")
// try to migrate from unspported.toml - it should work and give us a big diff
// try to migrate from unsupported.toml - it should work and give us a big diff
out, err := clitestutil.ExecTestCLICmd(clientCtx, cmd.MigrateCommand(), []string{"v0.46", filepath.Join(clientCtx.HomeDir, "config", "unsupported.toml"), "--skip-validate", "--verbose"})
assert.NilError(t, err)
assert.Assert(t, strings.Contains(out.String(), "add app-db-backend key"))

View File

@ -44,7 +44,7 @@ halt-time = 0
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: Tendermint block pruning is dependant on this parameter in conjunction
# Note: Tendermint block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.

View File

@ -43,7 +43,7 @@ halt-time = 0
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: Tendermint block pruning is dependant on this parameter in conjunction
# Note: Tendermint block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.
@ -172,7 +172,7 @@ enable-fee-suggestion = false
# GasToSuggest defines gas limit when calculating the fee
gas-to-suggest = 200000
# DenomToSuggest defines the defult denom for fee suggestion.
# DenomToSuggest defines the default denom for fee suggestion.
# Price must be in minimum-gas-prices.
denom-to-suggest = "uatom"

View File

@ -43,7 +43,7 @@ halt-time = 0
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: Tendermint block pruning is dependant on this parameter in conjunction
# Note: Tendermint block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.
@ -170,7 +170,7 @@ enable-fee-suggestion = false
# GasToSuggest defines gas limit when calculating the fee
gas-to-suggest = 200000
# DenomToSuggest defines the defult denom for fee suggestion.
# DenomToSuggest defines the default denom for fee suggestion.
# Price must be in minimum-gas-prices.
denom-to-suggest = "uatom"

View File

@ -47,7 +47,7 @@ halt-time = 0
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: CometBFT block pruning is dependant on this parameter in conjunction
# Note: CometBFT block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.

View File

@ -47,7 +47,7 @@ halt-time = 0
# It has no bearing on application state pruning which is determined by the
# "pruning-*" configurations.
#
# Note: CometBFT block pruning is dependant on this parameter in conjunction
# Note: CometBFT block pruning is dependent on this parameter in conjunction
# with the unbonding (safety threshold) period, state pruning and state sync
# snapshot parameters to determine the correct minimum value of
# ResponseCommit.RetainHeight.

View File

@ -35,7 +35,7 @@ Cosmovisor is designed to be used as a wrapper for a `Cosmos SDK` app:
*Note: If new versions of the application are not set up to run in-place store migrations, migrations will need to be run manually before restarting `cosmovisor` with the new binary. For this reason, we recommend applications adopt in-place store migrations.*
:::tip
Only the lastest version of cosmovisor is actively developed/maintained.
Only the latest version of cosmovisor is actively developed/maintained.
:::
:::warning
@ -128,9 +128,9 @@ Use of `cosmovisor` without one of the action arguments is deprecated. For backw
└── preupgrade.sh (optional)
```
The `cosmovisor/` directory incudes a subdirectory for each version of the application (i.e. `genesis` or `upgrades/<name>`). Within each subdirectory is the application binary (i.e. `bin/$DAEMON_NAME`) and any additional auxiliary files associated with each binary. `current` is a symbolic link to the currently active directory (i.e. `genesis` or `upgrades/<name>`). The `name` variable in `upgrades/<name>` is the lowercased URI-encoded name of the upgrade as specified in the upgrade module plan. Note that the upgrade name path are normalized to be lowercased: for instance, `MyUpgrade` is normalized to `myupgrade`, and its path is `upgrades/myupgrade`.
The `cosmovisor/` directory includes a subdirectory for each version of the application (i.e. `genesis` or `upgrades/<name>`). Within each subdirectory is the application binary (i.e. `bin/$DAEMON_NAME`) and any additional auxiliary files associated with each binary. `current` is a symbolic link to the currently active directory (i.e. `genesis` or `upgrades/<name>`). The `name` variable in `upgrades/<name>` is the lowercased URI-encoded name of the upgrade as specified in the upgrade module plan. Note that the upgrade name path are normalized to be lowercased: for instance, `MyUpgrade` is normalized to `myupgrade`, and its path is `upgrades/myupgrade`.
Please note that `$DAEMON_HOME/cosmovisor` only stores the *application binaries*. The `cosmovisor` binary itself can be stored in any typical location (e.g. `/usr/local/bin`). The application will continue to store its data in the default data directory (e.g. `$HOME/.simapp`) or the data directory specified with the `--home` flag. `$DAEMON_HOME` is independent of the data directory and can be set to any location. If you set `$DAEMON_HOME` to the same directory as the data directory, you will end up with a configuation like the following:
Please note that `$DAEMON_HOME/cosmovisor` only stores the *application binaries*. The `cosmovisor` binary itself can be stored in any typical location (e.g. `/usr/local/bin`). The application will continue to store its data in the default data directory (e.g. `$HOME/.simapp`) or the data directory specified with the `--home` flag. `$DAEMON_HOME` is independent of the data directory and can be set to any location. If you set `$DAEMON_HOME` to the same directory as the data directory, you will end up with a configuration like the following:
```text
.simapp

View File

@ -180,8 +180,8 @@ func (l Launcher) doBackup() error {
// a destination directory, Format YYYY-MM-DD
st := time.Now()
stStr := fmt.Sprintf("%d-%d-%d", st.Year(), st.Month(), st.Day())
dst := filepath.Join(l.cfg.DataBackupPath, fmt.Sprintf("data"+"-backup-%s", stStr))
ymd := fmt.Sprintf("%d-%d-%d", st.Year(), st.Month(), st.Day())
dst := filepath.Join(l.cfg.DataBackupPath, fmt.Sprintf("data"+"-backup-%s", ymd))
l.logger.Info("starting to take backup of data directory", "backup start time", st)

View File

@ -131,7 +131,7 @@ func (fw *fileWatcher) CheckUpdate(currentUpgrade upgradetypes.Plan) bool {
fw.currentInfo = info
fw.lastModTime = stat.ModTime()
// Heuristic: Deamon has restarted, so we don't know if we successfully
// Heuristic: Daemon has restarted, so we don't know if we successfully
// downloaded the upgrade or not. So we try to compare the running upgrade
// name (read from the cosmovisor file) with the upgrade info.
if !strings.EqualFold(currentUpgrade.Name, fw.currentInfo.Name) {

View File

@ -629,7 +629,7 @@ func (ca ConsAddress) String() string {
}
// Bech32ifyAddressBytes returns a bech32 representation of address bytes.
// Returns an empty sting if the byte slice is 0-length. Returns an error if the bech32 conversion
// Returns an empty string if the byte slice is 0-length. Returns an error if the bech32 conversion
// fails or the prefix is empty.
func Bech32ifyAddressBytes(prefix string, bs []byte) (string, error) {
if len(bs) == 0 {
@ -642,7 +642,7 @@ func Bech32ifyAddressBytes(prefix string, bs []byte) (string, error) {
}
// MustBech32ifyAddressBytes returns a bech32 representation of address bytes.
// Returns an empty sting if the byte slice is 0-length. It panics if the bech32 conversion
// Returns an empty string if the byte slice is 0-length. It panics if the bech32 conversion
// fails or the prefix is empty.
func MustBech32ifyAddressBytes(prefix string, bs []byte) string {
s, err := Bech32ifyAddressBytes(prefix, bs)

View File

@ -40,11 +40,11 @@ func (s *addressTestSuite) TestAddressRace() {
done := make(chan bool, workers)
cancel := make(chan bool)
for i := byte(1); i <= 2; i++ { // workes which will loop in first 100 addresses
for i := byte(1); i <= 2; i++ { // works which will loop in first 100 addresses
go addressStringCaller(s.Require(), i, 100, cancel, done)
}
for i := byte(1); i <= 2; i++ { // workes which will generate 1e6 new addresses
for i := byte(1); i <= 2; i++ { // works which will generate 1e6 new addresses
go addressStringCaller(s.Require(), i, 1000000, cancel, done)
}

View File

@ -76,7 +76,7 @@ func (s *coinTestSuite) TestIsEqualCoin() {
func (s *coinTestSuite) TestCoinIsValid() {
loremIpsum := `Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nam viverra dui vel nulla aliquet, non dictum elit aliquam. Proin consequat leo in consectetur mattis. Phasellus eget odio luctus, rutrum dolor at, venenatis ante. Praesent metus erat, sodales vitae sagittis eget, commodo non ipsum. Duis eget urna quis erat mattis pulvinar. Vivamus egestas imperdiet sem, porttitor hendrerit lorem pulvinar in. Vivamus laoreet sapien eget libero euismod tristique. Suspendisse tincidunt nulla quis luctus mattis.
Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Sed id turpis at erat placerat fermentum id sed sapien. Fusce mattis enim id nulla viverra, eget placerat eros aliquet. Nunc fringilla urna ac condimentum ultricies. Praesent in eros ac neque fringilla sodales. Donec ut venenatis eros. Quisque iaculis lectus neque, a varius sem ullamcorper nec. Cras tincidunt dignissim libero nec volutpat. Donec molestie enim sed metus venenatis, quis elementum sem varius. Curabitur eu venenatis nulla.
Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Sed id turpis at erat placerat fermentum id sed sapien. Fusce mattis enim id nulla viverra, eget placerat eros aliquet. Nunc fringilla urna ac condimentum ultricies. Praesent in eros ac neque fringilla sodales. Donec ut venenatis eros. Quisque iaculis lectus neque, a various sem ullamcorper nec. Cras tincidunt dignissim libero nec volutpat. Donec molestie enim sed metus venenatis, quis elementum sem various. Curabitur eu venenatis nulla.
Cras sit amet ligula vel turpis placerat sollicitudin. Nunc massa odio, eleifend id lacus nec, ultricies elementum arcu. Donec imperdiet nulla lacus, a venenatis lacus fermentum nec. Proin vestibulum dolor enim, vitae posuere velit aliquet non. Suspendisse pharetra condimentum nunc tincidunt viverra. Etiam posuere, ligula ut maximus congue, mauris orci consectetur velit, vel finibus eros metus non tellus. Nullam et dictum metus. Aliquam maximus fermentum mauris elementum aliquet. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Etiam dapibus lectus sed tellus rutrum tincidunt. Nulla at dolor sem. Ut non dictum arcu, eget congue sem.`
loremIpsum = strings.ReplaceAll(loremIpsum, " ", "")

View File

@ -643,7 +643,7 @@ type MigrationHandler func(sdk.Context) error
type VersionMap map[string]uint64
// RunMigrations performs in-place store migrations for all modules. This
// function MUST be called insde an x/upgrade UpgradeHandler.
// function MUST be called inside an x/upgrade UpgradeHandler.
//
// Recall that in an upgrade handler, the `fromVM` VersionMap is retrieved from
// x/upgrade's store, and the function needs to return the target VersionMap

View File

@ -4,6 +4,6 @@ import (
"regexp"
)
// IsAlphaNumeric defines a regular expression for matching against alpha-numeric
// IsAlphaNumeric defines a regular expression for matching against alphanumeric
// values.
var IsAlphaNumeric = regexp.MustCompile(`^[a-zA-Z0-9]+$`).MatchString

View File

@ -71,15 +71,15 @@ func SignatureDataFromProto(descData *SignatureDescriptor_Data) SignatureData {
}
case *SignatureDescriptor_Data_Multi_:
multi := descData.Multi
datas := make([]SignatureData, len(multi.Signatures))
data := make([]SignatureData, len(multi.Signatures))
for j, d := range multi.Signatures {
datas[j] = SignatureDataFromProto(d)
data[j] = SignatureDataFromProto(d)
}
return &MultiSignatureData{
BitArray: multi.Bitarray,
Signatures: datas,
Signatures: data,
}
default:
panic(fmt.Errorf("unexpected case %+v", descData))

View File

@ -108,7 +108,7 @@ type Implementation struct {
// MessageSchema defines the schema of a message.
// A message can also define a state schema.
type MessageSchema struct {
// Name identifies the message name, this must be queriable from some reflection service.
// Name identifies the message name, this must be queryable from some reflection service.
Name string
// New is used to create a new message instance for the schema.
New func() ProtoMsg

View File

@ -23,7 +23,7 @@ var _ store.KVStore = Store{}
// Store is similar with cometbft/cometbft/libs/db/prefix_db
// both gives access only to the limited subset of the store
// for convinience or safety
// for convenience or safety
type Store struct {
parent store.KVStore
prefix []byte

View File

@ -399,7 +399,7 @@ func (svd SigVerificationDecorator) AnteHandle(ctx sdk.Context, tx sdk.Tx, simul
// BaseApp.Commit() will set the check state based on the latest header.
//
// NOTE: Since CheckTx and DeliverTx state are managed separately, subsequent and
// sequential txs orginating from the same account cannot be handled correctly in
// sequential txs originating from the same account cannot be handled correctly in
// a reliable way unless sequence numbers are managed and tracked manually by a
// client. It is recommended to instead use multiple messages in a tx.
type IncrementSequenceDecorator struct {

View File

@ -421,7 +421,7 @@ func TestAnteHandlerChecks(t *testing.T) {
accNums []uint64
accSeqs []uint64
shouldErr bool
suported bool
supported bool
}
// Secp256r1 keys that are not on curve will fail before even doing any operation i.e when trying to get the pubkey
@ -450,7 +450,7 @@ func TestAnteHandlerChecks(t *testing.T) {
_, err = anteHandler(byteCtx, tx, true)
if tc.shouldErr {
require.NotNil(t, err, "TestCase %d: %s did not error as expected", i, tc.name)
if tc.suported {
if tc.supported {
require.ErrorContains(t, err, "not on curve")
} else {
require.ErrorContains(t, err, "unsupported key type")

View File

@ -111,7 +111,7 @@ simd query blocks --query 'message.sender=cosmos...' --page 1 --limit 30
#### Transactions
The `x/auth/tx` module provides a convinient CLI command for decoding and encoding transactions.
The `x/auth/tx` module provides a convenient CLI command for decoding and encoding transactions.
#### `encode`

View File

@ -35,8 +35,8 @@ This specification defines the vesting account implementation that is used by th
For all vesting accounts, the owner of the vesting account is able to delegate and undelegate from validators, however they cannot transfer coins to another account until those coins are vested. This specification allows for four different kinds of vesting:
* Delayed vesting, where all coins are vested once `ET` is reached.
* Continous vesting, where coins begin to vest at `ST` and vest linearly with respect to time until `ET` is reached
* Periodic vesting, where coins begin to vest at `ST` and vest periodically according to number of periods and the vesting amount per period. The number of periods, length per period, and amount per period are configurable. A periodic vesting account is distinguished from a continuous vesting account in that coins can be released in staggered tranches. For example, a periodic vesting account could be used for vesting arrangements where coins are relased quarterly, yearly, or over any other function of tokens over time.
* Continuous vesting, where coins begin to vest at `ST` and vest linearly with respect to time until `ET` is reached
* Periodic vesting, where coins begin to vest at `ST` and vest periodically according to number of periods and the vesting amount per period. The number of periods, length per period, and amount per period are configurable. A periodic vesting account is distinguished from a continuous vesting account in that coins can be released in staggered tranches. For example, a periodic vesting account could be used for vesting arrangements where coins are released quarterly, yearly, or over any other function of tokens over time.
* Permanent locked vesting, where coins are locked forever. Coins in this account can still be used for delegating and for governance votes even while locked.
## Note

View File

@ -96,7 +96,7 @@ https://github.com/cosmos/cosmos-sdk/blob/v0.47.0-rc1/x/staking/types/authz.go#L
In order to prevent DoS attacks, granting `StakeAuthorization`s with `x/authz` incurs gas. `StakeAuthorization` allows you to authorize another account to delegate, undelegate, or redelegate to validators. The authorizer can define a list of validators they allow or deny delegations to. The Cosmos SDK iterates over these lists and charge 10 gas for each validator in both of the lists.
Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (incase of any revoke of paritcular `msgType`) from the list and we are charging 20 gas per iteration.
Since the state maintaining a list for granter, grantee pair with same expiration, we are iterating over the list to remove the grant (in case of any revoke of paritcular `msgType`) from the list and we are charging 20 gas per iteration.
## State

View File

@ -25,7 +25,7 @@ const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
// EventGrant is emitted on Msg/Grant
type EventGrant struct {
// Msg type URL for which an autorization is granted
// Msg type URL for which an authorization is granted
MsgTypeUrl string `protobuf:"bytes,2,opt,name=msg_type_url,json=msgTypeUrl,proto3" json:"msg_type_url,omitempty"`
// Granter account address
Granter string `protobuf:"bytes,3,opt,name=granter,proto3" json:"granter,omitempty"`
@ -89,7 +89,7 @@ func (m *EventGrant) GetGrantee() string {
// EventRevoke is emitted on Msg/Revoke
type EventRevoke struct {
// Msg type URL for which an autorization is revoked
// Msg type URL for which an authorization is revoked
MsgTypeUrl string `protobuf:"bytes,2,opt,name=msg_type_url,json=msgTypeUrl,proto3" json:"msg_type_url,omitempty"`
// Granter account address
Granter string `protobuf:"bytes,3,opt,name=granter,proto3" json:"granter,omitempty"`

View File

@ -1012,7 +1012,7 @@ Example Output:
### SendEnabled
The `SendEnabled` enpoints allows users to query the SendEnabled entries of the `bank` module.
The `SendEnabled` endpoints allows users to query the SendEnabled entries of the `bank` module.
Any denominations NOT returned, use the `Params.DefaultSendEnabled` value.

View File

@ -107,7 +107,7 @@ func SimulateMsgSendToModuleAccount(
txGen client.TxConfig,
ak types.AccountKeeper,
bk keeper.Keeper,
moduleAccCount int,
moduleAccount int,
) simtypes.Operation {
return func(
r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context,
@ -115,7 +115,7 @@ func SimulateMsgSendToModuleAccount(
) (simtypes.OperationMsg, []simtypes.FutureOperation, error) {
msgType := sdk.MsgTypeURL(&types.MsgSend{})
from := accs[0]
to := getModuleAccounts(ak, ctx, moduleAccCount)[0]
to := getModuleAccounts(ak, ctx, moduleAccount)[0]
spendable := bk.SpendableCoins(ctx, from.Address)
coins := simtypes.RandSubsetCoins(r, spendable)
@ -290,7 +290,7 @@ func SimulateMsgMultiSendToModuleAccount(
txGen client.TxConfig,
ak types.AccountKeeper,
bk keeper.Keeper,
moduleAccCount int,
moduleAccount int,
) simtypes.Operation {
return func(
r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context,
@ -298,7 +298,7 @@ func SimulateMsgMultiSendToModuleAccount(
) (simtypes.OperationMsg, []simtypes.FutureOperation, error) {
msgType := sdk.MsgTypeURL(&types.MsgMultiSend{})
inputs := make([]types.Input, 2)
outputs := make([]types.Output, moduleAccCount)
outputs := make([]types.Output, moduleAccount)
// collect signer privKeys
privs := make([]cryptotypes.PrivKey, len(inputs))
var totalSentCoins sdk.Coins
@ -313,7 +313,7 @@ func SimulateMsgMultiSendToModuleAccount(
if err := bk.IsSendEnabledCoins(ctx, totalSentCoins...); err != nil {
return simtypes.NoOpMsg(types.ModuleName, msgType, err.Error()), nil, nil
}
moduleAccounts := getModuleAccounts(ak, ctx, moduleAccCount)
moduleAccounts := getModuleAccounts(ak, ctx, moduleAccount)
for i := range outputs {
var outCoins sdk.Coins
// split total sent coins into random subsets for output
@ -437,10 +437,10 @@ func randomSendFields(
return from, to, sendCoins, false
}
func getModuleAccounts(ak types.AccountKeeper, ctx sdk.Context, moduleAccCount int) []simtypes.Account {
moduleAccounts := make([]simtypes.Account, moduleAccCount)
func getModuleAccounts(ak types.AccountKeeper, ctx sdk.Context, moduleAccount int) []simtypes.Account {
moduleAccounts := make([]simtypes.Account, moduleAccount)
for i := 0; i < moduleAccCount; i++ {
for i := 0; i < moduleAccount; i++ {
acc := ak.GetModuleAccount(ctx, distributionModuleName)
mAcc := simtypes.Account{
Address: acc.GetAddress(),

View File

@ -148,17 +148,14 @@ func (suite *SimTestSuite) TestSimulateMsgMultiSend() {
}
func (suite *SimTestSuite) TestSimulateModuleAccountMsgSend() {
const (
accCount = 1
moduleAccCount = 1
)
const moduleAccount = 1
s := rand.NewSource(1)
r := rand.New(s)
accounts := suite.getTestingAccounts(r, accCount)
accounts := suite.getTestingAccounts(r, 1)
// execute operation
op := simulation.SimulateMsgSendToModuleAccount(suite.txConfig, suite.accountKeeper, suite.bankKeeper, moduleAccCount)
op := simulation.SimulateMsgSendToModuleAccount(suite.txConfig, suite.accountKeeper, suite.bankKeeper, moduleAccount)
s = rand.NewSource(1)
r = rand.New(s)
@ -176,17 +173,14 @@ func (suite *SimTestSuite) TestSimulateModuleAccountMsgSend() {
}
func (suite *SimTestSuite) TestSimulateMsgMultiSendToModuleAccount() {
const (
accCount = 2
mAccCount = 2
)
const mAccount = 2
s := rand.NewSource(1)
r := rand.New(s)
accounts := suite.getTestingAccounts(r, accCount)
accounts := suite.getTestingAccounts(r, 2)
// execute operation
op := simulation.SimulateMsgMultiSendToModuleAccount(suite.txConfig, suite.accountKeeper, suite.bankKeeper, mAccCount)
op := simulation.SimulateMsgMultiSendToModuleAccount(suite.txConfig, suite.accountKeeper, suite.bankKeeper, mAccount)
operationMsg, futureOperations, err := op(r, suite.app.BaseApp, suite.ctx, accounts, "")
suite.Require().Error(err)

View File

@ -28,7 +28,7 @@ func NewMintingRestrictionTestHelper() *MintingRestrictionTestHelper {
return &MintingRestrictionTestHelper{Calls: make([]*MintingRestrictionArgs, 0, 2)}
}
// RecordCall makes note that the provided args were used as a funcion call.
// RecordCall makes note that the provided args were used as a function call.
func (s *MintingRestrictionTestHelper) RecordCall(name string, coins sdk.Coins) {
s.Calls = append(s.Calls, s.NewArgs(name, coins))
}
@ -412,7 +412,7 @@ func NewSendRestrictionTestHelper() *SendRestrictionTestHelper {
return &SendRestrictionTestHelper{Calls: make([]*SendRestrictionArgs, 0, 2)}
}
// RecordCall makes note that the provided args were used as a funcion call.
// RecordCall makes note that the provided args were used as a function call.
func (s *SendRestrictionTestHelper) RecordCall(name string, fromAddr, toAddr sdk.AccAddress, coins sdk.Coins) {
s.Calls = append(s.Calls, s.NewArgs(name, fromAddr, toAddr, coins))
}

View File

@ -149,7 +149,7 @@ func (k Keeper) AllocateTokensToValidator(ctx context.Context, val sdk.Validator
}
// sendDecimalPoolToCommunityPool sends the decimal pool to the community pool
// Any remainer stays in the decimal pool
// Any remainder stays in the decimal pool
func (k Keeper) sendDecimalPoolToCommunityPool(ctx context.Context) error {
feePool, err := k.FeePool.Get(ctx)
if err != nil {

View File

@ -24,7 +24,7 @@ var (
// Key format:
// - <0x01><exp_bytes><len(grantee_address_bytes)><grantee_address_bytes><len(granter_address_bytes)><granter_address_bytes>
func FeeAllowancePrefixQueue(exp *time.Time, granterAddrBz []byte) []byte {
// no need of appending len(exp_bytes) here, `FormatTimeBytes` gives const length everytime.
// no need of appending len(exp_bytes) here, `FormatTimeBytes` gives const length every time.
var key []byte
key = append(key, FeeAllowanceQueueKeyPrefix...)
key = append(key, sdk.FormatTimeBytes(*exp)...)

View File

@ -54,7 +54,7 @@ func TestAddGenesisAccountCmd(t *testing.T) {
},
{
name: "with keyring",
addr: "ser",
addr: "set",
denom: "1000atom",
withKeyring: true,
expectErr: false,

View File

@ -245,7 +245,7 @@ There are three parameters that define if the deposit of a proposal should be bu
### Constitution
`Constitution` is found in the genesis state. It is a string field intended to be used to descibe the purpose of a particular blockchain, and its expected norms. A few examples of how the constitution field can be used:
`Constitution` is found in the genesis state. It is a string field intended to be used to describe the purpose of a particular blockchain, and its expected norms. A few examples of how the constitution field can be used:
* define the purpose of the chain, laying a foundation for its future development
* set expectations for delegators
@ -262,7 +262,7 @@ Since this is more of a social feature than a technical feature, we'll now get i
* What is the purpose of the chain, specifically?
* best example of this is the Cosmos hub, where different founding groups, have different interpertations of the purpose of the network.
This genesis entry, "constitution" hasn't been designed for existing chains, who should likely just ratify a constitution using their governance system. Instead, this is for new chains. It will allow for validators to have a much clearer idea of purpose and the expecations placed on them while operating thier nodes. Likewise, for community members, the constitution will give them some idea of what to expect from both the "chain team" and the validators, respectively.
This genesis entry, "constitution" hasn't been designed for existing chains, who should likely just ratify a constitution using their governance system. Instead, this is for new chains. It will allow for validators to have a much clearer idea of purpose and the expecations placed on them while operating their nodes. Likewise, for community members, the constitution will give them some idea of what to expect from both the "chain team" and the validators, respectively.
This constitution is designed to be immutable, and placed only in genesis, though that could change over time by a pull request to the cosmos-sdk that allows for the constitution to be changed by governance. Communities whishing to make amendments to their original constitution should use the governance mechanism and a "signaling proposal" to do exactly that.

View File

@ -205,7 +205,7 @@ func simulateMsgSubmitProposal(
// column 3: 75% vote
// column 4: 40% vote
// column 5: 15% vote
// column 6: noone votes
// column 6: no one votes
// All columns sum to 100 for simplicity, values chosen by @valardragon semi-arbitrarily,
// feel free to change.
numVotesTransitionMatrix, _ := simulation.CreateTransitionMatrix([][]int{
@ -640,7 +640,7 @@ func randomProposalID(r *rand.Rand, k *keeper.Keeper, ctx sdk.Context, status v1
proposalID = uint64(simtypes.RandIntBetween(r, int(initialProposalID), int(proposalID)))
default:
// This is called on the first call to this funcion
// This is called on the first call to this function
// in order to update the global variable
initialProposalID = proposalID
}

View File

@ -192,13 +192,13 @@ func (p Params) ValidateBasic() error {
minInitialDepositRatio, err := sdkmath.LegacyNewDecFromStr(p.MinInitialDepositRatio)
if err != nil {
return fmt.Errorf("invalid mininum initial deposit ratio of proposal: %w", err)
return fmt.Errorf("invalid minimum initial deposit ratio of proposal: %w", err)
}
if minInitialDepositRatio.IsNegative() {
return fmt.Errorf("mininum initial deposit ratio of proposal must be positive: %s", minInitialDepositRatio)
return fmt.Errorf("minimum initial deposit ratio of proposal must be positive: %s", minInitialDepositRatio)
}
if minInitialDepositRatio.GT(sdkmath.LegacyOneDec()) {
return fmt.Errorf("mininum initial deposit ratio of proposal is too large: %s", minInitialDepositRatio)
return fmt.Errorf("minimum initial deposit ratio of proposal is too large: %s", minInitialDepositRatio)
}
proposalCancelRate, err := sdkmath.LegacyNewDecFromStr(p.ProposalCancelRatio)

View File

@ -85,7 +85,7 @@ A decision policy is the mechanism by which members of a group can vote on
proposals, as well as the rules that dictate whether a proposal should pass
or not based on its tally outcome.
All decision policies generally would have a mininum execution period and a
All decision policies generally would have a minimum execution period and a
maximum voting window. The minimum execution period is the minimum amount of time
that must pass after submission in order for a proposal to potentially be executed, and it may
be set to 0. The maximum voting window is the maximum time after submission that a proposal may
@ -210,7 +210,7 @@ Proposals and votes are automatically pruned to avoid state bloat.
Votes are pruned:
* either after a successful tally, i.e. a tally whose result passes the decision
policy's rules, which can be trigged by a `Msg/Exec` or a
policy's rules, which can be triggered by a `Msg/Exec` or a
`Msg/{SubmitProposal,Vote}` with the `Exec` field set,
* or on `EndBlock` right after the proposal's voting period end. This applies to proposals with status `aborted` or `withdrawn` too.

Some files were not shown because too many files have changed in this diff Show More