You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let (route, payment_hash, _, payment_secret) = get_route_and_payment_hash!(nodes[1], nodes[0], 200_000); // + 177_000 msat of HTLC-success tx at 253 sats/kWU
9728
+
if let Err(_) = nodes[1].node.send_payment(&route, payment_hash, &Some(payment_secret)) { panic!("Unexpected event at dust HTLC {}", i); }
9729
+
}
9730
+
} else {
9731
+
for _ in 0..25 {
9732
+
route_payment(&nodes[0], &[&nodes[1]], 200_000); // + 167_000 msat of HTLC-timeout tx at 253 sats/kWU
9733
+
}
9734
+
}
9735
+
}
9736
+
9737
+
if at_forward {
9738
+
let (route, payment_hash, _, payment_secret) = get_route_and_payment_hash!(nodes[1], nodes[0], if on_holder_tx { 2_300_000 } else { 200_000 });
9739
+
let mut config = UserConfig::default();
9740
+
if on_holder_tx {
9741
+
unwrap_send_err!(nodes[1].node.send_payment(&route, payment_hash, &Some(payment_secret)), true, APIError::ChannelUnavailable { ref err }, assert_eq!(err, &format!("Cannot send value that would put holder dusted balance {} on holder commitment over limit {}", 6_900_000, config.channel_options.max_balance_dust_htlc_msat)));
9742
+
} else {
9743
+
unwrap_send_err!(nodes[1].node.send_payment(&route, payment_hash, &Some(payment_secret)), true, APIError::ChannelUnavailable { ref err }, assert_eq!(err, &format!("Cannot send value that would put holder dusted balance {} on counterparty commitment over limit {}", 5_200_000, config.channel_options.max_balance_dust_htlc_msat)));
9744
+
}
9745
+
} else {
9746
+
let (route, payment_hash, _, payment_secret) = get_route_and_payment_hash!(nodes[0], nodes[1 ], if on_holder_tx { 2_300_000 } else { 200_000 });
nodes[1].logger.assert_log("lightning::ln::channel".to_string(), format!("Cannot accept value that would put holder dusted balance {} on holder commitment over limit {}", 6_900_000, config.channel_options.max_balance_dust_htlc_msat), 1);
9755
+
} else {
9756
+
nodes[1].logger.assert_log("lightning::ln::channel".to_string(), format!("Cannot accept value that would put holder dusted balance {} on counterparty commitment over limit {}", 5_200_000, config.channel_options.max_balance_dust_htlc_msat), 1);
9757
+
}
9758
+
}
9759
+
9760
+
let _ = nodes[1].node.get_and_clear_pending_msg_events();
9761
+
let mut added_monitors = nodes[1].chain_monitor.added_monitors.lock().unwrap();
0 commit comments