-
Notifications
You must be signed in to change notification settings - Fork 107
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
getblockchaininfo JSON-RPC method #3143
Comments
Hey team! Please add your planning poker estimate with ZenHub @conradoplg @dconnolly @gustavovalverde @oxarbitrage @teor2345 @upbqdn @jvff |
I am unsure about the I tried to get info from zcashd and i get all |
Something like: let next_block_height = (height + 1).expect("valid chain tips are a lot less than Height::MAX");
consensus.chaintip = NetworkUpgrade::current(network, height).branch_id();
consensus.nextblock = NetworkUpgrade::current(network, next_block_height).branch_id(); |
Motivation
lightwalletd
uses thegetblockchaininfo
JSON-RPC method.Dependencies
Required Fields
The method is documented here: https://zcash.github.io/rpc/getblockchaininfo.html
But only the following fields are used by
lightwalletd
: https://github.com/zcash/lightwalletd/blob/master/common/common.go#L70Field list:
The
zcashd
code that generates the network upgrade JSON is here:https://github.com/zcash/zcash/blob/6cd5b8792bbe0a3cc1064e1884914415f0c6e7d7/src/rpc/blockchain.cpp#L970
The
lightwalletd
code that parses the network upgrade JSON is here:https://github.com/adityapk00/lightwalletd/blob/c1bab818a683e4de69cd952317000f9bb2932274/common/common.go#L195
Tasks
lightwalletd
API Reference
We plan to use jsonrpc_core with:
Example Code
Here are examples of:
The text was updated successfully, but these errors were encountered: