Commit Graph

116 Commits

Author SHA1 Message Date
ThomasV b5482e4470 create transport and perform handshake before creating Peer 2019-08-20 09:03:11 +02:00
ThomasV 61638664f7 do not add ephemeral addresses to recent peers 2019-08-20 09:03:11 +02:00
ThomasV d383573bc3 CLI: use funding_point in channel_open and channel_close. add host:port to nodeid 2019-08-20 09:03:11 +02:00
ThomasV 0924503cb6 rpartition->rsplit 2019-08-20 09:03:11 +02:00
ThomasV f04e10f61a save channel timestamps, and show lightning payments in history tab 2019-08-20 09:03:11 +02:00
ThomasV ae402303ca channel: is_closed 2019-08-20 09:03:11 +02:00
ThomasV f6f5cbee72 fix lnworker.get_balance 2019-08-20 09:03:11 +02:00
ThomasV b7d93e2e11 gui: display lightning balance in status bar 2019-08-20 09:03:11 +02:00
Janus 18bd934461 ln: show full chan id in list, use Event for initialized, more timeouts, return peer from add_peer, set max_htlc_value_in_flight_msat to capacity 2019-08-20 09:03:11 +02:00
ThomasV 2af178a586 Store boolean is_received in lightning invoices. Sort lightning history with timestamp. Minor fixes 2019-08-20 09:03:11 +02:00
ThomasV 0e8dba897e lightning:
* store invoices for both directions
* do not store lightning_payments_inflight, lightning_payments_completed in lnworker
* payment history is returned by get_payments method of LNChannel
* command line: lightning history, lightning_invoices
* re-enable push_msat
2019-08-20 09:03:11 +02:00
Janus e6bd3959e0 ln: handle channel limits better, show remote limits in details dialog, replace rusty's testnet peer (doesn't work currently) 2019-08-20 09:03:11 +02:00
ThomasV 0a08ccc1c6 rename paying -> inflight 2019-08-20 09:03:11 +02:00
ThomasV b0d6000771 turn lightning_payments_completed into dict. Show status of lightning payments in GUI. Make 'listchannels' available offline 2019-08-20 09:03:11 +02:00
ThomasV 26ced1b343 fix test 2019-08-20 09:03:11 +02:00
ThomasV d789f11898 remove deterministic derivation for testing 2019-08-20 09:03:11 +02:00
ThomasV e6d680ec1b instanciate LNWorker without Network 2019-08-20 09:03:11 +02:00
Janus 7cf4f40dcb ln: warn when negotiated feerate is too low 2019-08-20 09:03:11 +02:00
Janus 8fc1779b0d ln: add test_lnwatcher 2019-08-20 09:03:11 +02:00
Janus 129099797a lnworker: handle null whitelist correctly 2019-08-20 09:03:11 +02:00
Janus 3b44cf8c67 lnworker: fix 'channel details' with stuck htlc 2019-08-20 09:03:11 +02:00
Janus bd45f3f1c8 lnworker: return txid from force_close_channel as expected 2019-08-20 09:03:11 +02:00
Janus e56e849505 lnchan refactor
- replace undoing logic with new HTLCManager class
- separate SENT/RECEIVED
- move UpdateAddHtlc to lnutil
2019-08-20 09:03:11 +02:00
ThomasV cf3e050b7e fix error message 2019-08-20 09:03:11 +02:00
ThomasV fde9f91902 lnchannel: store pre-signed sweep transactions after each new commitment 2019-08-20 09:03:11 +02:00
ThomasV 3019aa35cf on_close_channel: fix output index, and simplify lnsweep 2019-08-20 09:03:11 +02:00
ThomasV 729ddb8ec3 LNWatcher refactoring:
- do not store non-breach transactions
 - send 'channel_open' and 'channel_closed' events
 - force-closed channels are handled by LNWorker
2019-08-20 09:03:11 +02:00
Janus 133e5ec8c3 use gossip_timestamp_filter instead of request_initial_sync 2019-08-20 09:03:11 +02:00
Janus 864d910888 qt: channel_details: add more info: sent/received, channel id, funding tx, short channel id, node id 2019-08-20 09:03:11 +02:00
SomberNight 595cfcbb65 move sweeping methods from lnchan.py to new file
also sweep "received" htlcs from "our" ctx
also sweep htlcs from their ctx (non-breach)
extract ctn; included_htlcs_in_their_latest_ctxs
2019-08-20 09:03:11 +02:00
ThomasV 88c6eeb966 make LNWatcher inherit AddressSynchronizer 2019-08-20 09:03:11 +02:00
Janus e3409d32ef channel details with list of htlcs 2019-08-20 09:03:11 +02:00
Janus 9d32031ca2 Kivy: Lightning support in Receive tab 2019-08-20 09:03:11 +02:00
Janus 7db9a22d63 Kivy: open channel dialog 2019-08-20 09:03:11 +02:00
Janus 1352b0ce9f Kivy: Support Lightning in Send tab 2019-08-20 09:03:11 +02:00
Janus 1425628604 add command for listing invoices and their progress, fix list_channels 2019-08-20 09:03:11 +02:00
Janus c570bc5fb1 avoid leaving FORCE_CLOSING state, rebroadcast closing tx if reorged out 2019-08-20 09:03:11 +02:00
Janus 0ea87278fb move force_close_channel to lnbase, test it, add FORCE_CLOSING state 2019-08-20 09:03:11 +02:00
SomberNight c0ae7b5534 after rebase clean-up 2019-08-20 09:03:10 +02:00
Janus 7e76e82152 test_lnbase: add test that pays to another local electrum 2019-08-20 09:03:10 +02:00
SomberNight 449ec013fe add licence headers to more files 2019-08-20 09:03:10 +02:00
Janus a42c1067ab lnworker: fix listchannels 2019-08-20 09:03:10 +02:00
ThomasV eb4e6b2e54 use WaitingDialog to close channels 2019-08-20 09:03:10 +02:00
ThomasV 70dbd8e672 add close_channel method to peer 2019-08-20 09:03:10 +02:00
SomberNight 54edc9488a lnworker: store invoices based on payment_hash 2019-08-20 09:03:10 +02:00
SomberNight f70e679aba some more type annotations that needed conditional imports 2019-08-20 09:03:10 +02:00
SomberNight 2364de930b lnrouter: run Dijkstra in reverse direction 2019-08-20 09:03:10 +02:00
SomberNight 7edbd5682a fix confusion re max path length 2019-08-20 09:03:10 +02:00
SomberNight 2fafd01945 protect against getting robbed through routing fees 2019-08-20 09:03:10 +02:00
SomberNight d511ecdc00 start failing htlcs 2019-08-20 09:03:10 +02:00