Commit graph

16010 commits

Author SHA1 Message Date
Olaoluwa Osuntokun
771d1f0a9c
Merge pull request #8338 from lightningnetwork/coop-close-v2-wire-messages
lnwire: add new closing_complete and closing_sig messages
2024-02-05 17:08:36 -08:00
Olaoluwa Osuntokun
ba3c0c497a
.github: codeowners additions 2024-02-05 16:30:31 -08:00
Olaoluwa Osuntokun
5953eaa9d8
lnwire: add fuzz tests for ClosingComplete+ClosingSigs 2024-02-05 16:30:26 -08:00
Olaoluwa Osuntokun
3d88017b38
lnwire: add new closing_complete and closing_sig messages
These two messages will be used to implement the new and improved co-op
closing protocol. This PR also show cases how to use the new
`tlv.OptionalRecord` type to define and handle TLV level parsing.

I think we can make one additional helper function to clean up some of
the boiler plate for the encode/decode.
2024-02-05 16:30:23 -08:00
Olaoluwa Osuntokun
34fd35bc63
lnwire: add Record() method to lnwire.Sig
We'll use this later on to re-use the normal primitive record to create
a series of new TLV types for the new co-op close protocol.
2024-02-05 16:30:16 -08:00
Yong
63e698ec49
Merge pull request #8432 from yyforyongyu/fix-timestamp-precision
invoice+payment: fix timestamp precision for queries
2024-02-05 18:28:39 +08:00
Oliver Gugger
4584f7e39c
Merge pull request #8457 from mohamedawnallah/lnddir-option-overwrite-docs
docs: mention that `--lnddir` option overwrites all other directory options [skip ci]
2024-02-05 03:36:05 -06:00
Mohamed Awnallah
043834c698
config.go: mention that --lnddir option overwrites all other directory options [skip ci] 2024-02-05 11:30:09 +02:00
Oliver Gugger
e9bc9ad510
Merge pull request #8456 from Roasbeef/record-zero-fn
tlv: add new Zero method on RecordT
2024-02-05 02:48:38 -06:00
yyforyongyu
4da9582862
docs: add release notes for precision fix 2024-02-05 15:26:54 +08:00
yyforyongyu
605211823d
multi: fix timestamp filters for payment query
This commit fixes the timestamp precision to always compare the dates
using unix seconds for payments.
2024-02-05 15:26:49 +08:00
yyforyongyu
18333e8c7d
multi: fix timestamp filters for invoice query
This commit fixes the timestamp precision to always compare the dates
using unix seconds for invoices.
2024-02-05 15:26:43 +08:00
yyforyongyu
221e7ff898
itest: update testListPayments to precisely test timestamp filters 2024-02-05 15:23:57 +08:00
Yong
d41b86bb7e
Merge pull request #7852 from ziggie1984/pathfind_sizeestimate
Path Finding Size Estimation including Blinded Path Data
2024-02-05 15:21:51 +08:00
ziggie
da5055c210
docs: add release-notes. 2024-02-03 12:16:07 +00:00
ziggie
4732c09a26
multi: Fix final hop payload size for AMP payments. 2024-02-03 12:16:06 +00:00
ziggie
ff30ff40bf
multi: Fix final hop payload size for blinded rt.
The final hop size is calculated differently therefore we extract
the logic in its own function and also account for the case where
the final hop might be a blinded hop.
2024-02-03 12:11:01 +00:00
ziggie
c1b91fff14
multi: use new AdditionalEdge interface.
In the previous commit the AdditionalEdge interface was introduced
with both of its implementations `BlindedEdge` and `PrivateEdge`.
In both cases where we append a route either by a blinded route
section or private route hints we now use these new types. In
addition the `PayloadSizeFunc` type is introduced in the
`unifiedEdge` struct. This is necessary to have the payload size
function at hand when searching for a route hence not overshooting
the max sphinx package size of 1300 bytes.
2024-02-03 12:10:46 +00:00
Yong
54c47a3feb
Merge pull request #8449 from ProofOfKeags/refactor/lnwallet/delete-LightningChannel-status
lnwallet: simplify status row
2024-02-03 13:48:31 +08:00
Olaoluwa Osuntokun
78e0e5ac5d
tlv: add new Zero method on RecordT
In this commit, we add a new `Zero` method for the `RecordT` type. This
method allows a caller to create the zero record for a type without
needing to reference the actual TLV type.

With this we go from this:
```go
sig1 := tlv.ZeroRecordT[tlv.TlvType1, Sig]()
```

To this:
```
sig1 := c.CloserNoClosee.Zero()
```
2024-02-02 17:31:06 -08:00
Olaoluwa Osuntokun
47fced69da
Merge pull request #8440 from saubyk/codeowners
Add CODEOWNERS file
2024-02-02 17:25:30 -08:00
Keagan McClelland
3a02f2ba65 lnwallet: use ResetState instead of tweaking private rows 2024-02-02 11:46:32 -08:00
Keagan McClelland
606f8e79d1 lnwallet: rewrite channelState to bool for clarity
Over the last few commits we have systematically eliminated all but
two states. This allows us to replace it with a boolean to encode
the two remaining states. We would like to be able to eliminate this
field entirely, but doing so requires being able to prove that the
concurrent request block is necessary. This is more difficult and
will be left to future commits.
2024-02-02 11:46:32 -08:00
Keagan McClelland
17e67348a8 lnwallet: remove unused channelPending channelState
lnwallet: remove unused channelPendingPayment channelState

Since this state is never set nor read, we remove it completely.

lnwallet: remove redundant channelDispute channelState

In this case, even though we do set this value, it is never read.
Further, the times we read the field at all from LightningChannel
we want the situation of force-closure to block any other
concurrent closure attempts, so we change the sites where we set
channelDispute to channelClosed.

lnwallet: remove redundant channelClosing channelStatus

This value is never used to impact control flow so we need not set
it. We also need not have it.
2024-02-02 11:46:20 -08:00
Keagan McClelland
4e6b1cda49 lnwallet: change channelDispute to channelClosed so errors are handled 2024-02-02 11:40:22 -08:00
Oliver Gugger
ca5f23a647
Merge pull request #7372 from bhandras/listsweeps-range
walletrpc: add `startheight` parameter to the `ListSweeps` RPC
2024-02-02 02:03:16 -06:00
saubyk
fd212ed8c2
.github: add CODEOWNERS file 2024-02-01 12:16:40 -08:00
Andras Banki-Horvath
c4472254ef
docs: update release notes for 0.18.0 2024-02-01 21:02:25 +01:00
Andras Banki-Horvath
187e61da23
itests: add itest for ListSweeps's start_height 2024-02-01 21:02:25 +01:00
Andras Banki-Horvath
7725a57055
walletkit: add startheight parameter to ListSweeps
By default ListSweeps will list all sweeps known to the wallet. Over
time this may become expensive to call and callers may not be interested
in the full history. This commit adds a `startheight` parameter to the
`ListSweeps` RPC call. This parameter can be used to fetch sweeps only
from a specified start block height or only unconfirmed ones if it is
set to -1.
2024-02-01 21:02:24 +01:00
ziggie
9d3c0d9e3a
routing: add new interface AdditionalEdge.
A new interface AdditionalEdge is introduced which allows us to
enhance the CachedEdgePolicy with additional information. We
currently only need a PayloadSize function which is then used to
determine the exact payload size when building a route to adhere
to the sphinx package size limit (BOLT04).
2024-02-01 17:37:43 +00:00
Yong
5fe99f06ac
Merge pull request #8446 from yyforyongyu/validate-deprecation
lnd: add warning logs if deprecated config options are used
2024-02-01 23:32:35 +08:00
yyforyongyu
1057eb729d
multi: add unsafedisconnect as a dev config
This commit adds a new dev config `unsafedisconnect` as we sometimes
want to disconnect nodes in our itests.
2024-02-01 21:21:18 +08:00
yyforyongyu
9adec89fa8
lncfg: hide deprecated routing.assumechanvalid and neutrino.feeurl 2024-02-01 21:21:16 +08:00
yyforyongyu
78d552de22
config+rpcserver: hide deprecated option unsafe-disconnect
Also fix a case where this deprecated flag is used. We will always
bypass the active channels check when `DisconnectPeer` because
`!r.cfg.UnsafeDisconnect` is always false.
2024-02-01 21:20:11 +08:00
yyforyongyu
157c84cc4d
multi: log warnings if deprecated config options are used
This commit adds warning logs if the user uses deprecated config
options, paving the way for future removal.
2024-02-01 21:20:11 +08:00
Olaoluwa Osuntokun
7d74165296
Merge pull request #8442 from ProofOfKeags/bugfix/shutdown-msg
peer: fix issue where we echo remote Shutdown
2024-01-31 12:05:30 -08:00
Olaoluwa Osuntokun
cf4f468ab5
Merge pull request #8437 from ellemouton/v0-17-3-tls-fix
tls_manager: let REST proxy skip tls cert verification
2024-01-30 11:22:31 -08:00
Keagan McClelland
317aaf9940 peer: fix issue where we echo remote Shutdown 2024-01-30 12:15:59 -05:00
Yong
c89005c3a1
Merge pull request #8431 from ziggie1984/unhandled-witness-type-taproot
walletrpc: Add Taproot witness types to rpc.
2024-01-30 11:40:07 +08:00
Yong
dd7b186622
Merge pull request #8426 from breez/expose-closing-tx
Expose closing tx in waiting_close_channels
2024-01-30 09:13:17 +08:00
Elle Mouton
404a50ae25
tls_manager: let REST proxy skip tls cert verification 2024-01-29 17:56:50 +02:00
ziggie
13e20e99e4
docs: add release-notes. 2024-01-29 15:10:15 +00:00
ziggie
339c5fe1f0
makefile: add rpc tags to the unit tests. 2024-01-29 15:09:22 +00:00
ziggie
4f77758419
walletrpc: Add Taproot witness types to rpc. 2024-01-29 15:09:22 +00:00
Jesse de Wit
172e8366d4
docs: add release note for 8426 2024-01-29 14:16:51 +01:00
Jesse de Wit
ef3aa84c10
lncli: add include_raw_tx flag to pendingchannels 2024-01-29 14:16:51 +01:00
Jesse de Wit
b6616bc040
itest: assert closing tx is set in waiting_close_channels 2024-01-29 14:16:51 +01:00
Jesse de Wit
e794bd37a4
lnrpc: include raw closing tx in waiting_close_channels 2024-01-29 14:16:50 +01:00
Yong
b76d3e64d3
Merge pull request #8428 from ziggie1984/prune-node-deadlock-blocksync
Fix Pruned Node Loss Sync Issue.
2024-01-29 20:42:02 +08:00