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

fix: return error when Wasm uncompression fails #60

Merged
merged 3 commits into from
Sep 29, 2023

Conversation

hacheigriega
Copy link
Member

@hacheigriega hacheigriega commented Sep 28, 2023

This PR fixes a bug that was introduced by an incorrect error handling. It also fixes message server unit tests and adds a few more cases.

expErrMsg: "Data Request Wasm with given hash already exists",
expErrMsg: "data Request Wasm with given hash already exists",
},
// TO-DO: Add after migrating ValidateBasic logic
Copy link
Member

@mariocao mariocao Sep 29, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the logic not already there?

if msg.WasmType != WasmTypeDataRequest && msg.WasmType != WasmTypeTally {

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes! But Cosmos is encouraging us to put that logic directly in msg_server starting with v0.50. See cosmos/cosmos-sdk#15648

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants