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

Invalid homeDir for export command #334

Closed
whylee259 opened this issue Dec 10, 2020 · 3 comments · Fixed by #337
Closed

Invalid homeDir for export command #334

whylee259 opened this issue Dec 10, 2020 · 3 comments · Fixed by #337
Labels
bug Something isn't working
Milestone

Comments

@whylee259
Copy link

whylee259 commented Dec 10, 2020

The wasmd doesn't pass the homeDir properly when using export command.
It passes always wasm as the homeDir.

Step to reproduce

wasmd export

                                                                          1 ↵
panic: Error calling the VM: Cache error: Error opening Wasm file for reading: No such file or directory (os error 2)

goroutine 1 [running]:
github.com/CosmWasm/wasmd/x/wasm/internal/keeper.ExportGenesis.func1(0x1, 0xc000fc5a80, 0x20, 0x20, 0xc000f6b950, 0x2b, 0x0, 0x0, 0x0, 0x0, ...)
	github.com/CosmWasm/wasmd/x/wasm/internal/keeper/genesis.go:67 +0x2b4
github.com/CosmWasm/wasmd/x/wasm/internal/keeper.Keeper.IterateCodeInfos(0x5bc7de0, 0xc001068210, 0x5c00260, 0xc000c80470, 0x5bc7de0, 0xc001068140, 0x5bf9c40, 0xc000c80470, 0x5bf9c40, 0xc000c80470, ...)
	github.com/CosmWasm/wasmd/x/wasm/internal/keeper/keeper.go:574 +0x287
github.com/CosmWasm/wasmd/x/wasm/internal/keeper.ExportGenesis(0x5be7be0, 0xc0000c8030, 0x5bfd860, 0xc0010809c0, 0x0, 0x0, 0x0, 0x0, 0x116, 0x0, ...)

debugging

@ethanfrey
Copy link
Member

Thank you for the screen shot with captured variables.

Can you add which version you are using?

@whylee259
Copy link
Author

I have tried the code of master branch(576f620).
I think it has been in since ca040da

@alpe alpe added this to the v0.14.0 milestone Dec 11, 2020
@alpe alpe added the bug Something isn't working label Dec 11, 2020
@alpe
Copy link
Contributor

alpe commented Dec 11, 2020

@whylee259 thanks a lot for reporting this issue. 💐
The code affected comes originally from the cosmos-sdk simapp which is a template for other chains. I will report this issue upstream so that it gets fixed there, too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants