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

panic when attempting to dump state via osmosisd export #1019

Closed
jtieri opened this issue Mar 2, 2022 · 6 comments
Closed

panic when attempting to dump state via osmosisd export #1019

jtieri opened this issue Mar 2, 2022 · 6 comments
Labels
T:bug 🐛 Something isn't working

Comments

@jtieri
Copy link

jtieri commented Mar 2, 2022

I'm trying to export state for a few specific heights after the most recent upgrade and the process always ends up stopping due to a panic with the same error message at the same LOC.

Example:
osmosisd export --height 3409000 2> osmosis_state.json

Err Output:

panic: gauge with ID 2252 does not exist

goroutine 1 [running]:
github.com/osmosis-labs/osmosis/v7/x/incentives/keeper.Keeper.getGaugesFromIterator({{0x27fa178, 0xc00657d880}, {0x27871a0, 0xc00657d9e0}, {{0x27ede98, 0xc00657d880}, 0xc0012c2010, {0x27871a0, 0xc00657d950}, {0x27871f0, ...}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/x/incentives/keeper/gauge.go:30 +0x416
github.com/osmosis-labs/osmosis/v7/x/incentives/keeper.Keeper.GetActiveGauges({{0x27fa178, 0xc00657d880}, {0x27871a0, 0xc00657d9e0}, {{0x27ede98, 0xc00657d880}, 0xc0012c2010, {0x27871a0, 0xc00657d950}, {0x27871f0, ...}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/x/incentives/keeper/gauge.go:209 +0x198
github.com/osmosis-labs/osmosis/v7/x/incentives/keeper.Keeper.GetNotFinishedGauges({{0x27fa178, 0xc00657d880}, {0x27871a0, 0xc00657d9e0}, {{0x27ede98, 0xc00657d880}, 0xc0012c2010, {0x27871a0, 0xc00657d950}, {0x27871f0, ...}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/x/incentives/keeper/gauge.go:204 +0x98
github.com/osmosis-labs/osmosis/v7/x/incentives.ExportGenesis({{0x27c3508, 0xc000128000}, {0x27f36c0, 0xc092d97580}, {{0x0, 0x0}, {0x0, 0x0}, 0x340468, {0x0, ...}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/x/incentives/genesis.go:27 +0x218
github.com/osmosis-labs/osmosis/v7/x/incentives.AppModule.ExportGenesis({{{0x27fa178, 0xc00657d880}}, {{0x27fa178, 0xc00657d880}, {0x27871a0, 0xc00657d9e0}, {{0x27ede98, 0xc00657d880}, 0xc0012c2010, {0x27871a0, ...}, ...}, ...}, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/x/incentives/module.go:170 +0xb8
github.com/cosmos/cosmos-sdk/types/module.(*Manager).ExportGenesis(_, {{0x27c3508, 0xc000128000}, {0x27f36c0, 0xc092d97580}, {{0x0, 0x0}, {0x0, 0x0}, 0x340468, ...}, ...}, ...)
	github.com/cosmos/cosmos-sdk@v0.45.1/types/module/module.go:344 +0x125
github.com/osmosis-labs/osmosis/v7/app.(*OsmosisApp).ExportAppStateAndValidators(0xc00017f500, 0x0, {0x39ee658, 0x0, 0x0})
	github.com/osmosis-labs/osmosis/v7/app/export.go:32 +0x20f
github.com/osmosis-labs/osmosis/v7/cmd/osmosisd/cmd.createOsmosisAppAndExport({0x27c46f8, 0xc0013eab40}, {0x27eeed8, 0xc0012c2008}, {0x0, 0x0}, 0x340468, 0x0, {0x39ee658, 0x0, ...}, ...)
	github.com/osmosis-labs/osmosis/v7/cmd/osmosisd/cmd/root.go:303 +0x4ce
github.com/cosmos/cosmos-sdk/server.ExportCmd.func1(0xc00123d400, {0xc0013540c0, 0x0, 0x2})
	github.com/cosmos/cosmos-sdk@v0.45.1/server/export.go:71 +0x31c
github.com/spf13/cobra.(*Command).execute(0xc00123d400, {0xc0013540a0, 0x2, 0x2})
	github.com/spf13/cobra@v1.3.0/command.go:856 +0x60e
github.com/spf13/cobra.(*Command).ExecuteC(0xc00120a280)
	github.com/spf13/cobra@v1.3.0/command.go:974 +0x3bc
github.com/spf13/cobra.(*Command).Execute(...)
	github.com/spf13/cobra@v1.3.0/command.go:902
github.com/spf13/cobra.(*Command).ExecuteContext(...)
	github.com/spf13/cobra@v1.3.0/command.go:895
github.com/cosmos/cosmos-sdk/server/cmd.Execute(0x0, {0xc0011ee5a0, 0x1b})
	github.com/cosmos/cosmos-sdk@v0.45.1/server/cmd/execute.go:36 +0x1eb
main.main()
	github.com/osmosis-labs/osmosis/v7/cmd/osmosisd/main.go:16 +0x31
@ValarDragon
Copy link
Member

ValarDragon commented Mar 3, 2022

@p0mvn just finished a fix for this in IAVL github.com/osmosis-labs/iavl/pull/33

@ValarDragon ValarDragon added the T:bug 🐛 Something isn't working label Mar 3, 2022
@ValarDragon
Copy link
Member

you can atm export the latest height, just not any historical height due to that issue

@ValarDragon
Copy link
Member

Can you try again on v7.0.3?

@jtieri
Copy link
Author

jtieri commented Mar 3, 2022

Can you try again on v7.0.3?

Gonna give it a try right now!

@jtieri
Copy link
Author

jtieri commented Mar 3, 2022

Okay seems to be working properly now for both historical and current heights 👍
Closing this issue now

@jtieri jtieri closed this as completed Mar 3, 2022
@ValarDragon
Copy link
Member

Awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T:bug 🐛 Something isn't working
Projects
Archived in project
Development

No branches or pull requests

2 participants