types: first field in Canonical structs is Type#2675
Merged
Conversation
6877783 to
2998616
Compare
Codecov Report
@@ Coverage Diff @@
## develop #2675 +/- ##
===========================================
+ Coverage 61.69% 61.74% +0.04%
===========================================
Files 207 207
Lines 16902 16934 +32
===========================================
+ Hits 10428 10456 +28
- Misses 5607 5610 +3
- Partials 867 868 +1
|
liamsi
approved these changes
Oct 19, 2018
docs/spec/blockchain/encoding.md
Outdated
| Height int64 `binary:"fixed64"` | ||
| Round int64 `binary:"fixed64"` | ||
| VoteType byte | ||
| Type byte |
Contributor
There was a problem hiding this comment.
This would need to be the first field in the documentation too.
Contributor
Author
There was a problem hiding this comment.
Weird I thought I fixed that - thanks!
This was referenced Oct 19, 2018
liamsi
added a commit
to tendermint/tmkms
that referenced
this pull request
Oct 21, 2018
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Despite deciding in #1622 and ADR-024 to include a version field in the sign bytes, #2665 suggested it was unnecessary, so it was removed. Further discussion has re-iterated the desire for the HSMs to be able to independently reject schemas they do not know about, without relying on something like the KMS to do it for them.
Rather than bring back the Version field, we can use the existing
Type bytefield, which currently has only 4 defined types (prevote, precommit, proposal, heartbeat). If and when we need to upgrade the sign bytes format, we can introduce new types here. 256 options should be more than enough.