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

Check wasm public api before saving #108

Merged
merged 4 commits into from
Jan 13, 2020
Merged

Check wasm public api before saving #108

merged 4 commits into from
Jan 13, 2020

Conversation

ethanfrey
Copy link
Member

Closes #50

This adds logic to enforce that the wasm exports all required export functions, and only imports the available imports. We check this in CosmWasm.save(), which is the main public entrypoint to instantiate contracts. It is also available as check_api_compatibility().

More than just avoiding garbage contracts, this validates the versioning before failing later on init (or worse, handle) as there was a cosmwasm version mismatch between runtime and contract.

@ethanfrey ethanfrey merged commit ee175f2 into master Jan 13, 2020
@ethanfrey ethanfrey deleted the check-wasm-exports branch January 13, 2020 17:23
@ethanfrey ethanfrey mentioned this pull request Oct 20, 2020
12 tasks
brew0722 pushed a commit to brew0722/cosmwasm-1 that referenced this pull request Nov 9, 2021
* feat: Add release automation config

* fix: remove unneeded cmd

* feat: add doc for release

* fix: apply review

* ci: fix release process

* chore: fix generate_release_tag

* fix: remove template and fix release.yml

* chore: edit docs

* fix: change flow

* fix: fix error

* chore: fix grep format

* fix: remove libgcc

* fix: add check version
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.

Pre-check wasm before compiling
1 participant