forked from dagurval/electrum-cash-protocol
-
Notifications
You must be signed in to change notification settings - Fork 3
Documentation changes for Protocol 1.6 #5
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
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
f50cbcc
Begin to document protocol v1.6 changes
cculianu 83b91cb
Update document version to 1.6.0, clarify mempool ordering
cculianu 4162b7c
Various tweaks, refer to mempool ordering in more places, various nit…
cculianu 66b5910
Added .gitignore for .build/
cculianu 81363c4
Document blockchain.block.headers change for 1.6; more misc doc tweaks
cculianu d94a696
Added documentation for blockchain.transaction.broadcast_package
cculianu 03e8447
Added broadcast_package (optional bool) to server.features map
cculianu 797c322
Added blockchain.transaction.broadcast_package error examples
cculianu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| _build/ |
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
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
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
Oops, something went wrong.
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.
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.
note the txid is in network byte-order here, not the human-readable form
Uh oh!
There was an error while loading. Please reload this page.
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 the review here.
In Fulcrum, internally, I keep the hashes as bytes but in human-readable byte order always (to avoid having to reverse them when presenting them to RPCs or in human-readable form) -- Electron Cash on BCH also assumes this now. This kind of throws a wrench into the works for me to have to change this... why are you keeping them in memory in non-human readable form anyway? It's just wasted cycles to do that since internally you don't really care about exact hash value you just care about communicating to the client (in human readable hex form) and to the daemon (again, in the same ordering).
Hmm... :/
Note that the only reason the hash is "reversed" when stringified in bitcoind anyway is due to a historical quirk of sorts -- the hashes (sometimes) were uint256 values treated as a little-endian integer (as is the case with a block hash). They ended up getting "reversed" so they print nicely because humans read numbers in big endian order.
But most hashes are never internally treated as integers anymore so.. the whole reversing-them-to-print is kind of nonsensical in the first place... but since that stupidity is enforced in the RPC interface and when printing hashes.. better to keep them in memory in the "ready to print" and "ready to send to RPC" form when communicating with bitcoind, clients, etc, if you ask me.