rgb-cln/contrib
Rusty Russell 96ff874bd1 pytest: fix race when we mine blocks after pay().
This seems to trigger now, especially on PostgresQL (maybe it's faster
to process blocks?).

e.g. test_closing_simple() hangs in close(), because the close is unilateral
because the HTLC timed out, so it's waiting for a block (other lines removed):

```
lightningd-1: 2022-01-12T00:33:46.258Z DEBUG   022d223620a359a47ff7f7ac447c85c46c923da53389221a0054c11c1e3ca31d59-channeld-chan#1: peer_out WIRE_COMMITMENT_SIGNED
lightningd-1: 2022-01-12T00:33:46.278Z DEBUG   lightningd: close_command: timeout = 172800
2022-01-12T01:03:36.9757201Z lightningd-2: 2022-01-12T00:33:46.384Z DEBUG   lightningd: Adding block 104: 73ffa19d27d048613b2731e1682b4efff0dc226807d8cc99d724523c2ea58204
2022-01-12T01:03:36.9759053Z lightningd-2: 2022-01-12T00:33:46.396Z DEBUG   lightningd: Adding block 105: 44fd06ed053a0d0594abcfefcfa69089351fc89080826799fb4b278a68fe5c20
2022-01-12T01:03:36.9760865Z lightningd-2: 2022-01-12T00:33:46.406Z DEBUG   lightningd: Adding block 106: 0fee2dcbd1376249832642079131275e195bba4fb49cc9968df3a899010bba0f
2022-01-12T01:03:36.9762632Z lightningd-2: 2022-01-12T00:33:46.418Z DEBUG   lightningd: Adding block 107: 7f24f2d7d3e83fe3256298bd661e57cdf92b058440738fd4d7e1c8ef4a4ca073
2022-01-12T01:03:36.9773411Z lightningd-2: 2022-01-12T00:33:46.429Z DEBUG   0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-channeld-chan#1: peer_in WIRE_REVOKE_AND_ACK
2022-01-12T01:03:36.9794707Z lightningd-2: 2022-01-12T00:33:46.437Z DEBUG   0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-channeld-chan#1: Commits outstanding after recv revoke_and_ack
2022-01-12T01:03:36.9788197Z lightningd-2: 2022-01-12T00:33:46.433Z DEBUG   lightningd: Adding block 108: 283b371fb5d1ef42980ea10ab9f5965a179af8e91ddf31c8176e79820e1ec54d
2022-01-12T01:03:36.9799347Z lightningd-2: 2022-01-12T00:33:46.439Z DEBUG   0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-channeld-chan#1: HTLC 0[REMOTE] => RCVD_REMOVE_REVOCATION
2022-01-12T01:03:36.9808057Z lightningd-2: 2022-01-12T00:33:46.447Z UNUSUAL 0266e4598d1d3c415f572a8488830b60f7e744ed9235eb0b1ba93283b315c03518-chan#1: Peer permanent failure in CHANNELD_NORMAL: Fulfilled HTLC 0 RCVD_REMOVE_REVOCATION cltv 109 hit deadline
```

This is because `pay` returns from l1 when it has the preimage, not
when the HTLC is fully resolved.  Add a helper for this, and call it
at the end of the pay test helper.  We might need this elsewhere
though!

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2022-01-20 15:24:06 +10:30
..
init systemd: After=network-online.target 2019-08-20 20:14:36 +02:00
keys chore: add 3 gpg pubkeys of maintainers to the repository 2021-07-19 13:22:33 +09:30
libhsmd_python ccan: remove autodata. 2021-09-21 18:04:43 +02:00
plugins JSON-RPC: getmanifest passes allow-deprecated-apis flag. 2020-08-11 08:43:18 +09:30
pylightning pylightning: Make it clear pyln-client should be used instead 2021-10-06 13:44:42 +02:00
pyln-client Update lightning.py 2022-01-08 14:15:29 +01:00
pyln-proto gci: Pin down a couple more dependencies 2021-09-28 18:34:43 +02:00
pyln-spec contrib: fix other pyln-spec package requirements too. 2021-11-17 10:50:54 +10:30
pyln-testing pytest: fix race when we mine blocks after pay(). 2022-01-20 15:24:06 +10:30
reprobuild repro: Add missing Dockerfiles 2020-09-16 06:27:12 +09:30
sanitizer_suppressions common/autodata: use instead of ccan/autodata 2021-09-21 18:04:43 +02:00
Dockerfile.builder build: add mkrd to docker install? 2020-04-19 08:07:47 +09:30
Dockerfile.builder.fedora build: add mkrd to docker install? 2020-04-19 08:07:47 +09:30
Dockerfile.tester gci: Add a tester Dockerfile 2021-01-29 10:29:09 +10:30
bootstrap-node.sh contrib: add executable flag for bootstrap-node.sh 2020-05-05 13:27:55 +09:30
lightning-cli.bash-completion Fix bash completion. 2020-05-15 15:25:33 +02:00
linuxarm32v7.Dockerfile Fix dockerfile for arm32/64 2021-12-08 12:46:58 +01:00
linuxarm64v8.Dockerfile Fix dockerfile for arm32/64 2021-12-08 12:46:58 +01:00
short_channel_id-to-txid.sh Add compability to current formalism to short_channel_id-to-txid.sh 2019-10-04 00:38:52 +00:00
startup_regtest.sh queryrates: make it dev-only 2021-07-20 13:28:38 -04:00