Add supports on getclaimbyid RPC command #124

Closed
opened 2018-04-23 16:37:35 +02:00 by shyba · 2 comments
shyba commented 2018-04-23 16:37:35 +02:00 (Migrated from github.com)

getclaimbyid calculates the effective amount, but doesn't returns the supports list. Supports are needed for our electrum layer. For getting it we actually need to call getclaimsforname, which transfer more data then needed and adds an extra call.

@lbrynaut proposed a new index for supports over claim ids. I think it's the way to go, but we should discuss here.

I have some very ugly proof of concept here with a new JSON format for it: 2fdd202cbf

Some other idea was to make the support listing optional with an extra boolean parameter like includeSupports.

`getclaimbyid` calculates the effective amount, but doesn't returns the supports list. Supports are needed for our electrum layer. For getting it we actually need to call `getclaimsforname`, which transfer more data then needed and adds an extra call. @lbrynaut proposed a new index for supports over claim ids. I think it's the way to go, but we should discuss here. I have some very ugly proof of concept here with a new JSON format for it: https://github.com/shyba/lbrycrd/commit/2fdd202cbf0908ca9441e6edbd6e667ce5c9a7a1 Some other idea was to make the support listing optional with an extra boolean parameter like `includeSupports`.
lbrynaut commented 2018-04-23 16:41:33 +02:00 (Migrated from github.com)

@shyba Thanks for filing this. After the claimindex PR (#110) is merged, I'll start by making supports returned from the appropriate methods to avoid calling (effectively) the same things multiple times.

@shyba Thanks for filing this. After the claimindex PR (#110) is merged, I'll start by making supports returned from the appropriate methods to avoid calling (effectively) the same things multiple times.
shyba commented 2018-04-24 02:02:09 +02:00 (Migrated from github.com)

@lbrynaut something I also had to add but is pretty simple, maybe not worth another issue:
claim.push_back(Pair("valid at height", claimValue.nValidAtHeight));

@lbrynaut something I also had to add but is pretty simple, maybe not worth another issue: `claim.push_back(Pair("valid at height", claimValue.nValidAtHeight));`
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: LBRYCommunity/lbrycrd#124
No description provided.