We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
While I was writing a Python script for big-data challenge, detected a weird response from RPC server:
Get validators method with block_height: 2018939 And save result.epoch_start_height (2008940)
BLOCK_HEIGHT_epoch_start_height=$(curl -s -X POST 'https://rpc.shardnet.near.org' \ -H 'Content-Type: application/json' \ -d '{ "jsonrpc": "2.0", "id": "dontcare", "method": "validators", "params": [2018939] }' -s | jq .result.epoch_start_height)
Call block method with the epoch_start_height
curl -s -X POST 'https://rpc.shardnet.near.org' \ -H 'Content-Type: application/json' \ -d '{ "jsonrpc": "2.0", "id": "dontcare", "method": "block", "params": { "block_id": '$BLOCK_HEIGHT_epoch_start_height' } }' -s | jq
Validators method should answer 2008939 as epoch_start_height, instead of non-exiting block (2008940) The 2008941 block says: "prev_height": 2008939
"prev_height": 2008939
2008940 response is:
"jsonrpc": "2.0", "error": { "name": "HANDLER_ERROR", "cause": { "info": {}, "name": "UNKNOWN_BLOCK" }, "code": -32000, "message": "Server error", "data": "DB Not Found Error: BLOCK HEIGHT: 2008940 \n Cause: Unknown" }, "id": "dontcare" }```
The text was updated successfully, but these errors were encountered:
No branches or pull requests
While I was writing a Python script for big-data challenge, detected a weird response from RPC server:
Step 1
Get validators method with block_height: 2018939
And save result.epoch_start_height (2008940)
Setp 2
Call block method with the epoch_start_height
Expected result
Validators method should answer 2008939 as epoch_start_height, instead of non-exiting block (2008940)
The 2008941 block says:
"prev_height": 2008939
Actual result
2008940 response is:
The text was updated successfully, but these errors were encountered: