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

Add GasUsed to Reply #470

Merged
merged 1 commit into from
Nov 20, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions types/submessages.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,11 @@ type SubMsg struct {
ReplyOn replyOn `json:"reply_on"`
}

// The result object returned to `reply`. We always get the ID from the submessage back and then must handle success and error cases ourselves.
type Reply struct {
// The amount of gas used by the submessage, measured in [Cosmos SDK gas](https://github.com/CosmWasm/cosmwasm/blob/main/docs/GAS.md).
GasUsed uint64 `json:"gas_used"`
// The ID that the contract set when emitting the `SubMsg`. Use this to identify which submessage triggered the `reply`.
ID uint64 `json:"id"`
Result SubMsgResult `json:"result"`
}
Expand Down