Use multi-resolve feature of LBRY API and other resolve clean-up #392

Closed
opened 2017-07-26 23:43:17 +02:00 by kauffj · 16 comments
kauffj commented 2017-07-26 23:43:17 +02:00 (Migrated from github.com)
  • Update discover landing page to pass all URLs to resolve at once, rather than one at a time.
  • Drop the XHR caching of resolve calls
  • Change FileCard, ShowPage, and possibly other components to always call resolve (#511), rather than only if the claim is undefined. This can only be done after the above two.
- [ ] Update discover landing page to pass all URLs to `resolve` at once, rather than one at a time. - [ ] Drop the XHR caching of resolve calls - [ ] Change `FileCard`, `ShowPage`, and possibly other components to always call resolve (#511), rather than only if the claim is undefined. This can only be done after the above two.
hackrush01 commented 2017-08-28 11:56:11 +02:00 (Migrated from github.com)

@jackrobison
While trying out the resolve API command I encountered the following issue

This is what I get when I use resolve using uri param
https://pastebin.com/nzk7hjvS

This is what I get when I use resolve using uris param
https://pastebin.com/7TDQirkY

Am I doing something wrong? Can't there be a single URI in uris param.

@jackrobison While trying out the resolve API command I encountered the following issue This is what I get when I use `resolve` using `uri` param https://pastebin.com/nzk7hjvS This is what I get when I use `resolve` using `uris` param https://pastebin.com/7TDQirkY Am I doing something wrong? Can't there be a single URI in `uris` param.
kauffj commented 2017-08-28 14:32:32 +02:00 (Migrated from github.com)

@hackrush01 just pass it as an array:

curl 'http://localhost:5279/lbryapi' --data '{"method":"resolve", "params":{"uris":["lbry://@hackrush/holi"]}}'

@hackrush01 just pass it as an array: `curl 'http://localhost:5279/lbryapi' --data '{"method":"resolve", "params":{"uris":["lbry://@hackrush/holi"]}}'`
hackrush01 commented 2017-08-28 14:55:31 +02:00 (Migrated from github.com)

Ah, I tried the other 2 brackets and then gave up :-P

Ah, I tried the other 2 brackets and then gave up :-P
kauffj commented 2017-08-30 00:41:33 +02:00 (Migrated from github.com)

@hackrush01 if you are ever blocked on tipping, this is a good one to come back to. Big low-hanging optimization here.

@hackrush01 if you are ever blocked on tipping, this is a good one to come back to. Big low-hanging optimization here.
hackrush01 commented 2017-08-30 03:38:27 +02:00 (Migrated from github.com)

Sure thing.

-Regards
-Amit Tulshyan

On 30-Aug-2017 4:11 am, "Jeremy Kauffman" notifications@github.com wrote:

@hackrush01 https://github.com/hackrush01 if you are ever blocked on
tipping, this is a good one to come back to. Big low-hanging optimization
here.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/lbryio/lbry-app/issues/392#issuecomment-325825234,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AQxPZo-2LvMEuh2FZre7oE-NNMxqdE5Fks5sdJOegaJpZM4OkhyB
.

Sure thing. -Regards -Amit Tulshyan On 30-Aug-2017 4:11 am, "Jeremy Kauffman" <notifications@github.com> wrote: > @hackrush01 <https://github.com/hackrush01> if you are ever blocked on > tipping, this is a good one to come back to. Big low-hanging optimization > here. > > — > You are receiving this because you were mentioned. > Reply to this email directly, view it on GitHub > <https://github.com/lbryio/lbry-app/issues/392#issuecomment-325825234>, > or mute the thread > <https://github.com/notifications/unsubscribe-auth/AQxPZo-2LvMEuh2FZre7oE-NNMxqdE5Fks5sdJOegaJpZM4OkhyB> > . >
tzarebczan commented 2017-09-29 18:12:20 +02:00 (Migrated from github.com)

Would something like this also be fixed as part of this effort? https://github.com/lbryio/lbry-app/issues/451

Would something like this also be fixed as part of this effort? https://github.com/lbryio/lbry-app/issues/451
minersmoss commented 2017-10-06 01:45:26 +02:00 (Migrated from github.com)

Launched LBRY app on Win10 x64 desltop. App launched and asked for update, which I clicked. Programmed crashed and now won't launch. What is the fix? Thanks

Launched LBRY app on Win10 x64 desltop. App launched and asked for update, which I clicked. Programmed crashed and now won't launch. What is the fix? Thanks
tzarebczan commented 2017-10-06 01:48:07 +02:00 (Migrated from github.com)

I'd say restart your pc, and reinstall the latest version from lbry.io/get

That should get you back up and running, otherwise check out https://lbry.io/faq/startup-troubleshooting

I'd say restart your pc, and reinstall the latest version from lbry.io/get That should get you back up and running, otherwise check out https://lbry.io/faq/startup-troubleshooting
alexliebowitz commented 2017-10-10 07:42:46 +02:00 (Migrated from github.com)

Fixed by #653.

Fixed by #653.
tzarebczan commented 2017-10-10 18:23:06 +02:00 (Migrated from github.com)

When I type something random into the address bar like "testingsearch123" (which is not a valid claim)- the search page continues to show "loading..." and when I click enter / the claim, I get "loading magic decentralized data...".

The resolve call does return:

{
  "id": 90,
  "jsonrpc": "2.0",
  "result": {
    "lbry://testingsearch123": {
      "error": "URI lbry://testingsearch123 cannot be resolved"
    }
  }
}

Same happens when you type Teleporter into the search bar.

If I go Home and search for the same item again, I don't see another resolve call but I get the same results. If I type another 1 at the end (testingsearch1231), then it says "this location is unused" but there is also no resolve call made.

Another finding - searching for wqwqwqwq brings up a channel in the search results that says "This is a channel with over 10 items inside of it" but the channel only has 1 item. Filed this here: https://github.com/lbryio/lbry-app/issues/659

{
  "id": 143,
  "jsonrpc": "2.0",
  "result": {
    "lbry://@wqwqwqwqwqwqwq#a4c06b2c73362a3120a99c0fa9a36886109284e5": {
      "certificate": {
        "address": "bUCN61BxRty64d36gbFyMCA3HP241pkU8y",
        "amount": 0.0001,
        "claim_id": "a4c06b2c73362a3120a99c0fa9a36886109284e5",
        "claim_sequence": 1,
        "decoded_claim": true,
        "depth": 35328,
        "effective_amount": 0.0001,
        "has_signature": false,
        "height": 218370,
        "hex": "08011002225e0801100322583056301006072a8648ce3d020106052b8104000a0342000439cc40677efc7320c8c7263c4a27b6dd58a4bab2b8c0e211f88b30a4f471626064c9457d87bc16f6ef8ea0e99fd32e2155b3c47b2a1c785738135c5bc50b735c",
        "name": "@wqwqwqwqwqwqwq",
        "nout": 0,
        "supports": [],
        "txid": "550a601d5f6b8c1e99cec2179ab260c7e1a7d4216eb0115242d91866a78b54d4",
        "valid_at_height": 218370,
        "value": {
          "certificate": {
            "keyType": "SECP256k1",
            "publicKey": "3056301006072a8648ce3d020106052b8104000a0342000439cc40677efc7320c8c7263c4a27b6dd58a4bab2b8c0e211f88b30a4f471626064c9457d87bc16f6ef8ea0e99fd32e2155b3c47b2a1c785738135c5bc50b735c",
            "version": "_0_0_1"
          },
          "claimType": "certificateType",
          "version": "_0_0_1"
        }
      },
      "claims_in_channel": 1
    }
  }
}

When I type something random into the address bar like "testingsearch123" (which is not a valid claim)- the search page continues to show "loading..." and when I click enter / the claim, I get "loading magic decentralized data...". The resolve call does return: ``` { "id": 90, "jsonrpc": "2.0", "result": { "lbry://testingsearch123": { "error": "URI lbry://testingsearch123 cannot be resolved" } } } ``` Same happens when you type Teleporter into the search bar. If I go Home and search for the same item again, I don't see another resolve call but I get the same results. If I type another 1 at the end (testingsearch1231), then it says "this location is unused" but there is also no resolve call made. Another finding - searching for wqwqwqwq brings up a channel in the search results that says "This is a channel with over 10 items inside of it" but the channel only has 1 item. Filed this here: https://github.com/lbryio/lbry-app/issues/659 ``` { "id": 143, "jsonrpc": "2.0", "result": { "lbry://@wqwqwqwqwqwqwq#a4c06b2c73362a3120a99c0fa9a36886109284e5": { "certificate": { "address": "bUCN61BxRty64d36gbFyMCA3HP241pkU8y", "amount": 0.0001, "claim_id": "a4c06b2c73362a3120a99c0fa9a36886109284e5", "claim_sequence": 1, "decoded_claim": true, "depth": 35328, "effective_amount": 0.0001, "has_signature": false, "height": 218370, "hex": "08011002225e0801100322583056301006072a8648ce3d020106052b8104000a0342000439cc40677efc7320c8c7263c4a27b6dd58a4bab2b8c0e211f88b30a4f471626064c9457d87bc16f6ef8ea0e99fd32e2155b3c47b2a1c785738135c5bc50b735c", "name": "@wqwqwqwqwqwqwq", "nout": 0, "supports": [], "txid": "550a601d5f6b8c1e99cec2179ab260c7e1a7d4216eb0115242d91866a78b54d4", "valid_at_height": 218370, "value": { "certificate": { "keyType": "SECP256k1", "publicKey": "3056301006072a8648ce3d020106052b8104000a0342000439cc40677efc7320c8c7263c4a27b6dd58a4bab2b8c0e211f88b30a4f471626064c9457d87bc16f6ef8ea0e99fd32e2155b3c47b2a1c785738135c5bc50b735c", "version": "_0_0_1" }, "claimType": "certificateType", "version": "_0_0_1" } }, "claims_in_channel": 1 } } } ```
tzarebczan commented 2017-10-10 20:44:33 +02:00 (Migrated from github.com)

https://github.com/lbryio/lbry-app/issues/511 is not fixed - I updated a claim and it continued to show the incorrect amount/claim data in the app, even though resolve shows correct data (when running from CLI). Maybe this has to do with caching or Jeremy's comment here: https://github.com/lbryio/lbry-app/issues/451#issuecomment-335543119

https://github.com/lbryio/lbry-app/issues/511 is not fixed - I updated a claim and it continued to show the incorrect amount/claim data in the app, even though resolve shows correct data (when running from CLI). Maybe this has to do with caching or Jeremy's comment here: https://github.com/lbryio/lbry-app/issues/451#issuecomment-335543119
tzarebczan commented 2017-10-11 23:21:26 +02:00 (Migrated from github.com)

lbry://@kazeemanuar - (not a valid claim) gets stuck on "Loading magic decentralized data" - probably the same issue as reported above.

lbry://@kazeemanuar - (not a valid claim) gets stuck on "Loading magic decentralized data" - probably the same issue as reported above.
kauffj commented 2017-10-12 01:21:44 +02:00 (Migrated from github.com)

Something weird is going on here but not sure if multi-resolve related...

Something weird is going on here but not sure if multi-resolve related...
kauffj commented 2017-10-12 16:03:57 +02:00 (Migrated from github.com)

The way empty/unclaimed URLs are being returned was changed in lbry, breaking resolution of unclaimed URLs.

This will be (hack) fixed in 0.17.0rc3

The way empty/unclaimed URLs are being returned was changed in `lbry`, breaking resolution of unclaimed URLs. This will be (hack) fixed in 0.17.0rc3
kauffj commented 2017-10-15 15:15:33 +02:00 (Migrated from github.com)

@tzarebczan if there are any outstanding issues here, please open as separate ticket

@tzarebczan if there are any outstanding issues here, please open as separate ticket
tzarebczan commented 2017-10-15 15:19:53 +02:00 (Migrated from github.com)

Nope, all good besides the slowness. Where do you think we can make this process faster? On the resolve itself?

Nope, all good besides the slowness. Where do you think we can make this process faster? On the resolve itself?
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/lbry-desktop#392
No description provided.