Commit Graph

986 Commits

Author SHA1 Message Date
Mohamed Awnallah
5c3015b223
rpcserver: validate DeleteAllPayments options 2024-04-24 18:48:57 +02:00
ziggie
b954ee4c72
rpcserver: allow unconf. inputs for psbt shim.
Allow unconfirmed inputs to be used when funding a channel via
the psbt channel opening flow. We do now check for unstable utxos.
2024-04-24 13:58:20 +01:00
Olaoluwa Osuntokun
7af195768a
Merge pull request #8667 from lightningnetwork/elle-new-sweeper
Merge new sweeper branch to master
2024-04-22 11:20:49 -07:00
Oliver Gugger
73fd389e9a
Merge pull request #8627 from feelancer21/inbound-fees-reject
lnrpc: rejects positive inbound fees by default
2024-04-22 01:56:02 -06:00
feelancer21
a2319e4313 lnrpc: rejects positive inbound fees by default
Positive inbound are now rejected by default. The user can enable positive
inbound fees with the option 'accept-positive-inbound-fees'.
2024-04-20 00:11:36 +02:00
yyforyongyu
61e9c11881
rpcserver: skip calculating fee rate for PSBT funding 2024-04-19 21:33:22 +08:00
yyforyongyu
530eed92a0
multi: rename FeePreference to FeeEstimateInfo
Results from running,
```
gofmt -d -w -r 'FeePreference -> FeeEstimateInfo' .
```
2024-04-19 21:33:21 +08:00
yyforyongyu
6ff6c86155
multi: merge DetermineFeePerKw and Estimate
This commit moves `DetermineFeePerKw` into the `Estimate` method on
`FeePreference`. A few callsites previously calling `DetermineFeePerKw`
without the max fee rate is now also temporarily fixed by forcing them
to use `Estimate` with the default sweeper max fee rate.
2024-04-19 21:33:21 +08:00
Oliver Gugger
648fb22f63
multi: wrap all errors 2024-04-11 15:04:03 +02:00
Oliver Gugger
b1175514f9
Merge pull request #8515 from mohamedawnallah/add-coin-selection-strategy-on-chain-rpc
coin select: add coin selection strategy option to all on-chain RPCs
2024-04-02 11:20:08 +00:00
ziggie
eba4911599
lnd: fix sweepall argument call.
maxFeeRate and feePerKw were switched in CraftSweepAllTx.
2024-04-01 20:00:54 +01:00
Mohamed Awnallah
1a2d50d385
multi: add coin selection strategy option to all on-chain rpcs
In this commit, we add the coin selection strategy option to the following
on-chain RPCs `fundpsbt`, `batchopenchannel`, `estimatefee`, `sendcoins`,
`sendmany`, and `sendoutputs`.
2024-04-01 19:08:22 +02:00
Joost Jager
763787e08c routing+lnrpc: add inbound fee policy update 2024-03-31 16:49:19 +02:00
Joost Jager
3e6adbf1c0 lnwire+channeldb: parse inbound fees
In this commit, the tlv extension of a channel update message is parsed.
If an inbound fee schedule is encountered, it is reported in the
graph rpc calls.
2024-03-31 16:33:26 +02:00
Keagan McClelland
db39a905cb multi: make NewChanIDFromOutpoint accept value instead of pointer 2024-03-08 15:47:55 -08:00
Andras Banki-Horvath
7a45bbbeab
lnd: call into the correct InvoiceStore from RPC calls 2024-03-01 10:08:10 +01:00
ffranr
cd566eb097
multi: fix fmt.Errorf error wrapping
Refactor fmt.Errorf usage to correctly wrap errors instead of using
non-wrapping format verbs.
2024-02-27 11:13:40 +00: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
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
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
Jesse de Wit
e794bd37a4
lnrpc: include raw closing tx in waiting_close_channels 2024-01-29 14:16:50 +01:00
Keagan McClelland
804dabb4ea lnd: make closechannel send an instant empty update when no_wait set
We do things this way to keep behavior consistent across REST, gRPC
and CLI consistent. This was done to not alter the way we handle
Recv calls from the streams.
2024-01-23 12:25:01 -08:00
Oliver Gugger
8a2c3a3d85
lnrpc+rpcserver: add new GetDebugInfo RPC method 2024-01-09 12:32:37 +01:00
bitcoin-lightning
b72fc9529e docs: fix typos 2023-12-21 15:21:35 +00:00
Elle
4fa483f1bc
Merge pull request #7702 from ellemouton/towerClientMux
wtclient: Tower Client Multiplexer
2023-12-05 12:27:05 +02:00
Marcos
90b5037d73
lnrpc: add MinConfs to WalletBalanceRequest 2023-12-01 18:22:35 +01:00
Elle Mouton
fcfdf699e3
multi: move BackupState and RegisterChannel to Manager
This commit moves over the last two methods, `RegisterChannel` and
`BackupState` from the `Client` to the `Manager` interface. With this
change, we no longer need to pass around the individual clients around
and now only need to pass the manager around.

To do this change, all the goroutines that handle channel closes,
closable sessions needed to be moved to the Manager and so a large part
of this commit is just moving this code from the TowerClient to the
Manager.
2023-11-28 10:59:40 +02:00
Elle Mouton
a44bf381c4
multi: move AddTower to Tower Client Manager
In this commit we move the AddTower method from the Client interface to
the TowerClientManager interface. The wtclientrpc is updated to call the
`AddTower` method of the Manager instead of calling the `AddTower`
method of each individual client. The TowerClient now is also only
concerned with adding a new tower (or new tower address) to its
in-memory state; the tower Manager will handle adding the tower to the
DB.
2023-11-28 09:54:02 +02:00
yyforyongyu
816a70e08c
multi: add new config usestatusinitiated for the new payment status
This commit adds a new config value to signal that the user understands
the new payment status `StatusInitiated`.
2023-11-15 20:18:17 +08:00
Elle Mouton
0e82293e45
multi: address linter issues 2023-11-08 14:50:35 +02:00
Elle Mouton
84cdcd6847
multi: move DB schemas to channeldb/models
This commit moves the ChannelEdgePolicy, ChannelEdgeInfo,
ChanelAuthProof and CachedEdgePolicy structs to the `channeldb/models`
package.
2023-11-08 14:50:35 +02:00
Elle Mouton
6c76d31e89
multi: let FetchLightningNode take an optional tx
In preparation for the next commit which will remove the
`*LightningNode` from the `ChannelEdgePolicy` struct,
`FetchLightningNode` is modified to take in an optional transaction so
that it can be utilised in places where a transaction exists.
2023-11-08 14:50:34 +02:00
Elle Mouton
fa7c1e250b
multi: let ForEachChannel be a method on ChannelGraph
Having a `ForEachChannel` method on the `LightningNode` struct itself
results in a `kvdb.Backend` object needing to be stored within the
LightningNode struct. In this commit, this method is replaced with a
`ForEachNodeChannel` method on the `ChannelGraph` struct will perform
the same function without needing the db pointer to be stored within the
LightningNode. This change, the LightningNode struct more closely
represents the schema on disk.

The existing `ForEachNodeChannel` method on `ChannelGraph` is renamed to
`ForEachNodeDirectedChannel`. It performs a slightly different function
since it's call-back operates on Cached policies.
2023-11-08 10:51:50 +02:00
yyforyongyu
0532b82dd5
multi: add new method FeePerVByte to avoid manual conversion 2023-10-13 17:00:53 +08:00
András Bánki-Horváth
ad5cd9c8bb
multi: extend InvoiceDB methods with a context argument (#8066)
* multi: extend InvoiceDB methods with a context argument

This commit adds a context to InvoiceDB's methods. Along this refactor
we also extend InvoiceRegistry methods with contexts where it makes
sense. This change is essential to be able to provide kvdb and sqldb
implementations for InvoiceDB.

* channeldb: restrict invoice tests to only use an InvoiceDB instance

* docs: update release notes for 0.18.0
2023-10-11 13:42:59 +02:00
yyforyongyu
25d82fd62b rpcserver+sweep: fix linter re unused params 2023-10-06 16:34:47 -07:00
yyforyongyu
24fa35ec80 multi: make sure CPFP won't exceed max allowed fee rate
This commit updates the `fee()` method in `weightEstimator` to make sure
when doing CPFP we are not exceeding the max allowed fee rate. In order
to use the max fee rate, we need to modify several methods to pass the
configured value to the estimator.
2023-10-06 16:34:47 -07:00
Elle Mouton
031dbd7760 multi: remove ChainRegistry 2023-10-06 16:34:47 -07:00
Elle Mouton
3912d5a0c6 multi: remove Litecoin config options
This commit removes the `Litecoin`, `LtcMode` and `LitecoindMode`
members from the main LND `Config` struct. Since only the bitcoin
blockchain is now supported, this commit also deprecates the
`cfg.Bitcoin.Active` config option.
2023-10-06 16:34:47 -07:00
Olaoluwa Osuntokun
bb7a257359
Merge pull request #8037 from yyforyongyu/fix-weight-calc
lnwallet+rpcserver: fix weight calculation for taproot channels
2023-09-28 11:21:29 -05:00
yyforyongyu
522518922f
lnwallet+rpcserver: fix weight calculation for taproot channels 2023-09-28 19:42:13 +08:00
Oliver Gugger
d94ae3f509
lnrpc+rpcserver: add musig2 to ChanPointShim 2023-09-26 21:45:17 +02:00
Olaoluwa Osuntokun
384b1b1c12
feature: use +100 staging bit for taproot channels
In this commit, we carry out a new notion introduced during a recent
spec meeting to use a feature bit plus 100 before the feature has been
finalized in the spec.

We split into the Final and Staging bits.
2023-08-22 16:34:28 -07:00
Olaoluwa Osuntokun
4aa9bba4ef
rpc: update open channel parsing to detect taproot chans 2023-08-22 16:32:31 -07:00
Olaoluwa Osuntokun
95d627af4e
lnwallet/chanfunding: update assemblers to support musig2
In this commit, we update the set of intents and assemblers to recognize
musig2. For this change, we use a new bool, `musig2`, then use that to
determine if we need to use the new taproot funding scripts or not.
2023-08-22 16:30:42 -07:00
Slyghtning
ab117a0ed4
typos: fix updatechanpolicy typos 2023-08-11 17:04:36 +02:00
Oliver Gugger
d930dcec40
Merge pull request #7819 from ziggie1984/abandonchannel-rebroadcaster
Cancel the Rebroadcasting of a Transaction when Abandoning a Channel
2023-08-10 10:43:24 +02:00
Elle Mouton
b9560b067a
refactor: move State server REST registration
This commit moves the registration of the State server with a REST proxy
into the `RegisterWithRestProxy` method in order to keep all the REST
registrations in one place.
2023-08-08 11:43:25 +02:00