@@ -5366,6 +5366,7 @@ where
5366
5366
}
5367
5367
if valid_mpp {
5368
5368
for htlc in sources.drain(..) {
5369
+ let prev_hop_chan_id = htlc.prev_hop.outpoint.to_channel_id();
5369
5370
if let Err((pk, err)) = self.claim_funds_from_hop(
5370
5371
htlc.prev_hop, payment_preimage,
5371
5372
|_, definitely_duplicate| {
@@ -5376,6 +5377,7 @@ where
5376
5377
if let msgs::ErrorAction::IgnoreError = err.err.action {
5377
5378
// We got a temporary failure updating monitor, but will claim the
5378
5379
// HTLC when the monitor updating is restored (or on chain).
5380
+ let logger = WithContext::from(&self.logger, None, Some(prev_hop_chan_id));
5379
5381
log_error!(self.logger, "Temporary failure claiming HTLC, treating as success: {}", err.err.err);
5380
5382
} else { errs.push((pk, err)); }
5381
5383
}
@@ -10035,7 +10037,7 @@ where
10035
10037
log_error!(logger, "A ChannelManager is stale compared to the current ChannelMonitor!");
10036
10038
log_error!(logger, " The channel will be force-closed and the latest commitment transaction from the ChannelMonitor broadcast.");
10037
10039
if channel.context.get_latest_monitor_update_id() < monitor.get_latest_update_id() {
10038
- log_error!(args. logger, " The ChannelMonitor for channel {} is at update_id {} but the ChannelManager is at update_id {}.",
10040
+ log_error!(logger, " The ChannelMonitor for channel {} is at update_id {} but the ChannelManager is at update_id {}.",
10039
10041
&channel.context.channel_id(), monitor.get_latest_update_id(), channel.context.get_latest_monitor_update_id());
10040
10042
}
10041
10043
if channel.get_cur_holder_commitment_transaction_number() > monitor.get_cur_holder_commitment_number() {
@@ -10431,7 +10433,7 @@ where
10431
10433
let counterparty_opt = id_to_peer.get(&monitor.get_funding_txo().0.to_channel_id());
10432
10434
let chan_id = monitor.get_funding_txo().0.to_channel_id();
10433
10435
if counterparty_opt.is_none() {
10434
- let logger = WithContext ::from(&args.logger, None, Some(chan_id) );
10436
+ let logger = WithChannelMonitor ::from(&args.logger, monitor );
10435
10437
for (htlc_source, (htlc, _)) in monitor.get_pending_or_resolved_outbound_htlcs() {
10436
10438
if let HTLCSource::OutboundRoute { payment_id, session_priv, path, .. } = htlc_source {
10437
10439
if path.hops.is_empty() {
0 commit comments