-
Notifications
You must be signed in to change notification settings - Fork 228
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
Replace RPC ABCI types with ABCI domain types #1204
Conversation
Signed-off-by: Thane Thomson <[email protected]>
Signed-off-by: Thane Thomson <[email protected]>
Signed-off-by: Thane Thomson <[email protected]>
…ermint::Hash Signed-off-by: Thane Thomson <[email protected]>
Does not seem to be used for anything.
First attempt, with a serialization snag in tendermint-proto.
Instead of deriving serde on raw proto types to de/serialize abci::response::DeliverTx, abci::Event, and abci::EventAttribute, derive on the domain types directly. This disentangles the serialization, now primarily used by JSON-RPC, from protobuf struct definitions which are subject to change for Tendermint Core 0.37 (in case of EventAttribute).
In tendermint-rpc, the only place where Gas newtype is still used is in the response to /broadcast_tx_commit, which is a development-only endpoint. Leave the response struct defined through tx_commit::TxResult for the time being. Define serialization of abci::response::CheckTx (currently not used) to match that of DeliverTx.
Also in tendermint, remove validator::Update which duplicates abci::types::ValidatorUpdate.
With it goes mod abci::responses.
b602e09
to
5725d4f
Compare
Codecov Report
@@ Coverage Diff @@
## main #1204 +/- ##
=======================================
+ Coverage 64.0% 64.3% +0.3%
=======================================
Files 253 244 -9
Lines 21636 21345 -291
=======================================
- Hits 13851 13736 -115
+ Misses 7785 7609 -176
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Promote this to a proper domain type.
This was the last of the ABCI helper types defined in tendermint-rpc, and with it goes the abci module.
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.
Thanks for disentangling all this @mzabaluev!
/// | ||
/// Used to inform Tendermint of changes to the validator set. | ||
/// | ||
/// [ABCI documentation](https://docs.tendermint.com/master/spec/abci/abci.html#validatorupdate) |
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.
/// [ABCI documentation](https://docs.tendermint.com/master/spec/abci/abci.html#validatorupdate) | |
/// [ABCI documentation](https://github.com/tendermint/tendermint/blob/v0.34.x/spec/abci/abci.md#validatorupdate) |
We currently do not make the spec available via the docs site, and the one from master
is no longer relevant. We also keep the specification relevant to the specific Tendermint release series on each release branch, so it's easier to see diffs in the specs between major releases of Tendermint.
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.
I think we can probably keep this as-is for this PR, but in a follow-up PR we should update all the spec references to rather point to the v0.34.x
branch of the Tendermint repo. I've created #1224 to track this.
Closes #1090 and #947
Picked up from #1092 by rebasing the branch onto
main
..changelog/