prusnak/suez

edge not foud

Closed this issue · 2 comments

I'm not sure if this project intends to cover all weird edge cases, but just in case, here's another one:

...
XXX 2171602535068008448
XXX 2130060786746851328
XXX 1598976879324692480
XXX 2163737728395575296
[lncli] rpc error: code = Unknown desc = edge not found
[lncli] rpc error: code = Unknown desc = unable to find node
Traceback (most recent call last):
  File "./suez", line 5, in <module>
    suez()
  File "/home/bitcoin/.local/lib/python3.6/site-packages/click/core.py", line 1137, in __call__
    return self.main(*args, **kwargs)
  File "/home/bitcoin/.local/lib/python3.6/site-packages/click/core.py", line 1062, in main
    rv = self.invoke(ctx)
  File "/home/bitcoin/.local/lib/python3.6/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/bitcoin/.local/lib/python3.6/site-packages/click/core.py", line 763, in invoke
    return __callback(*args, **kwargs)
  File "/home/bitcoin/Download/src/suez/suez.py", line 53, in suez
    ln = clients[client](client_args)
  File "/home/bitcoin/Download/src/suez/lndclient.py", line 10, in __init__
    self.refresh()
  File "/home/bitcoin/Download/src/suez/lndclient.py", line 61, in refresh
    chan.remote_alias = self._run("getnodeinfo", chan.remote_node_id)["node"][
  File "/home/bitcoin/Download/src/suez/lndclient.py", line 115, in _run
    return json.loads(j.stdout)
  File "/usr/lib/python3.6/json/__init__.py", line 354, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.6/json/decoder.py", line 339, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.6/json/decoder.py", line 357, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
[bitcoin@lnd-tst suez]$ lncli getchaninfo 2163737728395575296
[lncli] rpc error: code = Unknown desc = edge not found
[bitcoin@lnd-tst suez]$
        {
            "active": false,
            "remote_pubkey": "02bda6b2aeb315edd874d72ac2873e343448e7e5f126f62cee225f284de392debe",
            "channel_point": "b605fc85e5b95b744d065877de19762697df1721d95ca02b44a3b3a0d6ca0b8e:0",
            "chan_id": "2163737728395575296",
            "capacity": "1999810",
            "local_balance": "0",
            "remote_balance": "1999627",
            "commit_fee": "183",
            "commit_weight": "552",
            "fee_per_kw": "253",
            "unsettled_balance": "0",
            "total_satoshis_sent": "0",
            "total_satoshis_received": "0",
            "num_updates": "0",
            "pending_htlcs": [
            ],
            "csv_delay": 1008,
            "private": true,
            "initiator": false,
            "chan_status_flags": "ChanStatusDefault",
            "local_chan_reserve_sat": "19998",
            "remote_chan_reserve_sat": "19998",
            "static_remote_key": true,
            "commitment_type": "STATIC_REMOTE_KEY",
            "lifetime": "84858",
            "uptime": "0",
            "close_address": "",
            "push_amount_sat": "0",
            "thaw_height": 0,
            "local_constraints": {
                "csv_delay": 1008,
                "chan_reserve_sat": "19998",
                "dust_limit_sat": "573",
                "max_pending_amt_msat": "1999810000",
                "min_htlc_msat": "1",
                "max_accepted_htlcs": 5
            },
            "remote_constraints": {
                "csv_delay": 240,
                "chan_reserve_sat": "19998",
                "dust_limit_sat": "546",
                "max_pending_amt_msat": "1979812000",
                "min_htlc_msat": "1",
                "max_accepted_htlcs": 483
            }
        },

Should be fixed in latest code, see #13.

Right, please git pull.