Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: support custom tx config and sign modes #10553

Closed
wants to merge 3 commits into from

Conversation

fedekunze
Copy link
Collaborator

Description

Closes: #XXXX

Currently, the SDK supports a custom TxConfig interface. Nevertheless, the concrete types are private, so a chain that wants to implement a custom SignMode needs to fork the SDK or copy the individual modes from the SDK, which defeats the purpose of supporting an interface in the first place.

This PR fixes this Dev UX issue


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 docs: prefix in the PR title
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • followed the documentation writing guidelines
  • 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 docs: prefix in the PR title
  • confirmed all author checklist items have been addressed
  • confirmed that this PR only changes documentation
  • reviewed content for consistency
  • reviewed content for thoroughness
  • reviewed content for spelling and grammar
  • tested instructions (if applicable)

Copy link
Collaborator

@robert-zaremba robert-zaremba left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AmauryM will remember why the implementations were private.

// instance.
func NewSignModeLegacyAminoJSONHandler() signing.SignModeHandler {
return signModeLegacyAminoJSONHandler{}
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to expose that function?

@aaronc
Copy link
Member

aaronc commented Nov 16, 2021

Description

Closes: #XXXX

Currently, the SDK supports a custom TxConfig interface. Nevertheless, the concrete types are private, so a chain that wants to implement a custom SignMode needs to fork the SDK or copy the individual modes from the SDK, which defeats the purpose of supporting an interface in the first place.

But that's still the case even with this PR. The SignMode enum is part of the proto files and you would need to copy all of those and change them. There is currently not a good way to add custom sign modes and that's not really the intended design either. They're private for a reason. Sign modes are hard, error prone and really part of the core protocol.

Can you describe the sign mode you're trying to add?

@aaronc aaronc removed the T:Bug label Nov 16, 2021
@fedekunze
Copy link
Collaborator Author

@aaronc I'm trying to implement EIP191 to sign ethereum messages

@sunnya97
Copy link
Member

sunnya97 commented Nov 18, 2021

@fedekunze we have these implemented already actually

We will be upstreaming them soon

osmosis-labs#20

@aaronc
Copy link
Member

aaronc commented Nov 18, 2021

@aaronc I'm trying to implement EIP191 to sign ethereum messages

But how would that even work with the existing protobuf tx? I don't see how you could use the same transaction envelope at all

@fedekunze
Copy link
Collaborator Author

@sunnya97 the idea is to prevent breaking changes so that we can add them without forking the SDK

@aaronc
Copy link
Member

aaronc commented Nov 19, 2021

@sunnya97 the idea is to prevent breaking changes so that we can add them without forking the SDK

@fedekunze can you clarify if you're still using the underlying cosmos.tx.v1beta1.Tx envelope with EIP191?

Comment on lines +39 to +45
func CustomTxConfig(
handler signing.SignModeHandler,
decoder sdk.TxDecoder,
encoder sdk.TxEncoder,
jsonDecoder sdk.TxDecoder,
jsonEncoder sdk.TxEncoder,
protoCodec codec.ProtoCodecMarshaler,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can see wanting to add additional sign modes, but overloading all the decoders and encoders seems like a smell here.

@aaronc
Copy link
Member

aaronc commented Nov 19, 2021

@fedekunze we have these implemented already actually

We will be upstreaming them soon

osmosis-labs#20

As a first step I suggest reserving an enum case in https://github.com/cosmos/cosmos-sdk/blob/master/proto/cosmos/tx/signing/v1beta1/signing.proto#L10 with a small PR for this new sign mode. Then we can allow custom sign modes that don't have to be implemented in the SDK proper as @fedekunze is suggesting here. As long as the canonical SignMode enum lists all known sign modes I think that's fine even if they're not all implemented in the SDK.

@tac0turtle
Copy link
Member

@fedekunze do you want make the changes Aaron is suggesting?

@tac0turtle
Copy link
Member

closing this for now. @sunnya97 when you get a chance id love to coordinate upstreaming your work

@tac0turtle tac0turtle closed this Jan 24, 2022
@robert-zaremba
Copy link
Collaborator

let's handle it #11055

@fedekunze fedekunze deleted the fedekunze/custom-config branch February 9, 2022 14:16
@fedekunze fedekunze mentioned this pull request Apr 4, 2022
19 tasks
@fedekunze
Copy link
Collaborator Author

@aaronc I added the EIP191 sign mode as suggested: #11533

mergify bot pushed a commit that referenced this pull request Apr 5, 2022
## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: #10553 (comment)



---

### 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
- [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)
- [ ] 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)
mergify bot pushed a commit that referenced this pull request Apr 5, 2022
## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: #10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	go.sum
mergify bot pushed a commit that referenced this pull request Apr 5, 2022
## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: #10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go
amaury1093 pushed a commit that referenced this pull request Apr 5, 2022
* feat: EIP191 sign mode (#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: #10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
daeMOn63 pushed a commit to fetchai/cosmos-sdk that referenced this pull request Apr 26, 2022
* feat: EIP191 sign mode (#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos/cosmos-sdk#10553 (comment)
daeMOn63 added a commit to fetchai/cosmos-sdk that referenced this pull request Apr 27, 2022
* fix: add concurrency fence on traceContext to avoid data races (backport #11117) (#11139)

* fix: add concurrency fence on traceContext to avoid data races (#11117)

See #11114 for more info.

## Description

Closes: #11114

* feat: add get all versions (backport #11124) (#11144)

* feat: add get all versions (#11124)

* add get all versions

* add changelog entry

(cherry picked from commit d624a65)

# Conflicts:
#	CHANGELOG.md

* fix conflicts and remove interface break

Co-authored-by: Marko <[email protected]>

* support debug trace QueryResult (#11148)

Update types/errors/abci.go

Co-authored-by: Amaury <[email protected]>

Co-authored-by: Amaury <[email protected]>

* disable url parameter in swagger-ui page (backport #11202) (#11207)

* disable url parameter in swagger-ui page (#11202)

Closes: #11201
Solution:
- update swagger-ui to recent release
- add option `queryConfigEnabled: false`

(cherry picked from commit cb6fea9)

# Conflicts:
#	client/docs/statik/statik.go
#	client/docs/swagger-ui/swagger-ui-bundle.js
#	client/docs/swagger-ui/swagger-ui-bundle.js.map
#	client/docs/swagger-ui/swagger-ui-es-bundle-core.js
#	client/docs/swagger-ui/swagger-ui-es-bundle-core.js.map
#	client/docs/swagger-ui/swagger-ui-es-bundle.js
#	client/docs/swagger-ui/swagger-ui-es-bundle.js.map
#	client/docs/swagger-ui/swagger-ui-standalone-preset.js
#	client/docs/swagger-ui/swagger-ui-standalone-preset.js.map
#	client/docs/swagger-ui/swagger-ui.js
#	client/docs/swagger-ui/swagger-ui.js.map

* fix conflicts

* override swagger-ui after resolve conflicts

Co-authored-by: yihuang <[email protected]>
Co-authored-by: marbar3778 <[email protected]>

* feat: Allow to restrict MintCoins from app.go (backport #10771) (#11227)

* feat: Allow to restrict MintCoins from app.go (#10771)

## Description

Closes: cosmos/cosmos-sdk#10386

This PR adds feature to the bank module so that other modules using bankKeeper would be able to call the keeper with restricted permissions when minting coins. `WithMintCoinsRestriction` would be able to get called within app.go when setting keeper components for each individual keeper, taking a function that would validate minting denom as an argument.

The example below demonstrates adding bank module with restricted permissions.
```
	app.DistrKeeper = distrkeeper.NewKeeper(
		appCodec, keys[distrtypes.StoreKey], app.GetSubspace(distrtypes.ModuleName), app.AccountKeeper, app.BankKeeper.WithMintCoinsRestriction(DistributionMintingRestriction),
		&stakingKeeper, authtypes.FeeCollectorName, app.ModuleAccountAddrs(),
	)
```
while there would be a seperate function that would restrict and validate allowed denoms as such.

```

func DistributionMintingRestriction(ctx sdk.Context, coins sdk.Coins) errors {
  for _, coin := range coins {
    if coin.Denom != ctx.NativeStakingDenom {
       return errors.New(fmt.Sprintf("Distribution can only print denom %s, tried minting %s", ctx.NativeStakingDenom, coin.Denom))
     }
  }
}
```

The sdk's simapp currently does not have any keepers that are to be changed with this implementation added, thus remaining unchanged in `app.go`.

* refactor: prune everything (backport #11177) (#11258)

* refactor: prune everything (#11177)

(cherry picked from commit 75bcf47)

# Conflicts:
#	CHANGELOG.md
#	server/config/toml.go
#	server/start.go
#	store/rootmulti/store.go
#	store/types/pruning.go
#	store/v2/multi/store_test.go

* updates

* updates

* updates

* updates

* updates

Co-authored-by: Aleksandr Bezobchuk <[email protected]>
Co-authored-by: Aleksandr Bezobchuk <[email protected]>

* feat: min and max operators on coins (backport #11200) (#11249)

* feat: min and max operators on coins (#11200)

## Description

Closes: #10995

Adds `Min()` and `Max()` operations on `sdk.Coins` for per-denom minimum and maximum.

Replaced an example of manual low-level construction of `Coins` with higher-level operators.
Upcoming enhancements to vesting accounts make heavy use of this pattern.

* fix: add concurrency fence on traceContext to avoid data races (backport #11117) (#11139)

* fix: add concurrency fence on traceContext to avoid data races (#11117)

See #11114 for more info.

## Description

Closes: #11114

* feat: add get all versions (backport #11124) (#11144)

* feat: add get all versions (#11124)

* add get all versions

* add changelog entry

(cherry picked from commit d624a65)

# Conflicts:
#	CHANGELOG.md

* fix conflicts and remove interface break

Co-authored-by: Marko <[email protected]>

* support debug trace QueryResult (#11148)

Update types/errors/abci.go

Co-authored-by: Amaury <[email protected]>

Co-authored-by: Amaury <[email protected]>

* feat: Allow to restrict MintCoins from app.go (backport #10771) (#11227)

* feat: Allow to restrict MintCoins from app.go (#10771)

## Description

Closes: cosmos/cosmos-sdk#10386

This PR adds feature to the bank module so that other modules using bankKeeper would be able to call the keeper with restricted permissions when minting coins. `WithMintCoinsRestriction` would be able to get called within app.go when setting keeper components for each individual keeper, taking a function that would validate minting denom as an argument.

The example below demonstrates adding bank module with restricted permissions.
```
	app.DistrKeeper = distrkeeper.NewKeeper(
		appCodec, keys[distrtypes.StoreKey], app.GetSubspace(distrtypes.ModuleName), app.AccountKeeper, app.BankKeeper.WithMintCoinsRestriction(DistributionMintingRestriction),
		&stakingKeeper, authtypes.FeeCollectorName, app.ModuleAccountAddrs(),
	)
```
while there would be a seperate function that would restrict and validate allowed denoms as such.

```

func DistributionMintingRestriction(ctx sdk.Context, coins sdk.Coins) errors {
  for _, coin := range coins {
    if coin.Denom != ctx.NativeStakingDenom {
       return errors.New(fmt.Sprintf("Distribution can only print denom %s, tried minting %s", ctx.NativeStakingDenom, coin.Denom))
     }
  }
}
```

The sdk's simapp currently does not have any keepers that are to be changed with this implementation added, thus remaining unchanged in `app.go`.

* refactor: prune everything (backport #11177) (#11258)

* refactor: prune everything (#11177)

(cherry picked from commit 75bcf47)

# Conflicts:
#	CHANGELOG.md
#	server/config/toml.go
#	server/start.go
#	store/rootmulti/store.go
#	store/types/pruning.go
#	store/v2/multi/store_test.go

* updates

* updates

* updates

* updates

* updates

Co-authored-by: Aleksandr Bezobchuk <[email protected]>
Co-authored-by: Aleksandr Bezobchuk <[email protected]>

* feat: min and max operators on coins (backport #11200) (#11249)

* feat: min and max operators on coins (#11200)

## Description

Closes: #10995

Adds `Min()` and `Max()` operations on `sdk.Coins` for per-denom minimum and maximum.

Replaced an example of manual low-level construction of `Coins` with higher-level operators.
Upcoming enhancements to vesting accounts make heavy use of this pattern.

* feat: include transactions in QueryBlockByHeight (backport #10880) (#11248)

* feat: include transactions in QueryBlockByHeight  (#10880)

## Description

Closes: #3729

- adds a new query to the tx service in Auth, which gets block information + decoded txs
- added a new function to get the protoBlock from the node.

* chore: fix changelog entry for #11177 (backport #11263) (#11264)

* fix: reject query with block height in the future (backport #11222) (#11266)

* fix: reject query with block height in the future (#11222)

## Description

Closes: #11220

Should be good to backport to older versions.

* fix: x/authz allow insufficient funds error (backport #11252) (#11299)

* fix: x/authz allow insufficient funds error (#11252)

## Description

Allow insufficient funds error for authz simulation

Closes: #XXXX

* feat!: Add hooks to allow app modules to add things to state-sync (backport #10961) (#11267)

* feat!: Add hooks to allow app modules to add things to state-sync (#10961)

## Description

Closes: #7340

- Support registering multiple snapshotters in snapshot manager.
- Append the extension snapshotters to existing snapshot stream.

~TODO: testing.~
- existing tests are fixed

* Implement rollback command (#11179) (#11314)

Closes: #10281

fix tendermint rollback

changelog

update tendermint to recent v0.35.x branch

(cherry picked from commit 8296ad9)

# Conflicts:
#	CHANGELOG.md
#	go.mod
#	go.sum

Co-authored-by: yihuang <[email protected]>

* fix(types): use correct bit length constant for sdk.Dec (backport #11332) (#11335)

* Use correct bit length constant for sdk.Dec (#11332)

Co-authored-by: Marko <[email protected]>
(cherry picked from commit 3d3cf25)

# Conflicts:
#	go.sum

* fix conflicts

Co-authored-by: Julien Robert <[email protected]>
Co-authored-by: marbar3778 <[email protected]>

* fix: remove hardcoded pubkey from tx simulation (backport #11282) (#11288)

* fix: remove hardcoded pubkey from tx simulation (#11282)

## Description

Closes: #11283

* fix: cgosecp256k1 verification (backport #11298) (#11360)

* fix: cgosecp256k1 verification (#11298)

## Description

Closes: #10747

- update secp256k1 cgo fork,
- debug verify bytes

```
benchmark                     old ns/op     new ns/op     delta
BenchmarkKeyGeneration-10     407           413           +1.35%
BenchmarkSigning-10           95099         36754         -61.35%
BenchmarkVerification-10      215551        48053         -77.71%

benchmark                     old allocs     new allocs     delta
BenchmarkKeyGeneration-10     2              2              +0.00%
BenchmarkSigning-10           83             4              -95.18%
BenchmarkVerification-10      74             1              -98.65%

benchmark                     old bytes     new bytes     delta
BenchmarkKeyGeneration-10     96            96            +0.00%
BenchmarkSigning-10           5283          196           -96.29%
BenchmarkVerification-10      3537          32            -99.10%
```

* fix: multisig works with only multisig name as argument, not its address (backport #11197) (#11348)

* fix: multisig works with only multisig name as argument, not its address (#11197)

## Description

Closes: #11196
ref: https://github.com/terra-money/core/issues/570

multisig flag now works with both address and name as arguments for signing

* fix: Update query.go to include pagination for bank q totals (#11355) (#11375)

## Description

Closes: #11354

* feat: add support for spendable balances gRPC query (backport #11417) (#11459)

* feat: grpc-only mode (backport #11430) (#11460)

* feat: add grants by grantee authz query (backport #10944) (#11523)

* feat: add grants by grantee authz query (#10944)

(cherry picked from commit fa8099d)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/app/module/v1alpha1/module.pulsar.go
#	api/cosmos/app/v1alpha1/config.pulsar.go
#	api/cosmos/app/v1alpha1/module.pulsar.go
#	api/cosmos/app/v1alpha1/query.pulsar.go
#	api/cosmos/authz/v1beta1/authz.pulsar.go
#	api/cosmos/authz/v1beta1/genesis.pulsar.go
#	api/cosmos/authz/v1beta1/query.pulsar.go
#	api/cosmos/authz/v1beta1/query_grpc.pb.go
#	api/cosmos/base/query/v1beta1/pagination.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	proto/cosmos/authz/v1beta1/genesis.proto
#	proto/cosmos/authz/v1beta1/query.proto
#	x/authz/authz.pb.go
#	x/authz/client/cli/query.go
#	x/authz/client/rest/grpc_query_test.go
#	x/authz/genesis.pb.go
#	x/authz/keeper/grpc_query.go
#	x/authz/keeper/grpc_query_test.go
#	x/authz/query.pb.go
#	x/authz/query.pb.gw.go

* fix conflicts

* remove doc

* remove scalar

* Apply suggestions from code review

Co-authored-by: Amaury <[email protected]>

* fix conflicts

* remove go-eth dep

Co-authored-by: Callum Waters <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
Co-authored-by: Amaury <[email protected]>

* feat: EIP191 sign mode (backport #11533) (#11545)

* feat: EIP191 sign mode (#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos/cosmos-sdk#10553 (comment)

* chore: v0.45.2 Release Notes (#11546)

* chore: v0.45.2 Release Notes

* update changelog

* feat: `ScheduleUpgradeNoHeightValidation` for automated upgrades w/o gov proposal (backport #11551) (#11574)

* feat: `ScheduleUpgradeNoHeightValidation` for automated upgrades w/o gov proposal (#11551)

## Description

Implements a `ScheduleUpgradeNoHeightValidation` function for chains to schedule an automated upgrade (using the `x/upgrade` module) without having to go through a governance proposal.

This is beneficial to coordinate upgrades without having to manually download the new version, do the migration and restart the chain.

This is the procedure Evmos used for its automated upgrade.

* chore: update TM dep (#11562)

* fix: address confusing error message with SetOrder* functions (#11571) (#11581)

* chore: v0.45.3 Release Notes (#11611)

* fix: mod tidy & tests

* check error returned from NewNode (#11624)

* docs: Add v0.45.x to docs versions (backport #11613) (#11623)

* docs: Update mentions of Starport to Ignite CLI (backport #11612) (#11617)

* feat: add (re)delegation getters (backport #11596) (#11615)

* feat: add (re)delegation getters (#11596)

### Description

This PR adds general helper functions to the `x/staking` module that are used in the Evmos `x/vesting` module and originated from Agoric's custom staking module implementation https://github.com/agoric-labs/cosmos-sdk/blob/4085-true-vesting/x/staking/keeper/delegation.go.

- `GetDelegatorUnbonding`
- `GetDelegatorBonded`
- `IterateDelegatorUnbondingDelegations`
- `IterateDelegatorDelegations`
- `IterateDelegatorRedelegations`

(cherry picked from commit b8270fc)

# Conflicts:
#	CHANGELOG.md
#	x/staking/keeper/delegation.go

* fix RemoveDelegation method conflict

* fix CHANGELOG conflict

* add new PR in CHANGELOG

Co-authored-by: Daniel Burckhardt <[email protected]>

* feat: add vesting util functions (backport #11652) (#11667)

* feat: add vesting util functions (#11652)

* feat: add vesting util functions

* changelog

* revert string deletion

* fix build

* Update x/auth/vesting/types/period.go

Co-authored-by: Aleksandr Bezobchuk <[email protected]>

Co-authored-by: Aleksandr Bezobchuk <[email protected]>
Co-authored-by: Marko <[email protected]>
(cherry picked from commit c676952)

# Conflicts:
#	CHANGELOG.md
#	x/auth/vesting/types/period.go

* changelog

* Update x/auth/vesting/types/period.go

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: Federico Kunze Küllmer <[email protected]>

* chore: v0.45.x bump min go version to 1.17 (#11686)

* fix: Add validation on create gentx (backport #11693) (#11698)

* 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 <[email protected]>
(cherry picked from commit d5e0b86)

Co-authored-by: Takahiko Tominaga <[email protected]>

* chore: remove unneeded swagger docs from 0.45 #11745

* fix: data race issues with api.Server (backport #11724) (#11748)

* updates (#11752)

* chore: release notes++

* chore: rebuild rosetta data

* fix: gentx tests due to our custom min-self-delegation

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Marko <[email protected]>
Co-authored-by: yihuang <[email protected]>
Co-authored-by: Amaury <[email protected]>
Co-authored-by: Aleksandr Bezobchuk <[email protected]>
Co-authored-by: Aleksandr Bezobchuk <[email protected]>
Co-authored-by: Julien Robert <[email protected]>
Co-authored-by: Callum Waters <[email protected]>
Co-authored-by: Jorge Hernandez <[email protected]>
Co-authored-by: Daniel Burckhardt <[email protected]>
Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: Takahiko Tominaga <[email protected]>
JimLarson pushed a commit to agoric-labs/cosmos-sdk that referenced this pull request Jul 7, 2022
* feat: EIP191 sign mode (cosmos#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos#10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
dudong2 pushed a commit to dudong2/lbm-sdk that referenced this pull request Jul 26, 2022
* feat: EIP191 sign mode (#11533)

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos/cosmos-sdk#10553 (comment)

---

*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
- [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)
- [ ] 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

*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 dc66ddd)

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
randy75828 pushed a commit to Switcheo/cosmos-sdk that referenced this pull request Aug 10, 2022
* feat: EIP191 sign mode (cosmos#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos#10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
randy75828 pushed a commit to Switcheo/cosmos-sdk that referenced this pull request Aug 10, 2022
* feat: EIP191 sign mode (cosmos#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos#10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
JeancarloBarrios pushed a commit to agoric-labs/cosmos-sdk that referenced this pull request Sep 28, 2024
* feat: EIP191 sign mode (cosmos#11533)

## Description

Adds [EIP-191](https://eips.ethereum.org/EIPS/eip-191) as a supported sign mode.

Ref: cosmos#10553 (comment)

---

### 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
- [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)
- [ ] 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 dc66ddd)

# Conflicts:
#	CHANGELOG.md
#	api/cosmos/distribution/v1beta1/tx.pulsar.go
#	api/cosmos/tx/signing/v1beta1/signing.pulsar.go
#	client/cmd.go
#	client/flags/flags.go
#	client/tx/factory.go
#	go.sum
#	types/tx/signing/signing.pb.go
#	x/distribution/types/tx.pb.go

* fix conflicts

* fix conflicts++

Co-authored-by: Federico Kunze Küllmer <[email protected]>
Co-authored-by: marbar3778 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C:Encoding C:x/auth T: Dev UX UX for SDK developers (i.e. how to call our code)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants