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

[Bug]: server/v2 snapshot restore panics #22268

Closed
1 task done
kocubinski opened this issue Oct 15, 2024 · 0 comments · Fixed by #22267
Closed
1 task done

[Bug]: server/v2 snapshot restore panics #22268

kocubinski opened this issue Oct 15, 2024 · 0 comments · Fixed by #22267
Labels

Comments

@kocubinski
Copy link
Member

Is there an existing issue for this?

  • I have searched the existing issues

What happened?

❯ go run simdv2/main.go store restore 5 3
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x18 pc=0x1031844c8]

goroutine 1 [running]:
cosmossdk.io/server/v2/store.createSnapshotsManager(0x14001417508, 0x14000146020?, {0x1043dde60, 0x1400157a4d0}, {0x0, 0x0})
	/Users/mattk/src/cosmos-sdk/main/server/v2/store/snapshot.go:375 +0x138
cosmossdk.io/server/v2/store.(*Server[...]).RestoreSnapshotCmd.func1({0x14001800000, 0x2, 0x2})
	/Users/mattk/src/cosmos-sdk/main/server/v2/store/snapshot.go:98 +0xec
github.com/spf13/cobra.(*Command).execute(0x14001417508, {0x14001714f60, 0x2, 0x2})
	/Users/mattk/go/pkg/mod/github.com/spf13/[email protected]/command.go:985 +0x834
github.com/spf13/cobra.(*Command).ExecuteC(0x14001360908)
	/Users/mattk/go/pkg/mod/github.com/spf13/[email protected]/command.go:1117 +0x344
github.com/spf13/cobra.(*Command).Execute(...)
	/Users/mattk/go/pkg/mod/github.com/spf13/[email protected]/command.go:1041
cosmossdk.io/server/v2.Execute(0x14001360908, {0x0, 0x0}, {0x140010f16c8, 0x16})
	/Users/mattk/src/cosmos-sdk/main/server/v2/commands.go:31 +0x26c
main.main()
	/Users/mattk/src/cosmos-sdk/main/simapp/v2/simdv2/main.go:16 +0x4c
exit status 2

Cosmos SDK Version

main

How to reproduce?

❯ go run simdv2/main.go start
# run for n blocks, here at least 5
❯ go run simdv2/main.go store export
❯ go run simdv2/main.go store restore 5 3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: 🥳 Done
Development

Successfully merging a pull request may close this issue.

1 participant