XRPLF / rippled

Decentralized cryptocurrency blockchain daemon implementing the XRP Ledger protocol in C++
https://xrpl.org
ISC License
4.48k stars 1.45k forks source link

path_find not returning paths to XRP #2146

Closed cometburn closed 6 years ago

cometburn commented 7 years ago
{
    "id": "XRP",
    "command": "path_find",
    "subcommand": "create",
    "source_account": "XXXX",
    "send_max": {
        "currency": "ETH",
        "value": "1",
        "issuer": "ZZZZ"
    },
    "destination_account": "XXXX",
    "destination_amount": "-1"
}

provided that:

when i send that command through websocket, it doesn't return any paths.

Can anyone enlighten me on this?

JoelKatz commented 7 years ago

It's hard to know exactly what the issue is without seeing the exact situation. Two possibilities: 1) You are looking at the immediate reply to the path creation rather than waiting for the pathfinding to complete and provide a full reply. The immediate reply only finds "obvious" paths. 2) There is no path that will work. For example, there may be no liquidity at all between ETH/ZZZZ and XRP.

cometburn commented 7 years ago

Hello Sir, Thank you for replying.

screen shot 2017-06-17 at 10 51 55

What I'm doing is finding paths for ETH to XRP... but "alternatives" is empty..

cometburn commented 7 years ago

also on the documentation, it says

You can specify "-1" (for XRP) or provide -1 as the contents of the value field (for non-XRP currencies).

JoelKatz commented 7 years ago

The source account does not hold any of the asset it's trying to send, nor can it borrow any.

      "account" : "r4ZMZxtNMcqLYWcFAAxmueJaQLfSLENMdo",  
      "ledger_current_index" : 30580192,  
      "lines" : [
         ...
         {
            "account" : "rcA8X3TVMST1n3CJeAdGk1RdRCHii7N2h",
            "balance" : "0", <--
            "currency" : "ETH",
            "limit" : "1000000000",
            "limit_peer" : "0",
            "no_ripple" : true,
            "quality_in" : 0,
            "quality_out" : 0
         },
         ...
    ]