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

Interchain Account doesnt work when receiving a simple send message. #2664

Closed
georgelombardi97 opened this issue Sep 8, 2022 · 1 comment

Comments

@georgelombardi97
Copy link

System information

Osmosis version: latest version that validators are running as of Sep8, I guess its 11.0.1
OS & Version: Linux

Expected behaviour

The tx should be executed without error and emit a successful Ack to be relayed back to the controller chain.

Actual behaviour

The message is received by ibc-go OnRecvPacket, then tries to executeTx, which finds route to bank module, and bank module uses auth module, and finally auth module throws error. Causing the tx to fail. Based on traceback, looks like the auth module cannot handle interchain accounts.

Steps to reproduce the behaviour

  • Run a local blockchain node as a ICA controller (for example neutron repo)
  • Run a relayer between the local chain and osmosis mainnet
  • register an interchain account on osmosis
  • Send a MsgSend message to the interchain account on osmosis
  • The relayer tries to build and submit the tx but fails.

Backtrace

2022-09-08T14:07:19.067895Z	info	Error building or broadcasting transaction	{"provider_type": "cosmos", "chain_id": "osmosis-1", "attempt": 3, "max_attempts": 5, "error": "rpc error: code = InvalidArgument desc = recovered: no concrete type registered for type URL /ibc.applications.interchain_accounts.v1.InterchainAccount against interface *types.AccountI\nstack:\ngoroutine 2136146802 [running]:\nruntime/debug.Stack()\n\truntime/debug/stack.go:24 +0x65\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.newDefaultRecoveryMiddleware.func1({0x1c20ae0, 0xc1b394f060})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/recovery.go:71 +0x27\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.newRecoveryMiddleware.func1({0x1c20ae0?, 0xc1b394f060?})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/recovery.go:39 +0x30\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.processRecovery({0x1c20ae0, 0xc1b394f060}, 0xc091f18fc0?)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/recovery.go:28 +0x37\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.processRecovery({0x1c20ae0, 0xc1b394f060}, 0x251c5c0?)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/recovery.go:33 +0x5e\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).runTx.func1()\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/baseapp.go:612 +0xf0\npanic({0x1c20ae0, 0xc1b394f060})\n\truntime/panic.go:838 +0x207\ngit.luolix.top/cosmos/cosmos-sdk/x/auth/keeper.AccountKeeper.decodeAccount({{0x24f6510, 0xc00175a030}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/auth/keeper/keeper.go:219 +0xf4\ngit.luolix.top/cosmos/cosmos-sdk/x/auth/keeper.AccountKeeper.GetAccount({{0x24f6510, 0xc00175a030}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/auth/keeper/account.go:42 +0x178\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/keeper.BaseViewKeeper.LockedCoins({{_, _}, {_, _}, {_, _}}, {{0x250dae8, 0xc0000500a0}, {0x251c5c0, 0xc3cdb5c840}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/keeper/view.go:165 +0xa2\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/keeper.BaseSendKeeper.subUnlockedCoins({{{0x251aa90, 0xc0017320e0}, {0x24f6510, 0xc00175a040}, {0x251c040, 0xc0001990e0}}, {0x251aa90, 0xc0017320e0}, {0x251c040, 0xc0001990e0}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/keeper/send.go:228 +0xf6\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/keeper.BaseSendKeeper.SendCoins({{{0x251aa90, 0xc0017320e0}, {0x24f6510, 0xc00175a040}, {0x251c040, 0xc0001990e0}}, {0x251aa90, 0xc0017320e0}, {0x251c040, 0xc0001990e0}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/keeper/send.go:137 +0xe5\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/keeper.msgServer.Send({{0x2524598?, 0xc000e35ce0?}}, {0x250db58?, 0xc116e31bc0?}, 0xc3cdb5c0c0)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/keeper/msg_server.go:46 +0x2e5\ngit.luolix.top/osmosis-labs/bech32-ibc/x/bech32ics20/keeper.msgServer.Send({{{0x2524598, 0xc000e35ce0}, {0x24f83d8, 0xc000036f20}, {0x24f09a0, 0xc00175e120}, {0x2504fe0, 0xc0012e7f40}, {0x24f0980, 0xc00175e120}, ...}}, ...)\n\tgit.luolix.top/osmosis-labs/bech32-ibc@v0.3.0-rc1/x/bech32ics20/keeper/msg_server.go:51 +0x7f1\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/types._Msg_Send_Handler.func1({0x250db58, 0xc116e31bc0}, {0x1e540e0?, 0xc3cdb5c0c0})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/types/tx.pb.go:321 +0x78\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*MsgServiceRouter).RegisterService.func2.1({0x250db58, 0xc116e31b90}, {0x4c0026?, 0x412b8b?}, 0x1ec0c80?, 0xc24d4b2240)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/msg_service_router.go:113 +0xd2\ngit.luolix.top/cosmos/cosmos-sdk/x/bank/types._Msg_Send_Handler({0x1eb72c0?, 0xc00052fe80}, {0x250db58, 0xc116e31b90}, 0x228d788, 0xc1ecacd560)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/bank/types/tx.pb.go:323 +0x138\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*MsgServiceRouter).RegisterService.func2({{0x250dae8, 0xc0000500a0}, {0x251c5c0, 0xc3cdb5c840}, {{0xb, 0xa}, {0xc3385787a0, 0x9}, 0x5a8970, {0x30d5c3c8, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/msg_service_router.go:117 +0x2f3\ngit.luolix.top/cosmos/ibc-go/v3/modules/apps/27-interchain-accounts/host/keeper.Keeper.executeMsg({{0x24f6510, 0xc00175a0c0}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/apps/27-interchain-accounts/host/keeper/relay.go:123 +0xf1\ngit.luolix.top/cosmos/ibc-go/v3/modules/apps/27-interchain-accounts/host/keeper.Keeper.executeTx({{0x24f6510, 0xc00175a0c0}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/apps/27-interchain-accounts/host/keeper/relay.go:67 +0x5ef\ngit.luolix.top/cosmos/ibc-go/v3/modules/apps/27-interchain-accounts/host/keeper.Keeper.OnRecvPacket({{0x24f6510, 0xc00175a0c0}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/apps/27-interchain-accounts/host/keeper/relay.go:30 +0x19b\ngit.luolix.top/cosmos/ibc-go/v3/modules/apps/27-interchain-accounts/host.IBCModule.OnRecvPacket({{{0x24f6510, 0xc00175a0c0}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, 0xc0000103f8, {0x24f6510, 0xc00175a0a0}, {0x24f6560, ...}, ...}, ...}}, ...)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/apps/27-interchain-accounts/host/ibc_module.go:112 +0x1b8\ngit.luolix.top/cosmos/ibc-go/v3/modules/core/keeper.Keeper.RecvPacket({{0x0, 0x0}, {0x251aa90, 0xc0017320e0}, {{0x24f6510, 0xc00175a0b0}, {0x251aa90, 0xc0017320e0}, {{0x251aa90, 0xc0017320e0}, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/core/keeper/msg_server.go:407 +0x7d8\ngit.luolix.top/cosmos/ibc-go/v3/modules/core/04-channel/types._Msg_RecvPacket_Handler.func1({0x250db58, 0xc25eef76e0}, {0x1e3b280?, 0xc1386f4dc0})\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/core/04-channel/types/tx.pb.go:1306 +0x78\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*MsgServiceRouter).RegisterService.func2.1({0x250db58, 0xc25eef7680}, {0x4c0026?, 0x412b8b?}, 0x1ec0c80?, 0xc28d5c3ad0)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/msg_service_router.go:113 +0xd2\ngit.luolix.top/cosmos/ibc-go/v3/modules/core/04-channel/types._Msg_RecvPacket_Handler({0x1eaf620?, 0xc0002d9680}, {0x250db58, 0xc25eef7680}, 0x228d788, 0xc275b3e340)\n\tgit.luolix.top/cosmos/ibc-go/v3@v3.0.0/modules/core/04-channel/types/tx.pb.go:1308 +0x138\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*MsgServiceRouter).RegisterService.func2({{0x250dae8, 0xc0000500a0}, {0x251c5c0, 0xc3ff61a200}, {{0xb, 0xa}, {0xc3385787a0, 0x9}, 0x5a8970, {0x30d5c3c8, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/msg_service_router.go:117 +0x2f3\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).runMsgs(_, {{0x250dae8, 0xc0000500a0}, {0x251c5c0, 0xc3ff61a200}, {{0xb, 0xa}, {0xc3385787a0, 0x9}, 0x5a8970, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/baseapp.go:740 +0x5a5\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).runTx(0xc0002fc480, 0x2, {0xc091eb8000, 0x936, 0x936})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/baseapp.go:697 +0xbc5\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).Simulate(0x415507?, {0xc091eb8000?, 0x1d2d240?, 0x24f2401?})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/test_helpers.go:23 +0x2c\ngit.luolix.top/cosmos/cosmos-sdk/x/auth/tx.txServer.Simulate({{{0x0, 0x0, 0x0}, {0x2523d00, 0xc0012d1140}, {0xc0013510a0, 0x9}, {0x2512ac0, 0xc0011e3320}, 0x0, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/x/auth/tx/service.go:117 +0x129\ngit.luolix.top/cosmos/cosmos-sdk/types/tx._Service_Simulate_Handler({0x1db93a0?, 0xc0a75a0000}, {0x250db58, 0xc3769ad350}, 0xc346eda140, 0x0)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/types/tx/service.pb.go:745 +0x170\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*GRPCQueryRouter).RegisterService.func1({{0x250dae8, 0xc0000500a0}, {0x251c5c0, 0xc15e61e840}, {{0xb, 0xa}, {0xc3385787a0, 0x9}, 0x5a8970, {0x30d5c3c8, ...}, ...}, ...}, ...)\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/grpcrouter.go:85 +0x1f0\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).handleQueryGRPC(0xc0a690c5d8?, 0xc0a670b080, {{0xc091246c00, 0x939, 0x1300}, {0xc0cce48ff0, 0x23}, 0x5a8970, 0x0})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/abci.go:558 +0x1af\ngit.luolix.top/cosmos/cosmos-sdk/baseapp.(*BaseApp).Query(0xc0002fc480, {{0xc091246c00, 0x939, 0x1300}, {0xc0cce48ff0, 0x23}, 0x5a8970, 0x0})\n\tgit.luolix.top/cosmos/cosmos-sdk@v0.45.6/baseapp/abci.go:402 +0x6d3\ngit.luolix.top/tendermint/tendermint/abci/client.(*localClient).QuerySync(0xc0005219e0, {{0xc091246c00, 0x939, 0x1300}, {0xc0cce48ff0, 0x23}, 0x0, 0x0})\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/abci/client/local_client.go:256 +0x171\ngit.luolix.top/tendermint/tendermint/proxy.(*appConnQuery).QuerySync(0x2?, {{0xc091246c00, 0x939, 0x1300}, {0xc0cce48ff0, 0x23}, 0x0, 0x0})\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/proxy/app_conn.go:159 +0x6e\ngit.luolix.top/tendermint/tendermint/rpc/core.ABCIQuery(0x8?, {0xc0cce48ff0?, 0xc07f402b40?}, {0xc091246c00?, 0x4?, 0xc0f4369b00?}, 0x2?, 0x99?)\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/rpc/core/abci.go:20 +0xa6\nreflect.Value.call({0x1c8bf00?, 0x228fbb8?, 0x80?}, {0x1ed5ce9, 0x4}, {0xc0908f4980, 0x5, 0x18?})\n\treflect/value.go:556 +0x845\nreflect.Value.Call({0x1c8bf00?, 0x228fbb8?, 0x12c5?}, {0xc0908f4980, 0x5, 0x5})\n\treflect/value.go:339 +0xbf\ngit.luolix.top/tendermint/tendermint/rpc/jsonrpc/server.makeJSONRPCHandler.func1({0x250c420, 0xc1915dfdd0}, 0xc0919a2d00)\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/rpc/jsonrpc/server/http_json_handler.go:96 +0x1075\ngit.luolix.top/tendermint/tendermint/rpc/jsonrpc/server.handleInvalidJSONRPCPaths.func1({0x250c420?, 0xc1915dfdd0?}, 0x0?)\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/rpc/jsonrpc/server/http_json_handler.go:122 +0x5d\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x250c420?, 0xc1915dfdd0?}, 0x54c1e8?)\n\tnet/http/server.go:2084 +0x2f\nnet/http.(*ServeMux).ServeHTTP(0xc0a5f62240?, {0x250c420, 0xc1915dfdd0}, 0xc0919a2d00)\n\tnet/http/server.go:2462 +0x149\ngit.luolix.top/rs/cors.(*Cors).Handler.func1({0x250c420, 0xc1915dfdd0}, 0xc0919a2d00)\n\tgit.luolix.top/rs/cors@v1.8.2/cors.go:231 +0x1c4\nnet/http.HandlerFunc.ServeHTTP(0x160?, {0x250c420?, 0xc1915dfdd0?}, 0x0?)\n\tnet/http/server.go:2084 +0x2f\ngit.luolix.top/tendermint/tendermint/rpc/jsonrpc/server.maxBytesHandler.ServeHTTP({{0x24f52e0?, 0xc0b5b9d0e0?}, 0x415507?}, {0x250c420?, 0xc1915dfdd0}, 0xc0919a2d00)\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/rpc/jsonrpc/server/http_server.go:236 +0x122\ngit.luolix.top/tendermint/tendermint/rpc/jsonrpc/server.RecoverAndLogHandler.func1({0x250ca80?, 0xc17d4edc00}, 0xc0919a2d00)\n\tgit.luolix.top/tendermint/tendermint@v0.34.19/rpc/jsonrpc/server/http_server.go:209 +0x37f\nnet/http.HandlerFunc.ServeHTTP(0x0?, {0x250ca80?, 0xc17d4edc00?}, 0x4151a5?)\n\tnet/http/server.go:2084 +0x2f\nnet/http.serverHandler.ServeHTTP({0x24f79d8?}, {0x250ca80, 0xc17d4edc00}, 0xc0919a2d00)\n\tnet/http/server.go:2916 +0x43b\nnet/http.(*conn).serve(0xc28821cb40, {0x250db58, 0xc0a5f887e0})\n\tnet/http/server.go:1966 +0x5d7\ncreated by net/http.(*Server).Serve\n\tnet/http/server.go:3071 +0x4db\n: panic: invalid request"}
@georgelombardi97
Copy link
Author

same reported here #1710
and is fixed here #1825

Repository owner moved this from Needs Review 🔍 to Done ✅ in Osmosis Chain Development Sep 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

1 participant