cosmos-sdk/x/auth/middleware
Tyler 40a5364ff0
refactor(auth): better error message for method handler panic (#11482)
## Description

we panic when we attempt to register a msg that does not implement sdk.Msg. However, this is not immediately apparent in the panic error string. 

This PR updates the panic to be more specific as to why it panicked. 

Closes: n/a



---

### 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)
2022-03-29 16:06:30 +00:00
..
basic_test.go refactor: Move TxDecoder into its own middleware (#10612) 2021-12-06 10:26:15 +01:00
basic.go refactor: middleware refactor to change tx.Handler interface (#10527) 2021-12-02 06:54:38 +00:00
block_gas.go fix: should revert tx when block gas limit exceeded (#10770) 2022-01-11 10:21:01 +00:00
branch_store_test.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
branch_store.go fix: should revert tx when block gas limit exceeded (#10770) 2022-01-11 10:21:01 +00:00
expected_keepers.go refactor: migrate ante hanlders to middlewares (#10028) 2021-10-01 14:30:22 +00:00
ext_test.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
ext.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
fee_test.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
fee.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
feegrant_test.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
gas_test.go refactor: Move TxDecoder into its own middleware (#10612) 2021-12-06 10:26:15 +01:00
gas.go refactor: middleware refactor to change tx.Handler interface (#10527) 2021-12-02 06:54:38 +00:00
index_events.go refactor: middleware refactor to change tx.Handler interface (#10527) 2021-12-02 06:54:38 +00:00
legacy_router_test.go refactor!: BaseApp {Check,Deliver}Tx with middleware design (#9920) 2021-08-25 14:40:33 +00:00
legacy_router.go refactor!: BaseApp {Check,Deliver}Tx with middleware design (#9920) 2021-08-25 14:40:33 +00:00
middleware_test.go refactor: Move TxDecoder into its own middleware (#10612) 2021-12-06 10:26:15 +01:00
middleware.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00
msg_service_router_test.go refactor: migrate ante hanlders to middlewares (#10028) 2021-10-01 14:30:22 +00:00
msg_service_router.go refactor(auth): better error message for method handler panic (#11482) 2022-03-29 16:06:30 +00:00
recovery.go fix: should revert tx when block gas limit exceeded (#10770) 2022-01-11 10:21:01 +00:00
run_msgs_test.go refactor: middleware refactor to change tx.Handler interface (#10527) 2021-12-02 06:54:38 +00:00
run_msgs.go fix: should revert tx when block gas limit exceeded (#10770) 2022-01-11 10:21:01 +00:00
sigverify_benchmark_test.go refactor: migrate ante hanlders to middlewares (#10028) 2021-10-01 14:30:22 +00:00
sigverify_test.go feat: replace all ModuleCdc instances with legacy.Cdc (#11240) 2022-02-23 14:13:36 +00:00
sigverify.go refactor: Change SignerData.SignerIndex to PubKey (#10692) 2021-12-08 11:43:15 +00:00
testutil_test.go refactor: Change SignerData.SignerIndex to PubKey (#10692) 2021-12-08 11:43:15 +00:00
tips_test.go chore: Bump gov and group to v1 (#11334) 2022-03-11 15:58:01 +00:00
tips.go refactor: middleware refactor to change tx.Handler interface (#10527) 2021-12-02 06:54:38 +00:00
tx_test.go refactor: Move TxDecoder into its own middleware (#10612) 2021-12-06 10:26:15 +01:00
tx.go refactor: Move TxDecoder into its own middleware (#10612) 2021-12-06 10:26:15 +01:00
validator_tx_fee.go refactor(x/auth/middleware)!: tx middleware to support pluggable feemarket module (#11413) 2022-03-29 14:46:56 +00:00