From 17e829217e9fb8af368262256c9700a2bfb98dfa Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 11 Dec 2023 19:48:51 +0100 Subject: [PATCH 1/4] Fix leftover `rustdoc` warnings .. as these slipped in again. --- lightning/src/lib.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lightning/src/lib.rs b/lightning/src/lib.rs index df1bb1a2a2f..c42f66da576 100644 --- a/lightning/src/lib.rs +++ b/lightning/src/lib.rs @@ -40,9 +40,8 @@ #![cfg_attr(not(any(test, fuzzing, feature = "_test_utils")), deny(missing_docs))] #![cfg_attr(not(any(test, feature = "_test_utils")), forbid(unsafe_code))] -// Prefix these with `rustdoc::` when we update our MSRV to be >= 1.52 to remove warnings. -#![deny(broken_intra_doc_links)] -#![deny(private_intra_doc_links)] +#![deny(rustdoc::broken_intra_doc_links)] +#![deny(rustdoc::private_intra_doc_links)] // In general, rust is absolutely horrid at supporting users doing things like, // for example, compiling Rust code for real environments. Disable useless lints From 79cff6ce9f7d6c3fac8eba6023ecb2df40c8e303 Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 11 Dec 2023 19:50:27 +0100 Subject: [PATCH 2/4] Remove unused `chan_id` --- lightning/src/ln/channelmanager.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/lightning/src/ln/channelmanager.rs b/lightning/src/ln/channelmanager.rs index be220f82430..da95e3b618c 100644 --- a/lightning/src/ln/channelmanager.rs +++ b/lightning/src/ln/channelmanager.rs @@ -10495,7 +10495,6 @@ where // 0.0.102+ for (_, monitor) in args.channel_monitors.iter() { let counterparty_opt = id_to_peer.get(&monitor.get_funding_txo().0.to_channel_id()); - let chan_id = monitor.get_funding_txo().0.to_channel_id(); if counterparty_opt.is_none() { let logger = WithChannelMonitor::from(&args.logger, monitor); for (htlc_source, (htlc, _)) in monitor.get_pending_or_resolved_outbound_htlcs() { From c9ea2cebee1ca47b5c0701dd8d5d5c54250942d9 Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 11 Dec 2023 19:52:24 +0100 Subject: [PATCH 3/4] Markup packages link as hyperlink --- lightning/src/chain/chaininterface.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightning/src/chain/chaininterface.rs b/lightning/src/chain/chaininterface.rs index 2d7f0c18af3..1f42dc2fe42 100644 --- a/lightning/src/chain/chaininterface.rs +++ b/lightning/src/chain/chaininterface.rs @@ -40,7 +40,7 @@ pub trait BroadcasterInterface { /// be sure to manage both cases correctly. /// /// Bitcoin transaction packages are defined in BIP 331 and here: - /// https://github.com/bitcoin/bitcoin/blob/master/doc/policy/packages.md + /// fn broadcast_transactions(&self, txs: &[&Transaction]); } From 5112ac2f3f7a8f9c93ed563759c2da3888b800e9 Mon Sep 17 00:00:00 2001 From: Elias Rohrer Date: Mon, 11 Dec 2023 19:58:46 +0100 Subject: [PATCH 4/4] Remove unused `NodeId` in BP tests --- lightning-background-processor/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lightning-background-processor/src/lib.rs b/lightning-background-processor/src/lib.rs index 68940704797..62c03b81dfe 100644 --- a/lightning-background-processor/src/lib.rs +++ b/lightning-background-processor/src/lib.rs @@ -903,7 +903,7 @@ mod tests { use lightning::ln::functional_test_utils::*; use lightning::ln::msgs::{ChannelMessageHandler, Init}; use lightning::ln::peer_handler::{PeerManager, MessageHandler, SocketDescriptor, IgnoringMessageHandler}; - use lightning::routing::gossip::{NetworkGraph, NodeId, P2PGossipSync}; + use lightning::routing::gossip::{NetworkGraph, P2PGossipSync}; use lightning::routing::scoring::{ChannelUsage, ScoreUpdate, ScoreLookUp, LockableScore}; use lightning::routing::router::{DefaultRouter, Path, RouteHop, CandidateRouteHop}; use lightning::util::config::UserConfig;