Skip to content

Commit cfd15ee

Browse files
committed
Drop PendingHTLCsForwardable event
1 parent 6ce6c6d commit cfd15ee

23 files changed

+498
-837
lines changed

fuzz/src/chanmon_consistency.rs

Lines changed: 5 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ use bitcoin::secp256k1::{self, Message, PublicKey, Scalar, Secp256k1, SecretKey}
8585
use lightning::util::dyn_signer::DynSigner;
8686

8787
use std::cell::RefCell;
88-
use std::cmp::{self, Ordering};
88+
use std::cmp;
8989
use std::mem;
9090
use std::sync::atomic;
9191
use std::sync::{Arc, Mutex};
@@ -1304,28 +1304,6 @@ pub fn do_test<Out: Output>(data: &[u8], underlying_out: Out, anchors: bool) {
13041304
// deduplicate the calls here.
13051305
let mut claim_set = new_hash_map();
13061306
let mut events = nodes[$node].get_and_clear_pending_events();
1307-
// Sort events so that PendingHTLCsForwardable get processed last. This avoids a
1308-
// case where we first process a PendingHTLCsForwardable, then claim/fail on a
1309-
// PaymentClaimable, claiming/failing two HTLCs, but leaving a just-generated
1310-
// PaymentClaimable event for the second HTLC in our pending_events (and breaking
1311-
// our claim_set deduplication).
1312-
events.sort_by(|a, b| {
1313-
if let events::Event::PaymentClaimable { .. } = a {
1314-
if let events::Event::PendingHTLCsForwardable { .. } = b {
1315-
Ordering::Less
1316-
} else {
1317-
Ordering::Equal
1318-
}
1319-
} else if let events::Event::PendingHTLCsForwardable { .. } = a {
1320-
if let events::Event::PaymentClaimable { .. } = b {
1321-
Ordering::Greater
1322-
} else {
1323-
Ordering::Equal
1324-
}
1325-
} else {
1326-
Ordering::Equal
1327-
}
1328-
});
13291307
let had_events = !events.is_empty();
13301308
for event in events.drain(..) {
13311309
match event {
@@ -1352,9 +1330,6 @@ pub fn do_test<Out: Output>(data: &[u8], underlying_out: Out, anchors: bool) {
13521330
},
13531331
events::Event::PaymentForwarded { .. } if $node == 1 => {},
13541332
events::Event::ChannelReady { .. } => {},
1355-
events::Event::PendingHTLCsForwardable { .. } => {
1356-
nodes[$node].process_pending_htlc_forwards();
1357-
},
13581333
events::Event::HTLCHandlingFailed { .. } => {},
13591334
_ => {
13601335
if out.may_fail.load(atomic::Ordering::Acquire) {
@@ -1365,6 +1340,9 @@ pub fn do_test<Out: Output>(data: &[u8], underlying_out: Out, anchors: bool) {
13651340
},
13661341
}
13671342
}
1343+
while nodes[$node].needs_pending_htlc_processing() {
1344+
nodes[$node].process_pending_htlc_forwards();
1345+
}
13681346
had_events
13691347
}};
13701348
}
@@ -1806,8 +1784,7 @@ pub fn do_test<Out: Output>(data: &[u8], underlying_out: Out, anchors: bool) {
18061784
last_pass_no_updates = false;
18071785
continue;
18081786
}
1809-
// ...making sure any pending PendingHTLCsForwardable events are handled and
1810-
// payments claimed.
1787+
// ...making sure any payments are claimed.
18111788
if process_events!(0, false) {
18121789
last_pass_no_updates = false;
18131790
continue;

fuzz/src/full_stack.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -635,7 +635,6 @@ pub fn do_test(mut data: &[u8], logger: &Arc<dyn Logger>) {
635635
let mut loss_detector =
636636
MoneyLossDetector::new(&peers, channelmanager.clone(), monitor.clone(), peer_manager);
637637

638-
let mut should_forward = false;
639638
let mut payments_received: Vec<PaymentHash> = Vec::new();
640639
let mut intercepted_htlcs: Vec<InterceptId> = Vec::new();
641640
let mut payments_sent: u16 = 0;
@@ -785,10 +784,7 @@ pub fn do_test(mut data: &[u8], logger: &Arc<dyn Logger>) {
785784
}
786785
},
787786
7 => {
788-
if should_forward {
789-
channelmanager.process_pending_htlc_forwards();
790-
should_forward = false;
791-
}
787+
channelmanager.process_pending_htlc_forwards();
792788
},
793789
8 => {
794790
for payment in payments_received.drain(..) {
@@ -1004,9 +1000,6 @@ pub fn do_test(mut data: &[u8], logger: &Arc<dyn Logger>) {
10041000
//TODO: enhance by fetching random amounts from fuzz input?
10051001
payments_received.push(payment_hash);
10061002
},
1007-
Event::PendingHTLCsForwardable { .. } => {
1008-
should_forward = true;
1009-
},
10101003
Event::HTLCIntercepted { intercept_id, .. } => {
10111004
if !intercepted_htlcs.contains(&intercept_id) {
10121005
intercepted_htlcs.push(intercept_id);

lightning-dns-resolver/src/lib.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -179,10 +179,7 @@ mod test {
179179
use lightning::types::payment::PaymentHash;
180180
use lightning::util::logger::Logger;
181181

182-
use lightning::{
183-
commitment_signed_dance, expect_payment_claimed, expect_pending_htlcs_forwardable,
184-
get_htlc_update_msgs,
185-
};
182+
use lightning::{commitment_signed_dance, expect_payment_claimed, get_htlc_update_msgs};
186183
use lightning_types::string::UntrustedString;
187184

188185
use std::ops::Deref;
@@ -413,7 +410,7 @@ mod test {
413410
let updates = get_htlc_update_msgs!(nodes[0], payee_id);
414411
nodes[1].node.handle_update_add_htlc(payer_id, &updates.update_add_htlcs[0]);
415412
commitment_signed_dance!(nodes[1], nodes[0], updates.commitment_signed, false);
416-
expect_pending_htlcs_forwardable!(nodes[1]);
413+
expect_and_process_pending_htlcs(&nodes[1], false);
417414

418415
let claimable_events = nodes[1].node.get_and_clear_pending_events();
419416
assert_eq!(claimable_events.len(), 1);

lightning/src/events/mod.rs

Lines changed: 1 addition & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@ use bitcoin::script::ScriptBuf;
5050
use bitcoin::secp256k1::PublicKey;
5151
use bitcoin::{OutPoint, Transaction};
5252
use core::ops::Deref;
53-
use core::time::Duration;
5453

5554
#[allow(unused_imports)]
5655
use crate::prelude::*;
@@ -1196,21 +1195,6 @@ pub enum Event {
11961195
/// with channels in the public network graph.
11971196
short_channel_id: Option<u64>,
11981197
},
1199-
/// Used to indicate that [`ChannelManager::process_pending_htlc_forwards`] should be called at
1200-
/// a time in the future.
1201-
///
1202-
/// # Failure Behavior and Persistence
1203-
/// This event will eventually be replayed after failures-to-handle (i.e., the event handler
1204-
/// returning `Err(ReplayEvent ())`) and will be regenerated after restarts.
1205-
///
1206-
/// [`ChannelManager::process_pending_htlc_forwards`]: crate::ln::channelmanager::ChannelManager::process_pending_htlc_forwards
1207-
PendingHTLCsForwardable {
1208-
/// The minimum amount of time that should be waited prior to calling
1209-
/// process_pending_htlc_forwards. To increase the effort required to correlate payments,
1210-
/// you should wait a random amount of time in roughly the range (now + time_forwardable,
1211-
/// now + 5*time_forwardable).
1212-
time_forwardable: Duration,
1213-
},
12141198
/// Used to indicate that we've intercepted an HTLC forward. This event will only be generated if
12151199
/// you've encoded an intercept scid in the receiver's invoice route hints using
12161200
/// [`ChannelManager::get_intercept_scid`] and have set [`UserConfig::accept_intercept_htlcs`].
@@ -1815,11 +1799,7 @@ impl Writeable for Event {
18151799
(13, failure, required),
18161800
});
18171801
},
1818-
&Event::PendingHTLCsForwardable { time_forwardable: _ } => {
1819-
4u8.write(writer)?;
1820-
// Note that we now ignore these on the read end as we'll re-generate them in
1821-
// ChannelManager, we write them here only for backwards compatibility.
1822-
},
1802+
// 4u8 used to be `PendingHTLCsForwardable`
18231803
&Event::SpendableOutputs { ref outputs, channel_id } => {
18241804
5u8.write(writer)?;
18251805
write_tlv_fields!(writer, {

lightning/src/ln/async_signer_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -956,7 +956,7 @@ fn do_test_async_commitment_signature_ordering(monitor_update_failure: bool) {
956956
assert!(nodes[0].node.get_and_clear_pending_msg_events().is_empty());
957957
check_added_monitors!(nodes[0], 1);
958958

959-
expect_pending_htlcs_forwardable!(nodes[1]);
959+
expect_and_process_pending_htlcs(&nodes[1], false);
960960

961961
let events_5 = nodes[1].node.get_and_clear_pending_events();
962962
check_payment_claimable(

lightning/src/ln/blinded_payment_tests.rs

Lines changed: 21 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -439,7 +439,7 @@ fn do_forward_checks_failure(check: ForwardCheckFail, intro_fails: bool) {
439439
check_added_monitors!(nodes[1], 0);
440440
do_commitment_signed_dance(&nodes[1], &nodes[0], &updates_0_1.commitment_signed, true, true);
441441

442-
expect_pending_htlcs_forwardable!(nodes[1]);
442+
expect_and_process_pending_htlcs(&nodes[1], false);
443443
check_added_monitors!(nodes[1], 1);
444444

445445
if intro_fails {
@@ -477,7 +477,7 @@ fn do_forward_checks_failure(check: ForwardCheckFail, intro_fails: bool) {
477477
check_added_monitors!(nodes[2], 0);
478478
do_commitment_signed_dance(&nodes[2], &nodes[1], &updates_1_2.commitment_signed, true, true);
479479

480-
expect_pending_htlcs_forwardable!(nodes[2]);
480+
expect_and_process_pending_htlcs(&nodes[2], false);
481481
let failed_destination = match check {
482482
ForwardCheckFail::InboundOnionCheck|ForwardCheckFail::ForwardPayloadEncodedAsReceive => HTLCHandlingFailureType::InvalidOnion,
483483
ForwardCheckFail::OutboundChannelCheck =>
@@ -534,7 +534,7 @@ fn failed_backwards_to_intro_node() {
534534
nodes[1].node.handle_update_add_htlc(nodes[0].node.get_our_node_id(), &payment_event.msgs[0]);
535535
check_added_monitors!(nodes[1], 0);
536536
do_commitment_signed_dance(&nodes[1], &nodes[0], &payment_event.commitment_msg, false, false);
537-
expect_pending_htlcs_forwardable!(nodes[1]);
537+
expect_and_process_pending_htlcs(&nodes[1], false);
538538
check_added_monitors!(&nodes[1], 1);
539539

540540
let mut events = nodes[1].node.get_and_clear_pending_msg_events();
@@ -548,7 +548,7 @@ fn failed_backwards_to_intro_node() {
548548
check_added_monitors!(nodes[2], 0);
549549
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event.commitment_msg, true, true);
550550

551-
expect_pending_htlcs_forwardable!(nodes[2]);
551+
expect_and_process_pending_htlcs(&nodes[2], false);
552552
expect_htlc_handling_failed_destinations!(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::InvalidOnion]);
553553
check_added_monitors(&nodes[2], 1);
554554

@@ -626,7 +626,7 @@ fn do_forward_fail_in_process_pending_htlc_fwds(check: ProcessPendingHTLCsCheck,
626626
// Disconnect the next-hop peer so when we go to forward in process_pending_htlc_forwards, the
627627
// intro node will error backwards.
628628
$curr_node.node.peer_disconnected($next_node.node.get_our_node_id());
629-
expect_pending_htlcs_forwardable!($curr_node);
629+
expect_and_process_pending_htlcs(&$curr_node, false);
630630
expect_htlc_handling_failed_destinations!($curr_node.node.get_and_clear_pending_events(),
631631
vec![HTLCHandlingFailureType::Forward { node_id: Some($next_node.node.get_our_node_id()), channel_id: $failed_chan_id }]);
632632
},
@@ -636,10 +636,6 @@ fn do_forward_fail_in_process_pending_htlc_fwds(check: ProcessPendingHTLCsCheck,
636636
$curr_node.node.force_close_broadcasting_latest_txn(&$failed_chan_id, &$next_node.node.get_our_node_id(), error_message.to_string()).unwrap();
637637
let events = $curr_node.node.get_and_clear_pending_events();
638638
match events[0] {
639-
crate::events::Event::PendingHTLCsForwardable { .. } => {},
640-
_ => panic!("Unexpected event {:?}", events),
641-
};
642-
match events[1] {
643639
crate::events::Event::ChannelClosed { .. } => {},
644640
_ => panic!("Unexpected event {:?}", events),
645641
}
@@ -649,7 +645,6 @@ fn do_forward_fail_in_process_pending_htlc_fwds(check: ProcessPendingHTLCsCheck,
649645
$curr_node.node.process_pending_htlc_forwards();
650646
expect_htlc_handling_failed_destinations!($curr_node.node.get_and_clear_pending_events(),
651647
vec![HTLCHandlingFailureType::InvalidForward { requested_forward_scid: $failed_scid }]);
652-
$curr_node.node.process_pending_htlc_forwards();
653648
},
654649
}
655650
}
@@ -662,7 +657,7 @@ fn do_forward_fail_in_process_pending_htlc_fwds(check: ProcessPendingHTLCsCheck,
662657
return
663658
}
664659

665-
expect_pending_htlcs_forwardable!(nodes[1]);
660+
expect_and_process_pending_htlcs(&nodes[1], false);
666661
check_added_monitors!(nodes[1], 1);
667662

668663
let mut updates_1_2 = get_htlc_update_msgs!(nodes[1], nodes[2].node.get_our_node_id());
@@ -729,7 +724,7 @@ fn do_blinded_intercept_payment(intercept_node_fails: bool) {
729724
};
730725
nodes[1].node.handle_update_add_htlc(nodes[0].node.get_our_node_id(), &payment_event.msgs[0]);
731726
commitment_signed_dance!(nodes[1], nodes[0], &payment_event.commitment_msg, false, true);
732-
expect_pending_htlcs_forwardable!(nodes[1]);
727+
expect_and_process_pending_htlcs(&nodes[1], false);
733728

734729
let events = nodes[1].node.get_and_clear_pending_events();
735730
assert_eq!(events.len(), 1);
@@ -747,15 +742,15 @@ fn do_blinded_intercept_payment(intercept_node_fails: bool) {
747742

748743
if intercept_node_fails {
749744
nodes[1].node.fail_intercepted_htlc(intercept_id).unwrap();
750-
expect_pending_htlcs_forwardable_and_htlc_handling_failed_ignore!(nodes[1], [HTLCHandlingFailureType::InvalidForward { requested_forward_scid: intercept_scid }]);
745+
expect_pending_htlcs_forwardable_conditions(nodes[1].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::InvalidForward { requested_forward_scid: intercept_scid }]);
751746
nodes[1].node.process_pending_htlc_forwards();
752747
check_added_monitors!(&nodes[1], 1);
753748
fail_blinded_htlc_backwards(payment_hash, 1, &[&nodes[0], &nodes[1]], false);
754749
return
755750
}
756751

757752
nodes[1].node.forward_intercepted_htlc(intercept_id, &channel_id, nodes[2].node.get_our_node_id(), expected_outbound_amount_msat).unwrap();
758-
expect_pending_htlcs_forwardable!(nodes[1]);
753+
expect_and_process_pending_htlcs(&nodes[1], false);
759754

760755
let payment_event = {
761756
{
@@ -769,7 +764,7 @@ fn do_blinded_intercept_payment(intercept_node_fails: bool) {
769764
};
770765
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), &payment_event.msgs[0]);
771766
commitment_signed_dance!(nodes[2], nodes[1], &payment_event.commitment_msg, false, true);
772-
expect_pending_htlcs_forwardable!(nodes[2]);
767+
expect_and_process_pending_htlcs(&nodes[2], false);
773768

774769
expect_payment_claimable!(&nodes[2], payment_hash, payment_secret, amt_msat, None, nodes[2].node.get_our_node_id());
775770
do_claim_payment_along_route(
@@ -958,7 +953,7 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
958953
nodes[1].node.handle_update_add_htlc(nodes[0].node.get_our_node_id(), &payment_event_0_1.msgs[0]);
959954
check_added_monitors!(nodes[1], 0);
960955
do_commitment_signed_dance(&nodes[1], &nodes[0], &payment_event_0_1.commitment_msg, false, false);
961-
expect_pending_htlcs_forwardable!(nodes[1]);
956+
expect_and_process_pending_htlcs(&nodes[1], false);
962957
check_added_monitors!(&nodes[1], 1);
963958

964959
let mut payment_event_1_2 = {
@@ -973,7 +968,7 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
973968
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), &payment_event_1_2.msgs[0]);
974969
check_added_monitors!(nodes[2], 0);
975970
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event_1_2.commitment_msg, true, true);
976-
expect_pending_htlcs_forwardable!(nodes[2]);
971+
expect_and_process_pending_htlcs(&nodes[2], false);
977972
check_payment_claimable(
978973
&nodes[2].node.get_and_clear_pending_events()[0], payment_hash, payment_secret, amt_msat,
979974
None, nodes[2].node.get_our_node_id()
@@ -1009,7 +1004,7 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
10091004
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), update_add);
10101005
check_added_monitors!(nodes[2], 0);
10111006
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event_1_2.commitment_msg, true, true);
1012-
expect_pending_htlcs_forwardable!(nodes[2]);
1007+
expect_and_process_pending_htlcs(&nodes[2], false);
10131008
expect_htlc_handling_failed_destinations!(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::InvalidOnion]);
10141009
check_added_monitors(&nodes[2], 1);
10151010
},
@@ -1019,7 +1014,7 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
10191014
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), update_add);
10201015
check_added_monitors!(nodes[2], 0);
10211016
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event_1_2.commitment_msg, true, true);
1022-
expect_pending_htlcs_forwardable!(nodes[2]);
1017+
expect_and_process_pending_htlcs(&nodes[2], false);
10231018
expect_htlc_handling_failed_destinations!(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::Receive { payment_hash }]);
10241019
check_added_monitors(&nodes[2], 1);
10251020
},
@@ -1035,7 +1030,7 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
10351030

10361031
nodes[2].node.handle_shutdown(nodes[1].node.get_our_node_id(), &node_1_shutdown);
10371032
commitment_signed_dance!(nodes[2], nodes[1], (), false, true, false, false);
1038-
expect_pending_htlcs_forwardable!(nodes[2]);
1033+
expect_and_process_pending_htlcs(&nodes[2], false);
10391034
expect_htlc_handling_failed_destinations!(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::Receive { payment_hash }]);
10401035
check_added_monitors(&nodes[2], 1);
10411036
},
@@ -1044,16 +1039,15 @@ fn do_multi_hop_receiver_fail(check: ReceiveCheckFail) {
10441039
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), &payment_event_1_2.msgs[0]);
10451040
check_added_monitors!(nodes[2], 0);
10461041
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event_1_2.commitment_msg, true, true);
1047-
expect_pending_htlcs_forwardable!(nodes[2]);
1048-
expect_pending_htlcs_forwardable_and_htlc_handling_failed_ignore!(nodes[2],
1049-
[HTLCHandlingFailureType::Receive { payment_hash }]);
1042+
expect_and_process_pending_htlcs(&nodes[2], true);
1043+
expect_pending_htlcs_forwardable_conditions(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::Receive { payment_hash }]);
10501044
check_added_monitors!(nodes[2], 1);
10511045
},
10521046
ReceiveCheckFail::PaymentConstraints => {
10531047
nodes[2].node.handle_update_add_htlc(nodes[1].node.get_our_node_id(), &payment_event_1_2.msgs[0]);
10541048
check_added_monitors!(nodes[2], 0);
10551049
do_commitment_signed_dance(&nodes[2], &nodes[1], &payment_event_1_2.commitment_msg, true, true);
1056-
expect_pending_htlcs_forwardable!(nodes[2]);
1050+
expect_and_process_pending_htlcs(&nodes[2], false);
10571051
expect_htlc_handling_failed_destinations!(nodes[2].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::Receive { payment_hash }]);
10581052
check_added_monitors(&nodes[2], 1);
10591053
}
@@ -1162,18 +1156,14 @@ fn blinded_path_retries() {
11621156
do_commitment_signed_dance(&nodes[0], &$intro_node, &updates.commitment_signed, false, false);
11631157

11641158
let mut events = nodes[0].node.get_and_clear_pending_events();
1165-
assert_eq!(events.len(), 2);
1159+
assert_eq!(events.len(), 1);
11661160
match events[0] {
11671161
Event::PaymentPathFailed { payment_hash: ev_payment_hash, payment_failed_permanently, .. } => {
11681162
assert_eq!(payment_hash, ev_payment_hash);
11691163
assert_eq!(payment_failed_permanently, false);
11701164
},
11711165
_ => panic!("Unexpected event"),
11721166
}
1173-
match events[1] {
1174-
Event::PendingHTLCsForwardable { .. } => {},
1175-
_ => panic!("Unexpected event"),
1176-
}
11771167
nodes[0].node.process_pending_htlc_forwards();
11781168
}
11791169
}
@@ -1262,7 +1252,7 @@ fn min_htlc() {
12621252
nodes[1].node.handle_update_add_htlc(nodes[0].node.get_our_node_id(), &payment_event_0_1.msgs[0]);
12631253
check_added_monitors!(nodes[1], 0);
12641254
do_commitment_signed_dance(&nodes[1], &nodes[0], &payment_event_0_1.commitment_msg, true, true);
1265-
expect_pending_htlcs_forwardable!(nodes[1]);
1255+
expect_and_process_pending_htlcs(&nodes[1], false);
12661256
expect_htlc_handling_failed_destinations!(
12671257
nodes[1].node.get_and_clear_pending_events(),
12681258
&[HTLCHandlingFailureType::Forward { node_id: Some(nodes[2].node.get_our_node_id()), channel_id: chan_1_2.2 }]
@@ -1455,7 +1445,7 @@ fn fails_receive_tlvs_authentication() {
14551445

14561446
nodes[1].node.handle_update_add_htlc(nodes[0].node.get_our_node_id(), &payment_event.msgs[0]);
14571447
do_commitment_signed_dance(&nodes[1], &nodes[0], &payment_event.commitment_msg, true, true);
1458-
expect_pending_htlcs_forwardable!(nodes[1]);
1448+
expect_and_process_pending_htlcs(&nodes[1], false);
14591449
nodes[1].node.process_pending_htlc_forwards();
14601450
check_added_monitors!(nodes[1], 1);
14611451
expect_htlc_handling_failed_destinations!(nodes[1].node.get_and_clear_pending_events(), &[HTLCHandlingFailureType::InvalidOnion]);

0 commit comments

Comments
 (0)