Commit Graph

380 Commits

Author SHA1 Message Date
Csongor Kiss abbed8593e Fix simapp compilation
The WormholeKeeper is just set to nil so we don't incur a circular
dependency. The simapp test doesn't use that keeper anyway
2022-07-22 14:11:24 -05:00
HaeSung bf7348e631
fix: defaultGenTxGas to 10 times (#12314) 2022-06-21 09:48:54 -04:00
mergify[bot] a3f8a83ec4
chore(types): add MustAccAddressFromBech32 util func (backport #12201) (#12205) 2022-06-09 15:01:04 -04:00
mergify[bot] d721a760d8
refactor: Simplify SimulationManager setup (backport #12153) (#12159)
* refactor: Simplify SimulationManager setup (#12153)

(cherry picked from commit 544afb65e2)

# Conflicts:
#	CHANGELOG.md
#	simapp/app.go

* fix conflict

* fix conflict

Co-authored-by: Dev Ojha <ValarDragon@users.noreply.github.com>
Co-authored-by: Julien Robert <julien@rbrt.fr>
2022-06-07 13:40:39 +02:00
mergify[bot] 53396c8bec
fix: Added description of how to run the unsafe-reset-all command in simapp README (#11718) (#11719)
* Fix simapp README

* Revised review content

Co-authored-by: Julien Robert <julien@rbrt.fr>
(cherry picked from commit d5e0b86a07)

Co-authored-by: Takahiko Tominaga <57429437+takapi327@users.noreply.github.com>
2022-04-22 10:28:29 +02:00
Robert Zaremba 8236b26419
chore: move server.GenerateCoinKey and server.GenerateSaveCoinKey to testutil (#10956)
* chore: move server.GenerateCoinKey and server.GenerateSaveCoinKey to testutil

* add changelog

* move testutil/known_values.go to testutil/testdata

* changelog
2022-01-18 15:37:05 +01:00
mergify[bot] 90ffbce410
feat: support custom mnemonics in in-process testing network (backport #10922) (#10934) 2022-01-13 15:32:07 -05:00
mergify[bot] 8932338504
feat: support in-place migration ordering (backport #10614) (#10890)
* feat: support in-place migration ordering (#10614)

## Description

Closes: #10604

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)

(cherry picked from commit da929211d6)

# Conflicts:
#	CHANGELOG.md
#	docs/core/upgrade.md
#	types/errors/errors.go
#	types/module/module.go

* conflict fix

* Add Features section

* fix conflicts

Co-authored-by: Robert Zaremba <robert@zaremba.ch>
2022-01-06 01:05:01 +01:00
mergify[bot] a0503e5595
fix: Panic if SetOrder* functions forgot modules (backport #10711) (#10762)
* fix: Panic if SetOrder* functions forgot modules (#10711)

<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

fixes: #10708

Panic at startup if chain devs forgot to add some modules in SetOrder* functions.

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)

(cherry picked from commit d3a8e1e953)

# Conflicts:
#	CHANGELOG.md
#	simapp/app.go

* fix conflicss

* Fix build

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
2022-01-03 15:24:03 +01:00
mergify[bot] 8a9589a8de
style: lint go and markdown (backport #10060) (#10473)
* style: lint go and markdown (#10060)

## Description

+ fixing `x/bank/migrations/v44.migrateDenomMetadata` - we could potentially put a wrong data in a new key if the old keys have variable length.
+ linting the code

Putting in the same PR because i found the issue when running a linter.

Depends on: #10112

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [x] added `!` to the type prefix if API or client breaking change
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [x] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)

(cherry picked from commit 479485f95d)

# Conflicts:
#	CODING_GUIDELINES.md
#	CONTRIBUTING.md
#	STABLE_RELEASES.md
#	contrib/rosetta/README.md
#	cosmovisor/README.md
#	crypto/keyring/keyring.go
#	db/README.md
#	docs/404.md
#	docs/DOCS_README.md
#	docs/architecture/adr-038-state-listening.md
#	docs/architecture/adr-040-storage-and-smt-state-commitments.md
#	docs/architecture/adr-043-nft-module.md
#	docs/architecture/adr-044-protobuf-updates-guidelines.md
#	docs/architecture/adr-046-module-params.md
#	docs/migrations/pre-upgrade.md
#	docs/migrations/rest.md
#	docs/ru/README.md
#	docs/run-node/rosetta.md
#	docs/run-node/run-node.md
#	docs/run-node/run-testnet.md
#	go.mod
#	scripts/module-tests.sh
#	snapshots/README.md
#	store/streaming/README.md
#	store/streaming/file/README.md
#	store/v2/flat/store.go
#	store/v2/smt/store.go
#	x/auth/ante/sigverify.go
#	x/auth/middleware/basic.go
#	x/auth/spec/01_concepts.md
#	x/auth/spec/05_vesting.md
#	x/auth/spec/07_client.md
#	x/authz/spec/05_client.md
#	x/bank/spec/README.md
#	x/crisis/spec/05_client.md
#	x/distribution/spec/README.md
#	x/epoching/keeper/keeper.go
#	x/epoching/spec/03_to_improve.md
#	x/evidence/spec/07_client.md
#	x/feegrant/spec/README.md
#	x/gov/spec/01_concepts.md
#	x/gov/spec/07_client.md
#	x/group/internal/orm/spec/01_table.md
#	x/mint/spec/06_client.md
#	x/slashing/spec/09_client.md
#	x/slashing/spec/README.md
#	x/staking/spec/09_client.md
#	x/upgrade/spec/04_client.md

* fix conflicts

* remove unnecessary files

Co-authored-by: Robert Zaremba <robert@zaremba.ch>
2021-11-11 21:29:29 +01:00
mergify[bot] fece3f0485
fix: --home flag parsing (backport #10226) (#10271)
* fix: --home flag parsing (#10226)

<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

Closes: #XXXX

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [x] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [x] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [x] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [x] reviewed state machine logic
- [x] reviewed API design and naming
- [x] reviewed documentation is accurate
- [x] reviewed tests and test coverage
- [x] manually tested (if applicable)

(cherry picked from commit cc1a1c8cd0)

# Conflicts:
#	CHANGELOG.md

* merge conflicts

Co-authored-by: Arijit Das <arijitad.in@gmail.com>
Co-authored-by: Amaury M <1293565+amaurym@users.noreply.github.com>
2021-10-04 12:57:06 +02:00
Robert Zaremba 3ee70996bf
fix(CI): add golangci-lint to dependencies (#10112) (#10172)
* fix(CI): add golangci-lint to dependencies (#10112)

* fix(CI): add golangci-lint to dependencies

* update github workflow

* tidy go.mod

* add missing entries to go.mod

* update deps

* add missing run command

* remove golint and use revive instead

* fix workflow setup

* lint only changed files

* gofmt go tags

* update comments

* make lint-go

Co-authored-by: Marko <marbar3778@yahoo.com>
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>

* Update .golangci.yml

* Update .golangci.yml

* fix go.mod

Co-authored-by: Marko <marbar3778@yahoo.com>
Co-authored-by: Federico Kunze Küllmer <31522760+fedekunze@users.noreply.github.com>
2021-09-17 00:34:36 +02:00
mergify[bot] 1e4f5619f8
fix: use keyring in config for add-genesis-account cmd (backport #9969) (#10181)
* fix: use keyring in config for add-genesis-account cmd (#9969)

<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

ref: #9644

+use the keyring backend (if specified) in the binary config for the add-genesis-account command
+update existing test to check for the case of keyring in config

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [ ] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)

(cherry picked from commit cdf6196a7e)

* add changelog entry

Co-authored-by: Tyler <48813565+technicallyty@users.noreply.github.com>
Co-authored-by: Robert Zaremba <robert@zaremba.ch>
2021-09-16 23:42:32 +02:00
mergify[bot] 650ccdb927
fix!: Capability Issue on Restart, Backport to v0.43 (backport #9836) (#9841)
* fix!: Capability Issue on Restart, Backport to v0.43 (#9836)

<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

Closes: #9800

The following is a breaking fix to #9800. In the non-breaking fix, the initialization logic was moved out of `InitializeAndSeal` but the API was preserved. I've now removed `InitializeAndSeal` and replaced it with just the `Seal` function, which may be called much more cleanly in `app.go`

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [x] added `!` to the type prefix if API or client breaking change
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [x] provided a link to the relevant issue or specification
- [x] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [x] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [x] added a changelog entry to `CHANGELOG.md`
- [x] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [x] updated the relevant documentation or specification
- [x] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)

(cherry picked from commit 7f316adb97)

# Conflicts:
#	CHANGELOG.md

* solve conflicts

Co-authored-by: Aditya <adityasripal@gmail.com>
Co-authored-by: Robert Zaremba <robert@zaremba.ch>
2021-08-04 13:51:39 +02:00
Andrei Ivasko 3fd376bd56
feat: Non-zero Default Fees (#9371)
<!-- < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < ☺
v                               ✰  Thanks for creating a PR! ✰
v    Before smashing the submit button please review the checkboxes.
v    If a checkbox is n/a - please still include it but + a little note why
☺ > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >  -->

## Description

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review.
-->

closes: #9106

---

Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.

- [x] Targeted PR against correct branch (see [CONTRIBUTING.md](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [ ] Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
- [ ] Code follows the [module structure standards](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules/structure.md).
- [ ] Wrote unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] Updated relevant documentation (`docs/`) or specification (`x/<module>/spec/`)
- [ ] Added relevant `godoc` [comments](https://blog.golang.org/godoc-documenting-go-code).
- [ ] Added a relevant changelog entry to the `Unreleased` section in `CHANGELOG.md`
- [ ] Re-reviewed `Files changed` in the Github PR explorer
- [ ] Review `Codecov Report` in the comment section below once CI passes
2021-06-25 10:41:32 +00:00
Anil Kumar Kammari 1c77766717
feat: Allow app developers to override default appConfig template (#9550)
<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

Closes: #5540

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] added `!` to the type prefix if API or client breaking change
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [x] provided a link to the relevant issue or specification
- [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [x] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [x] updated the relevant documentation or specification
- [x] reviewed "Files changed" and left comments if necessary
- [x] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed 
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
2021-06-23 08:42:39 +00:00
Ryan Christoffersen 0ae07fe69c
fix: duplicate vesting and format (#9535)
<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

This pull request fixes the duplicate `vesting` command displayed with `--help` for the `tx` command. It also removes line breaks for consistent formatting across all commands and it fixes a minor typo.

## Manual Test

```
make build
```

```
./build/simd tx -h
```

```
./build/simd tx vesting -h
```

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [x] added `!` to the type prefix if API or client breaking change - *n/a*
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [x] provided a link to the relevant issue or specification - *n/a*
- [x] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules) - *n/a*
- [x] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [x] added a changelog entry to `CHANGELOG.md`
- [x] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [x] updated the relevant documentation or specification
- [x] reviewed "Files changed" and left comments if necessary
- [x] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed 
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
2021-06-18 01:50:37 +00:00
Tyler 179c819a9d
fix: testnet cli command update genesis supply (#9497)
<!--
The default pull request template is for types feat, fix, or refactor.
For other templates, add one of the following parameters to the url:
- template=docs.md
- template=other.md
-->

## Description

closes: #9372 

<!-- Add a description of the changes that this PR introduces and the files that
are the most critical to review. -->

### This PR makes the `testnet` command update the bank genesis supply. 

When using the `testnet` cli command, it creates nodes and balances, but does **not** update the supply. When using this in conjunction with `add-genesis-account` which **does** update the supply, it creates an invalid genesis file. This PR updates the testnet command to properly set the supply.

---

### Author Checklist

*All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.*

I have...

- [x] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [x] added `!` to the type prefix if API or client breaking change
- [x] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting))
- [x] provided a link to the relevant issue or specification
- [x] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules)
- [ ] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing)
- [ ] added a changelog entry to `CHANGELOG.md`
- [ ] included comments for [documenting Go code](https://blog.golang.org/godoc)
- [ ] updated the relevant documentation or specification
- [x] reviewed "Files changed" and left comments if necessary
- [ ] confirmed all CI checks have passed

### Reviewers Checklist

*All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.*

I have...

- [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title
- [ ] confirmed `!` in the type prefix if API or client breaking change
- [ ] confirmed all author checklist items have been addressed 
- [ ] reviewed state machine logic
- [ ] reviewed API design and naming
- [ ] reviewed documentation is accurate
- [ ] reviewed tests and test coverage
- [ ] manually tested (if applicable)
2021-06-14 09:56:25 +00:00
Robert Zaremba 7bca49e2d2
refactor(client): add client/Context.Codec and deprecate JSONCodec (#9498)
* chore(types): add sdk.Context.Codec and deprecate JSONCodec

* Use clientContext.Codec rather than JSONCodec everywhere

* update tests to use clientContext.Codec

* added a note that EncodingConfig.Marshaler will be renamed to Codec

* update changelog

* fix tests to use clientCtx.WithCodec instead of WithJSONCodec

* fix genutil build

* Update simapp/params/encoding.go

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
2021-06-11 11:49:39 +00:00
likhita-809 f1ec0e2193
fix: Fix testnet command (#9454)
* accept hyphen in node-dir-prefix flag for testnet and change `node-dir-prefixtoken` to `testtoken`

* remove unnecessary use of fmt.Sprintf in simapp/simd/cmd/testnet.go

* add changelog

* add  changelog

* remove unrelated changelog
2021-06-03 15:08:21 +00:00
Aleksandr Bezobchuk 80330ec17c
fix: update simapp to use correct default broadcast mode (#9408) 2021-05-28 09:17:50 -04:00
Ryan Christoffersen cb66c99eab
chore: add markdownlint to lint commands (#9353)
* add markdownlint config

* update make lint commands

* update markdownlint config

* run make lint-fix

* fix empty link

* resuse docker container

* run lint-fix

* do not echo commands

Co-authored-by: ryanchrypto <12519942+ryanchrypto@users.noreply.github.com>
2021-05-27 15:31:04 +00:00
Robert Zaremba 8c1fe4b166
test: fix mockgen version (#9127)
* setup: update mockgen

* Add expect ConsensusVersion in app_test

* fix ChainAnteDecorators tests

* remove types/handler.go from autogenerating mocks

* adding a note

* adding note

Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Marko <marbar3778@yahoo.com>
2021-05-25 09:18:59 +00:00
Ryan Christoffersen 8669f0b4b9
docs: update simapp instructions (#9374)
* update simapp instructions

* fix typo and amount

Co-authored-by: ryanchrypto <12519942+ryanchrypto@users.noreply.github.com>
Co-authored-by: Marko <marbar3778@yahoo.com>
2021-05-25 07:36:03 +00:00
Marie Gauthier 9d0504808a
SDK Core Audit - simapp updates (#9315)
* Make package imports consistent

* Update comment

* Update FundAccount/FundModuleAccount

* Fix bench test

Co-authored-by: atheeshp <59333759+atheeshp@users.noreply.github.com>
2021-05-17 15:42:44 +00:00
Prathyusha Lakkireddy d7dd1d7aff
Fixed parse key issue (#9299)
* Fixed parse key issue

* Added getconfig in root command

* uncommented changes in parse.go
2021-05-12 15:19:27 +00:00
Marie Gauthier 3582ccef7c
Move x/feegrant/types to x/feegrant (#9273)
* Move x/feegrant/types to x/feegrant

* Update spec

* Use feegrantmodule
2021-05-07 07:10:47 +00:00
Robert Zaremba 59810f3286
x/authz: audit updates (#9042)
* x/authz: audit updates

* audit with Aaron

* authz: Update Authorization.Accept method

* authz: add event proto definitions

* update query service

* authz: use typed events

* refactore and rename query authorizations

* remve Authorization infix from proto services

* renames wip

* refactoring

* update tests

* fix compilation

* fixing gRPC query tests

* fix simulation tests

* few renames

* more refactore

* add missing file

* moving export genesis to keeper

* Update docs

* update tests

* rename event Msg attribute to MsgTypeURL

* Upate Authorization interface

* rollback Makefile changes

* fix tests

* Apply suggestions from code review

Co-authored-by: Aaron Craelius <aaron@regen.network>

* renames

* refactore authz/exported

* lint fix

* authz/types refactore

* comment update

* conflict updates

* Apply suggestions from code review

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>

* authz: move storage keys to keeper

* review updates

* docs update

* Update x/authz/client/cli/query.go

Co-authored-by: Aaron Craelius <aaron@regen.network>

* move codec to the root package

* authz CMD info update

* comment update

* update imports and build flags

* fix functional tests

* update proto comment

* fix tests

* fix test

Co-authored-by: Aaron Craelius <aaron@regen.network>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
2021-05-06 18:23:48 +00:00
Amaury d19791be89
Rename clientCtx.JSONMarshaler to JSONCodec (#9251)
* Rename clientCtx.JSONMarshaler to JSONCodec

* change md files

* Fix lint
2021-05-03 14:45:47 +00:00
Robert Zaremba be4a965599
codec: Rename codec and marshaler interfaces (#9226)
* codec: Rename codec and marshaler interfaces, ref: 8413

* codec: remove BinaryBare

* changelog update

* Update comments and documentation

* adding doc string comments

* Update CHANGELOG.md

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>

* Update codec/codec.go

Co-authored-by: Marko <marbar3778@yahoo.com>

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Marko <marbar3778@yahoo.com>
2021-04-29 10:46:22 +00:00
Sunny Aggarwal bffcae54a1
Add hooks to governance actions (#9133)
* add governance hooks

* fix lint

* fix lint

* CHANGELOG

* sh -> gh

* improve comments

* add test

* add more tests

* rename two of the hooks

Co-authored-by: ahmedaly113 <ahmedaly113@outlook.com>
2021-04-21 12:59:30 -04:00
Riccardo Montagnin 96fe999343
Set proper default command output (#8628)
* Set proper default command output

* Removed duplicated cmd.SetErr(cmd.ErrOrStderr()) and cmd.SetOut(cmd.OutOrStdout())

* Moved command initialization and added CHANGELOG

* fix: groom all uses of cmd.Print*

* Ran make format

Co-authored-by: Michael FIG <mfig@agoric.com>
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
2021-04-17 00:21:32 +00:00
technicallyty 3ebf06ce0d
module/types code hygiene - utilize map access 2nd return value (#9098)
* update docs/code to utilize map access return values

* remove mock module in fromVM to simulate truly non-existent module

* update test docs to refelect change

Co-authored-by: technicallyty <48813565+tytech3@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2021-04-13 19:00:04 +00:00
Andrei Ivasko a465ae182c
Add env variable to cmd flags (#9040)
* first draft

* add tests in config_test package

* refactored, all tests pass, r4r

* ready for review

* add envPrefix

* Update simapp/simd/cmd/root.go

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>

* fix linter issues

* minor fixes

Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2021-04-13 17:32:08 +00:00
Sunny Aggarwal 05e2e45010 merged in master 2021-04-06 19:19:59 -04:00
Amaury 5d13b1fc63
InitGenesis in migrations when fromVersion==0 (#9007)
* InitGenesis in migrations when fromVersion==0

* Add test

* Fix test

* Fix comment

* cdc=>codec

* Don't break Configurator

* Remove method

* Add comments

* Add more comments

* Update types/module/module.go

Co-authored-by: technicallyty <48813565+technicallyty@users.noreply.github.com>

* Update types/module/module.go

Co-authored-by: technicallyty <48813565+technicallyty@users.noreply.github.com>

* Update types/module/module.go

Co-authored-by: technicallyty <48813565+technicallyty@users.noreply.github.com>

Co-authored-by: technicallyty <48813565+technicallyty@users.noreply.github.com>
2021-04-02 15:41:35 +00:00
technicallyty e3a0148bf6
x/upgrade: protocol version tracking (#8897)
* -added consensus version tracking to x/upgrade

* -added interface to module manager -added e2e test for migrations using consensus version store in x/upgrade -cleaned up x/upgrade Keeper -handler in apply upgrade now handles errors and setting consensus versions -cleaned up migration map keys -removed init chainer method -simapp now implements GetConsensusVersions to assist with testing

* protocol version p1

* add protocol version to baseapp

* rebase against master

* add test

* added test case

* cleanup

* docs and change to bigendian

* changelog

* cleanup keeper

* swap appVersion and version

* cleanup

* change interface id

* update keeper field name to versionSetter

* reorder keys and docs

* -move interface into exported folder

* typo

* typo2

* docs on keeper fields

* docs for upgrade NewKeeper

* cleanup

* NewKeeper docs

Co-authored-by: technicallyty <48813565+tytech3@users.noreply.github.com>
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
2021-04-02 07:11:58 -07:00
Andrei Ivasko 410d8edb38
Add client config subcommand to CLI (#8953)
* add client config

* addressed reviewers comments

* refactored,ready for review

* fixed linter issues and addressed reviewers comments

* Bump golangci-lint

* fix linter warnings

* fix some tests

Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
2021-03-31 12:04:33 +02:00
Amaury 1fa2c22d8a
Prefer sending tx_bytes to Simulate gRPC endpoint (#8926)
* First run

* Remove dead code

* Make test pass

* Proto gen

* Fix lint

* Add changelog

* Fix tests

* Fix test

* Update x/auth/tx/service.go

Co-authored-by: Marie Gauthier <marie.gauthier63@gmail.com>

* Remove protoTxProvider

* Add grpc-gateway test

* Add comment

* move to api breaking

* lesser diff

* remove conflict

* empty commit to rerun CI

* empty commit to rerun CI

Co-authored-by: Marie Gauthier <marie.gauthier63@gmail.com>
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2021-03-25 10:52:54 +00:00
Aleksandr Bezobchuk 56c312a979
Merge pull request from GHSA-2f3p-6gfj-jccq
* x/bank: update SendCoinsFromModuleToAccount

* x/bank: add TestSendCoinsFromModuleToAccount_Blacklist

* CL++

* fix tests

* godoc++
2021-03-24 12:05:33 -04:00
atheeshp 025d226099
move feegrant ante to auth ante (#8682)
* move feegrant ante to auth ante

* update ante builder

* remove commented code

* review changes

* fix lint

* review changes

* review changes

* review changes

* review changes

* fix ante builder

* review changes

* update ante builder with options struct

* review changes

* review changes

* add changelog

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Aaron Craelius <aaron@regen.network>
2021-03-23 07:31:09 +00:00
Sunny Aggarwal 1f99aa3fb2 merged in master 2021-03-21 16:37:06 -04:00
technicallyty 5bd93bfe7b
x/upgrade: added consensus version tracking (part of ADR-041) (#8743)
* -added consensus version tracking to x/upgrade

* -added interface to module manager -added e2e test for migrations using consensus version store in x/upgrade -cleaned up x/upgrade Keeper -handler in apply upgrade now handles errors and setting consensus versions -cleaned up migration map keys -removed init chainer method -simapp now implements GetConsensusVersions to assist with testing

* Changed MigrationMap identifier to VersionMap
removed module_test

* updated docs

* forgot this

* added line to changelog for this PR

* Change set consensus version function to match adr 041 spec

* add documentation

* remove newline from changelog

unnecessary newline removed

* updated example in simapp for RunMigrations, SetCurrentConsensusVersions now returns an error

* switch TestMigrations to use Require instead of t.Fatal

* Update CHANGELOG.md

Co-authored-by: Aaron Craelius <aaron@regen.network>

* docs for SetVersionManager

* -init genesis method added -removed panics/fails from setting consensus versions

* update identifiers to be more go-like

* update docs and UpgradeHandler fnc sig

* Upgrade Keeper now takes a VersionMap instead of a VersionManager interface

* upgrade keeper transition to Version Map

* cleanup, added versionmap return to RunMigrations

* quick fix

* Update docs/architecture/adr-041-in-place-store-migrations.md

Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>

* remove support for versionmap field on upgrade keeper

* cleanup

* rename get/set version map keeper functions

* update adr doc to match name changes

* remove redudant line

Co-authored-by: technicallyty <48813565+tytech3@users.noreply.github.com>
Co-authored-by: Aaron Craelius <aaron@regen.network>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2021-03-19 22:01:29 +00:00
Hanjun Kim 0836361c0e
Fix typo (#8905)
Co-authored-by: Marko <marbar3778@yahoo.com>
2021-03-17 09:53:51 +00:00
Aleksandr Bezobchuk e73cf2b410
Merge pull request from GHSA-mvm6-gfm2-89xj
Co-authored-by: Alessio Treglia <alessio@tendermint.com>
2021-03-10 22:31:21 +00:00
colin axnér da064e13d5
Remove IBC from the SDK (#8735) 2021-03-04 13:11:34 +00:00
Cuong Manh Le 91affb5167
simapp, types: fix benchmarks panics by honoring skip if set (#8763)
- BenchmarkAccAddressString must initialize the index less than ed25519.PubKeySize to avoid panics
 - BenchmarkFullAppSimulation should be skipped as it has the same logic as tests

Fixes #8762
2021-03-03 03:54:14 -08:00
colin axnér 1c6e267964
Remove IBC logic from x/upgrade (#8673)
* add zeroed custom fields check to tm client

* remove custom fields function from x/upgrade and fix tests

* use []byte in x/upgrade, move abci to 02-client

* remove x/ibc from types

* whoops, delete testing files

* fix upgrade tests

* fix tm tests

* fix tests

* update CHANGELOG

* revert proto breakage, use reserved field cc @amaurym

* add IBC Upgrade Proposal type

* remove IBC from upgrade types

* add IBC upgrade logic to 02-client

* fix all tests for x/upgrade

* Add CLI for IBC Upgrade Proposal

* Update x/ibc/core/02-client/types/proposal_test.go

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>

* add gRPC for upgraded client state

* test fixes

* add HandleUpgradeProposal tests

* update docs and remove unnecessary code

* self review bug and test fixes

* neatness

* construct empty rest handler

* fix tests

* fix stringer tests

* Update docs/core/proto-docs.md

Co-authored-by: Christopher Goes <cwgoes@pluranimity.org>

* add key in ibc store tracking ibc upgrade heights

Add a new Key to the IBC client store to track the IBC Upgrade Height. This allows IBC upgrades to correctly remove old IBC upgrade states

* update abci and tests

* revert key storage after discussion with @AdityaSripal

Revert using a key to track IBC upgrades. By clearing any IBC state using an old plan in ScheduleUpgrade, IBC upgrades do not need to be tracked by IBC. This reduces code complexity and reduces potential for bugs.

* clear IBC states on cancelled upgrades

Co-authored-by: Federico Kunze <31522760+fedekunze@users.noreply.github.com>
Co-authored-by: Christopher Goes <cwgoes@pluranimity.org>
2021-03-01 16:28:54 +00:00
Amaury ba74a7c737
x{stake,slash,gov,distrib} In-place Store Migrations (#8504)
* Add 1st version of migrate

* Put migration logic into Configurator

* add test to bank store migration

* add test for configurator

* Error if no migration found

* Remove RunMigrations from Configurator interface

* Update spec

* Rename folders

* copy-paste from keys.go

* Fix nil map

* rename function

* Update simapp/app.go

Co-authored-by: Robert Zaremba <robert@zaremba.ch>

* Update simapp/app_test.go

Co-authored-by: Robert Zaremba <robert@zaremba.ch>

* Adderss reviews

* Fix tests

* Update testutil/context.go

Co-authored-by: Robert Zaremba <robert@zaremba.ch>

* Update docs for ConsensusVersion

* Rename to forVersion

* Fix tests

* Check error early

* Return 1 for intiial version

* Use MigrationKeeper

* Fix test

* Revert adding marshaler to Configurator

* Godoc updates

* Update docs

* Add distrib legacy folder

* Add tests for distrib migration

* Add gov migrations

* Copy paste whole keys file

* Add gov migrations

* Add staking

* Fix staking tests

* Update spec and module.go

* Update to latest changes

* Update migration scripts

* capability to 1

* Fix tests

* Add package godoc

* Remove whitespace

* Remove global

* Use Migrator

* Remove 042 keys files

* Fix build

* Unlambda

* Rename to Migrate1to2

Co-authored-by: Robert Zaremba <robert@zaremba.ch>
2021-02-25 10:43:31 +00:00
SaReN 77668a3c23
Add multisign batch command (#7787)
* initial commit

* update signing data

* Update signature

* code cleanup

* code cleanup

* Add test for ms batch

* update test

* add build flag

* update flags

* update tests

* add test for signbatch multisig

* update test

* fix sign batch multisig

* add test

* update offline usage

* update with sign batch fix

* fix lint

* update tests

* update test

* update tests

* fix signature only

* update seq

* fix conflicts

* update multisign

* revert unintended

* fix tests

* rename flags

* code refactor

* fix typo

* update docs

* update test

* Update x/auth/client/cli/tx_multisign.go

* use named return values and explicit return

* Update x/auth/client/cli/tx_multisign.go

Co-authored-by: Robert Zaremba <robert@zaremba.ch>

* Update x/auth/client/cli/tx_multisign.go

Co-authored-by: Robert Zaremba <robert@zaremba.ch>

Co-authored-by: Alessio Treglia <alessio@tendermint.com>
Co-authored-by: Jonathan Gimeno <jonathan@tendermint.com>
Co-authored-by: Jonathan Gimeno <jgimeno@gmail.com>
Co-authored-by: Robert Zaremba <robert@zaremba.ch>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
2021-02-24 19:56:10 +00:00