Skip to content

Commit 0acc230

Browse files
committed
Log penalty for each path when logging Route
1 parent 9752595 commit 0acc230

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lightning/src/util/macro_logger.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ pub(crate) struct DebugRoute<'a>(pub &'a Route);
7272
impl<'a> core::fmt::Display for DebugRoute<'a> {
7373
fn fmt(&self, f: &mut core::fmt::Formatter) -> Result<(), core::fmt::Error> {
7474
for (idx, p) in self.0.paths.iter().enumerate() {
75-
writeln!(f, "path {}:", idx)?;
75+
writeln!(f, "path {} (penalty: {}):", idx, self.0.path_penalties[idx])?;
7676
for h in p.iter() {
7777
writeln!(f, " node_id: {}, short_channel_id: {}, fee_msat: {}, cltv_expiry_delta: {}", log_pubkey!(h.pubkey), h.short_channel_id, h.fee_msat, h.cltv_expiry_delta)?;
7878
}

0 commit comments

Comments
 (0)