wormhole-foundation / wormhole

A reference implementation for the Wormhole blockchain interoperability protocol.
https://wormhole.com
Other
1.66k stars 684 forks source link

cosmwasm: add support for json schemas for all contracts #4118

Open kakucodes opened 2 weeks ago

kakucodes commented 2 weeks ago

The purpose of this pull request is to update the cosmwasm contracts with the ability to export json schemas. These schemas are useful not only for frontend consumption (Typescript codegeneration) but also for Go and Interchain Test.

By and large the changes make all of the existing cosmwasm contracts a bit more homogeneous and fix some style differences between them. I added cosmwasm-schema where it didn't already exist and annotated query return types where they were not already specified. Additionally I swapped out the older style trait derives for serializable data types to use the cw_serde macro again for the sake of homogeneity in the workspace.