-
Notifications
You must be signed in to change notification settings - Fork 37
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
feat(jellyfish-api-core): add getBlockTemplate RPC #1993
base: main
Are you sure you want to change the base?
Conversation
Code Climate has analyzed commit d8dab77 and detected 0 issues on this pull request. View more on Code Climate. |
✅ Deploy Preview for jellyfishsdk ready!
To edit notification comments on pull requests, go to your Netlify site settings. |
Codecov ReportBase: 59.81% // Head: 85.53% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #1993 +/- ##
===========================================
+ Coverage 59.81% 85.53% +25.72%
===========================================
Files 290 358 +68
Lines 9331 10795 +1464
Branches 1251 1410 +159
===========================================
+ Hits 5581 9234 +3653
+ Misses 3528 1483 -2045
+ Partials 222 78 -144
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
Docker build preview for jellyfish/apps is ready! Built with commit 083d745
You can also get an immutable image with the commit hash
|
* @param {TemplateRquest} templateRequest A json object in the following spec | ||
* @param {string} mode This must be set to 'template', 'proposal' (see BIP 23), or omitted | ||
* @param {string[]} capabilities client side supported feature, 'longpoll', 'coinbasetxn', 'coinbasevalue', 'proposal', 'serverlist', 'workid' | ||
* @param {string[]} rules A list of strings | ||
* @returns {Promise<void>} | ||
*/ | ||
async getBlockTemplate (templateRequest: TemplateRquest): Promise<JSON> { |
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.
Promise<JSON>
? It should be typed.
Co-authored-by: Fuxing Loh <[email protected]> Signed-off-by: DrPing <[email protected]>
Co-authored-by: Fuxing Loh <[email protected]> Signed-off-by: DrPing <[email protected]>
Co-authored-by: Fuxing Loh <[email protected]> Signed-off-by: DrPing <[email protected]>
docs/node/CATEGORIES/02-mining.md
Outdated
|
||
```ts title="client.mining.getBlockTemplate()" | ||
interface mining { | ||
getBlockTemplate (templateRequest: TemplateRequest): Promise<JSON> |
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.
BlockTemplate
and docs
Co-authored-by: Fuxing Loh <[email protected]> Signed-off-by: DrPing <[email protected]>
Co-authored-by: Fuxing Loh <[email protected]> Signed-off-by: DrPing <[email protected]>
What this PR does / why we need it:
Adds getBlockTemplate RPC, tests and documentation.
Which issue(s) does this PR fixes?:
Fixes part of #48
Additional comments?: