-
Notifications
You must be signed in to change notification settings - Fork 102
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
Update Rust and Types #197
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. I just don't know about the JSON representation of pub gas_limit: Option<u64>
type SubMsg struct { | ||
ID uint64 `json:"id"` | ||
Msg CosmosMsg `json:"msg"` | ||
GasLimit *uint64 `json:"gas_limit,omitempty"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The JSON schema says this is null
or an integer:
"SubMsg_for_CustomMsg": {
"description": "A sub-message that will guarantee a subcall_response callback on success or error Note on error the subcall will revert any partial state changes due to this message, but not revert any state changes in the calling contract (that must be done in the subcall_response entry point)",
"type": "object",
"required": [
"id",
"msg"
],
"properties": {
"gas_limit": {
"type": [
"integer",
"null"
],
"format": "uint64",
"minimum": 0.0
},
"id": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"msg": {
"$ref": "#/definitions/CosmosMsg_for_CustomMsg"
}
}
},
Are you sure it works with *uint64
and omitempty
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not a required field. This works fine
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Alright, and it only needs to work from Rust to Go. Then we receive a number of null
in Go.
Closes #196