Skip to content
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

web3 server-side changes (JSON RPC spec compliance + bug-fixes) #75

Merged
merged 3 commits into from
Mar 2, 2018

Conversation

ali-sharif
Copy link
Contributor

@ali-sharif ali-sharif commented Mar 1, 2018

courtesy of Shidokht.

fix for #74

Copy link
Contributor Author

@ali-sharif ali-sharif left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need review from either Chris or Ross if this change breaks miner compatibility

@@ -169,8 +169,7 @@ private static JSONObject process(final IRpc.Method _method, final long _id, fin

case eth_getWork:
// Header without nonce and solution , pool needs add new nonce
return processResult(_id, api.getBestBlock().getHeader().getHeaderBytes(true));

return processResult(_id, toHexString(HashUtil.h256(api.getBestBlock().getHeader().getHeaderBytes(true))));
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need review from @aion-6368726973 or @aion-Ross if this will break miner compatibility.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At this time it should not break the reference miners/pool as they are relying on the "getblocktemplate" call.

However why are we returning a hash of the block header? If we want to update this to return Equihash work we would need eth_getWork to return the entire block header. Our result will be quite different from the referenced eth_getWork.

Copy link
Contributor

@aion-Ross aion-Ross left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes shouldn't cause any problems with miner.

@ali-sharif ali-sharif merged commit 751a98b into dev Mar 2, 2018
@ali-sharif ali-sharif deleted the dev-api branch March 2, 2018 18:18
@AionJayT AionJayT mentioned this pull request Mar 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants