-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Remove Tx Broadcast and Commit Support #3954
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #3954 +/- ##
===========================================
- Coverage 60.33% 60.21% -0.13%
===========================================
Files 196 196
Lines 14533 14557 +24
===========================================
- Hits 8768 8765 -3
- Misses 5181 5208 +27
Partials 584 584 |
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.
utACK
@@ -68,6 +68,7 @@ type TxResponse struct { | |||
TxHash string `json:"txhash"` | |||
Code uint32 `json:"code,omitempty"` | |||
Data []byte `json:"data,omitempty"` | |||
RawLog string `json:"raw_log,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.
++
func NewResponseFormatBroadcastTxCommit(res *ctypes.ResultBroadcastTxCommit) TxResponse { | ||
if !res.CheckTx.IsOK() { |
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.
++ much better here.
} | ||
return | ||
} | ||
switch ctx.BroadcastMode { |
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.
++
Left a few comments. Would really like to see the ability to set this via |
Another item bordering on this that might want to be a separate PR as well is short flags for |
yup, that's addressed in #3970. |
The swagger doc is not up to date here: |
The Swagger doc is updated: cosmos-sdk/client/lcd/swagger-ui/swagger.yaml Lines 227 to 291 in 8550d87
I don't know where that site pulls its docs from though. @fedekunze? |
it’s pulled from master |
Then it looks like it'll be resolved once 0.34 is released! |
--async
flag with--broadcast-mode
flag. This flag defaults tosync
which returns once CheckTx execution is finished. This is inline with the way nearly any other blockchain operates (e.g. broadcast and keep checking when it's included in a block).block
(commit) mode but this is mainly due to unit/integration tests. A doc entry has been added to stipulate this mode should not be used.Raw Log
entry to theTxResponse
. This is not JSON-encoded, but will allow getting a log entry when a tx fails pre message execution.closes: #3875
closes: #3941
Targeted PR against correct branch (see CONTRIBUTING.md)
Linked to github-issue with discussion and accepted design OR link to spec that describes this work.
Wrote tests
Updated relevant documentation (
docs/
)Added a relevant changelog entry:
sdkch add [section] [stanza] [message]
rereviewed
Files changed
in the github PR explorerFor Admin Use: