Skip to content

v16 blocker: twap records failing init genesis when state-exported v16 testnet is created from v15 genesis #5041

@p0mvn

Description

@p0mvn

Background

From @niccoloraspa

Daily upgrade test failed again. This time before the upgrade.
On the initGenesis() on a state exported testnified v15 genesis.

2:23PM INF running initialization for module module=capability
2:23PM INF running initialization for module module=auth
2:24PM INF running initialization for module module=bank
2:24PM INF running initialization for module module=distribution
2:26PM INF running initialization for module module=downtimedetector
2:26PM INF running initialization for module module=staking
2:27PM INF running initialization for module module=slashing
2:27PM INF running initialization for module module=gov
2:27PM INF running initialization for module module=mint
2:27PM INF running initialization for module module=crisis
2:27PM INF running initialization for module module=ibc
2:27PM INF running initialization for module module=interchainaccounts
2:27PM INF running initialization for module module=gamm
2:27PM INF running initialization for module module=poolmanager
2:27PM INF running initialization for module module=protorev
2:27PM INF running initialization for module module=twap
panic: twap record p1 last spot price must be zero due to having an error, was (0.000000000009024277)

goroutine 1 [running]:
github.com/osmosis-labs/osmosis/v15/x/twap.Keeper.InitGenesis({{0x2ed92f8, 0xc0014e5c60}, 0xc0014e5d80, {{0x2f09580, 0xc00122c370}, 0xc000211a60, {0x2ed92f8, 0xc0014e5bb0}, {0x2ed9348, 0xc0014e5d70}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v15/x/twap/keeper.go:55 +0x2c5
github.com/osmosis-labs/osmosis/v15/x/twap/twapmodule.AppModule.InitGenesis({{}, {{0x2ed92f8, 0xc0014e5c60}, 0xc0014e5d80, {{0x2f09580, 0xc00122c370}, 0xc000211a60, {0x2ed92f8, 0xc0014e5bb0}, {0x2ed9348, ...}, ...}, ...}}, ...)
	github.com/osmosis-labs/osmosis/v15/x/twap/twapmodule/module.go:115 +0x105
github.com/cosmos/cosmos-sdk/types/module.(*Manager).InitGenesis(_, {{0x2ef5028, 0xc0000560b0}, {0x2f0bc40, 0xc0002afdc0}, {{0x0, 0x0}, {0xc001202020, 0xc}, 0x8f0181, ...}, ...}, ...)
	github.com/cosmos/cosmos-sdk@v0.46.10/types/module/module.go:322 +0x429
github.com/osmosis-labs/osmosis/v15/app.(*OsmosisApp).InitChainer(_, {{0x2ef5028, 0xc0000560b0}, {0x2f0bc40, 0xc0002afdc0}, {{0x0, 0x0}, {0xc001202020, 0xc}, 0x8f0181, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v15/app/app.go:363 +0x1b5
github.com/cosmos/cosmos-sdk/baseapp.(*BaseApp).InitChain(0xc00172b520, {{0x0, 0xed85ec810, 0x0}, {0xc001202020, 0xc}, 0xc0014ca620, {0xc001509000, 0x96, 0x96}, ...})
	github.com/cosmos/cosmos-sdk@v0.46.10/baseapp/abci.go:85 +0x515
github.com/tendermint/tendermint/abci/client.(*localClient).InitChainSync(0xc000e26960, {{0x0, 0xed85ec810, 0x0}, {0xc001202020, 0xc}, 0xc0014ca620, {0xc001509000, 0x96, 0x96}, ...})
	github.com/tendermint/tendermint@v0.34.24/abci/client/local_client.go:272 +0x118
github.com/tendermint/tendermint/proxy.(*appConnConsensus).InitChainSync(0x0?, {{0x0, 0xed85ec810, 0x0}, {0xc001202020, 0xc}, 0xc0014ca620, {0xc001509000, 0x96, 0x96}, ...})
	github.com/tendermint/tendermint@v0.34.24/proxy/app_conn.go:77 +0x55
github.com/tendermint/tendermint/consensus.(*Handshaker).ReplayBlocks(_, {{{0xb, 0x0}, {0x28099a7, 0x7}}, {0xc001202020, 0xc}, 0x8f0181, 0x0, {{0x0, ...}, ...}, ...}, ...)
	github.com/tendermint/tendermint@v0.34.24/consensus/replay.go:319 +0xd78
github.com/tendermint/tendermint/consensus.(*Handshaker).Handshake(0xc000fcb920, {0x2f0c8c0, 0xc0014f8340})
	github.com/tendermint/tendermint@v0.34.24/consensus/replay.go:268 +0x3d4
github.com/tendermint/tendermint/node.doHandshake({_, _}, {{{0xb, 0x0}, {0x28099a7, 0x7}}, {0xc001202020, 0xc}, 0x8f0181, 0x0, ...}, ...)
	github.com/tendermint/tendermint@v0.34.24/node/node.go:329 +0x1b8
github.com/tendermint/tendermint/node.NewNode(0xc000e28640, {0x2ef1810, 0xc001505b80}, 0xc00070a790, {0x2ed2780, 0xc00070c8a0}, 0x1?, 0x0?, 0xc00070a900, {0x2ef6560, ...}, ...)
	github.com/tendermint/tendermint@v0.34.24/node/node.go:777 +0x597
github.com/cosmos/cosmos-sdk/server.startInProcess(_, {{0x0, 0x0, 0x0}, {0x2f19c38, 0xc000e1c690}, {0x0, 0x0}, {0x2efde30, 0xc00125bc10}, ...}, ...)
	github.com/cosmos/cosmos-sdk@v0.46.10/server/start.go:264 +0x7bb
github.com/cosmos/cosmos-sdk/server.StartCmd.func2(0xc001335800?, {0xc0014e8f90?, 0x0?, 0x3?})
	github.com/cosmos/cosmos-sdk@v0.46.10/server/start.go:128 +0x193
github.com/spf13/cobra.(*Command).execute(0xc001335800, {0xc0014e8f00, 0x3, 0x3})
	github.com/spf13/cobra@v1.6.1/command.go:916 +0x862
github.com/spf13/cobra.(*Command).ExecuteC(0xc00121ef00)
	github.com/spf13/cobra@v1.6.1/command.go:1044 +0x3bd
github.com/spf13/cobra.(*Command).Execute(...)
	github.com/spf13/cobra@v1.6.1/command.go:968
github.com/spf13/cobra.(*Command).ExecuteContext(...)
	github.com/spf13/cobra@v1.6.1/command.go:961
github.com/cosmos/cosmos-sdk/server/cmd.Execute(0x0?, {0xc000223548, 0x16})
	github.com/cosmos/cosmos-sdk@v0.46.10/server/cmd/execute.go:36 +0x1eb
main.main()
	./main.go:16 +0x31

Acceptance Criteria

  • investigate and fix bug

Metadata

Metadata

Assignees

Labels

T:bug 🐛Something isn't working

Type

No type

Projects

Status

Done ✅

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions