Commit Graph

575 Commits

Author SHA1 Message Date
Olaoluwa Osuntokun
16bce31e46
Merge pull request #5348 from yyforyongyu/fix-itest-channel-close
itest: fix wrong node queried for balance
2021-06-18 14:09:19 -07:00
Olaoluwa Osuntokun
a4d4d5f8dc
Merge pull request #5299 from C-Otto/insufficient-bandwidth-log
add detailed log message for "insufficient bandwidth" error
2021-06-18 14:07:15 -07:00
yyforyongyu
a60db53a5a
itest: fix wrong node queried for balance 2021-06-03 19:55:25 +08:00
Conner Fromknecht
d6f88cbe6f
lnrpc: allow payment addr override for AMP invoices
This permits an AMP invoice to be "pseudo-reusable", where the invoice
paramters can be used multiple times so long as a new payment address is
supplied. This prevents additional round trips between payer and payee
to obtain a new invoice, even though the payments/invoices won't be
logically associated via the RPC interface like they would when the full
reusable invoices are deployed.
2021-05-28 09:30:05 -07:00
Conner Fromknecht
a765ba1f3d
lntest/mpp_test: ensure ctx.alice and ctx.bob are shutdown
Not doing so prevents consecutive subtests from starting properly.
2021-05-28 09:30:05 -07:00
Carsten Otto
4b4d34fcce htlcswitch: change errors to warnings
for issues caused by bogus incoming HTLC data
2021-05-23 19:17:59 +01:00
Oliver Gugger
e39d00900c
Merge pull request #5260 from guggero/windows-itest
Travis: fix Windows itest
2021-05-14 12:57:51 +02:00
Oliver Gugger
e4873ac878
lntest: re-use P2P ports during SCB recovery
In some rare instances it can happen that the nodes don't find each
other again after one of them has been re-created and the other one has
been restarted in the SCB tests. By making sure the re-created has the
same P2P port again as before, we make sure they can connect to each
other again successfully for executing DLP.
2021-05-14 10:59:10 +02:00
Oliver Gugger
702dda6448
itest: reconnect nodes more quickly on SCB restore
Since there is a lot of connecting and disconnecting between nodes in
the channel backup tests, we try to speed up that process by lowering
the min backoff from 1 second to 50 milliseconds. We also make sure we
never wait more than 1 second if it does take multple attempts. This
should sum up and hopefully speed up our tests a bit.
2021-05-14 10:09:04 +02:00
Olaoluwa Osuntokun
7ab5906093
Merge pull request #5245 from bhandras/kvdb_module
kvdb: make kvdb a top level submodule to allow dependency in other projects
2021-05-13 15:59:20 -07:00
Olaoluwa Osuntokun
c0acdd8082
Merge pull request #5036 from halseth/breacharbiter-justice-splitting
[breacharbiter] Split justice tx in case of delayed confirmation.
2021-05-12 13:42:42 -07:00
Olaoluwa Osuntokun
86c5e483b2
Merge pull request #5206 from carlaKC/4987-heightexpirywatcher
invoices: add height based expiry watcher
2021-05-12 13:41:52 -07:00
Olaoluwa Osuntokun
dc73a23e81
Merge pull request #5253 from cfromknecht/amp-invoice
Support paying AMP invoices via SendPaymentV2
2021-05-12 13:38:42 -07:00
Johan T. Halseth
3aa5e650fb
lntest/mock: set input index on spend event 2021-05-12 12:32:28 +02:00
carla
8066ff7047
itest/test: assert expired hold invoice updated correctly 2021-05-11 08:45:32 +02:00
carla
b7d1ed0cbb
itest/test: test hold invoice cancel before force close 2021-05-11 08:45:31 +02:00
Conner Fromknecht
ef392dcd0c
lntest: add amp invoice test 2021-05-10 22:02:15 -07:00
Conner Fromknecht
4e93c1303c
lntest: isolate alice+bob in mppTestContext 2021-05-10 22:02:15 -07:00
Conner Fromknecht
2ecd1de713
config: expose distinct accept-amp flag
This mirrors the accept-keysend flag, but also permits users to
eventually toggle off keysend separately from AMP.
2021-05-10 22:02:15 -07:00
Conner Fromknecht
8c404ade18
routing: allow splitting for AMP or MPP 2021-05-10 22:02:14 -07:00
Conner Fromknecht
dba055de2d
lntest/amp_test: assert subscribe invoice in sendtoroute_amp 2021-05-10 22:02:14 -07:00
Olaoluwa Osuntokun
ba5aaec632
Merge pull request #5266 from wpaulino/import-dry-run
walletrpc: expose dry run support for ImportAccount
2021-05-10 17:19:09 -07:00
Oliver Gugger
6c37cae639
lntest+routing: update best height after graph pruning
It seems #5246 introduced a subtle bug that lead to the error "out of
order block: expecting height=1, got height=XXX" some times during
startup. Apparently it can happen that during pruning of the graph tip
some blocks can come in before we start our chain view and the new block
subscription. By querying the chain backend for the best height before
syncing with the graph we ensure that we never miss a block.
2021-05-10 16:46:28 +02:00
Oliver Gugger
8147b270d4
lntest: wait for chain sync in switch test 2021-05-10 16:46:28 +02:00
Andras Banki-Horvath
14c851c8fc
kvdb: move channeldb/kvdb to top level 2021-05-07 14:18:56 +02:00
yyforyongyu
270984b7d5
trivial: update log_error_whitelist 2021-05-07 13:20:54 +08:00
Wilmer Paulino
994405709a
lnwallet: expose dry run support for ImportAccount 2021-05-06 19:04:21 -07:00
Andras Banki-Horvath
dd14947154
lint: silence depreciation warnings 2021-05-04 17:33:14 +02:00
Andras Banki-Horvath
7caf26ce94
itest: add itest for failover after forcefull shutdown 2021-05-04 17:33:12 +02:00
Andras Banki-Horvath
5d8488871c
itest: basic failover itest when using leader election on etcd 2021-05-04 17:33:12 +02:00
Andras Banki-Horvath
5e215a7a66
lnrpc: add "waiting to start" state to state service
This commit adds a new "waiting to start" state which may be used to
query if we're still waiting to become the cluster leader. Once leader
we advance the state to "wallet not exist" or "wallet locked" given
wallet availablity.
2021-05-04 17:33:11 +02:00
Andras Banki-Horvath
e5f249ad51
mod: integrate latest btcwallet and bump protobuf and grpc 2021-05-04 17:33:09 +02:00
Olaoluwa Osuntokun
140dd944c0
Merge pull request #5257 from wpaulino/neutrino-update
lncfg: add config options for new neutrino options
2021-04-30 16:54:35 -07:00
Wilmer Paulino
f26cfac440
itest: use wait predicate for balance assertion in assertDLPExecuted
This assertion would at times fail if the wallet balance hadn't been
updated yet.
2021-04-29 13:56:20 -07:00
Wilmer Paulino
6bb7b00a80
lntest: decrease broadcast timeout for neutrino-backed integration tests
Since we don't have to worry about network latency within our
integration tests, we can shorten the broadcast timeout for neutrino
integration tests from 5s to 1s.
2021-04-29 13:56:19 -07:00
Oliver Gugger
13aed071bd
itest: add test for bi-directional WebSocket 2021-04-29 10:39:55 +02:00
Oliver Gugger
066472fd3e
itest: refactor WS tests into functions 2021-04-29 10:39:55 +02:00
Johan T. Halseth
13c00127da
itest: add SendPayment AMP itest 2021-04-27 09:47:24 +02:00
Johan T. Halseth
a2a61a104f
itest: make sendAndAssertSuccess take context 2021-04-27 09:47:23 +02:00
Johan T. Halseth
f07c9d002c
routing: use Identifier in place of PaymentHash
Since we want to support AMP payment using a different unique payment
identifier (AMP payments don't go to one specific hash), we change the
nomenclature to be Identifier instead of PaymentHash.
2021-04-27 09:47:23 +02:00
Olaoluwa Osuntokun
8af00ab0cf
Merge pull request #5205 from carlaKC/4987-refactorprep
invoices: add test to demonstrate hodl invoice bug and refactor
2021-04-26 15:48:56 -07:00
Olaoluwa Osuntokun
bfcaf02f04
Merge pull request #4905 from LN-Zap/feat/spend-unconfirmed-estimate
Support spend_unconfirmed in EstimateFee and FundPsbt
2021-04-26 15:48:11 -07:00
Olaoluwa Osuntokun
9ef00d98a7
Merge pull request #5230 from carlaKC/5059-interceptorchanupdate
multi: send channel update for failed interceptor packets
2021-04-26 15:45:43 -07:00
carla
d0d0d21573
itest/test: remove hold force close dependency
Our aggregate htlc test depends on our previous behavior
where recipients would allow channels with pending hold
invoice htlcs to force close. Now that we have an expiry
watcher to prevent these force closes, we can't rely on
this for tests because the recipient will cancel the htlcs
back before they expire.
2021-04-23 08:19:58 +02:00
carla
2e39edd6bd
itest/test: add test for expired hold invoices
This commit adds a test for a hold invoice which is accepted
off-chain, and held by the recipient until it expired and
the payer force-closes the channel. With this test we
demonstrate two bugs in our handling of hold invoice state
in the invoice registry when we expire on chain:
- Htlcs not updated: even when we've timed out, we don't
  update the htlc state accordingly.
- Invoice can be settled: the invoice can be settled even
  though it's expired on chain.
2021-04-23 08:19:51 +02:00
carla
16373d3879
itest/test: add test to reproduce settling timed out invoice
Reproduce the case where we allow settling of invoices that have
htlcs that have actually timed out on chain. This bug can rarely
occur if a hodl invoice goes to chain and is manually settled
after it has timed out. Funds are SAFU, but this could be a
headache because the invoice says it's settled when no funds
were claimed.
2021-04-23 08:19:50 +02:00
carla
fff6f83f23
itest/test: update remote force close timeout to use hodl inv
This commit updates our multi-hop force close test to use a hodl
invoice so that we can reproduce some bugs which will require
the preimage for the invoice that is timed out on chain.
2021-04-23 08:19:47 +02:00
Tom Kirkpatrick
2f80283ec2
rpc: minConfs and spendUnconfirmed for EstimateFee 2021-04-22 20:35:51 +02:00
Tom Kirkpatrick
03b55446b5
refactor: use camel case for minConfs 2021-04-22 20:35:00 +02:00
carla
5b7b6ab9b0
multi: send channel update for failed interceptor packets 2021-04-22 19:39:37 +02:00