From: Matt Corallo <649246+TheBlueMatt@users.noreply.github.com> Date: Wed, 29 Mar 2023 21:54:58 +0000 (+0000) Subject: Merge pull request #2059 from wpaulino/broadcast-missing-anchors-event X-Git-Tag: v0.0.115~46 X-Git-Url: http://git.bitcoin.ninja/?a=commitdiff_plain;h=a9534fe6b53ee5a35bcedb897f03804dc17f2d39;p=rust-lightning Merge pull request #2059 from wpaulino/broadcast-missing-anchors-event Queue BackgroundEvent to force close channels upon ChannelManager::read --- a9534fe6b53ee5a35bcedb897f03804dc17f2d39 diff --cc lightning-persister/src/lib.rs index 3bdf444dd,01cb4081c..e6687fef7 --- a/lightning-persister/src/lib.rs +++ b/lightning-persister/src/lib.rs @@@ -141,10 -141,11 +141,11 @@@ mod tests use bitcoin::{Txid, TxMerkleNode}; use lightning::chain::ChannelMonitorUpdateStatus; use lightning::chain::chainmonitor::Persist; + use lightning::chain::channelmonitor::CLOSED_CHANNEL_UPDATE_ID; use lightning::chain::transaction::OutPoint; use lightning::{check_closed_broadcast, check_closed_event, check_added_monitors}; + use lightning::events::{ClosureReason, MessageSendEventsProvider}; use lightning::ln::functional_test_utils::*; - use lightning::util::events::{ClosureReason, MessageSendEventsProvider}; use lightning::util::test_utils; use std::fs; use bitcoin::hashes::Hash; diff --cc lightning/src/ln/channel.rs index f47046942,ae45f5e8f..f1c5cae25 --- a/lightning/src/ln/channel.rs +++ b/lightning/src/ln/channel.rs @@@ -33,11 -33,11 +33,11 @@@ use crate::ln::chan_utils use crate::ln::onion_utils::HTLCFailReason; use crate::chain::BestBlock; use crate::chain::chaininterface::{FeeEstimator, ConfirmationTarget, LowerBoundedFeeEstimator}; - use crate::chain::channelmonitor::{ChannelMonitor, ChannelMonitorUpdate, ChannelMonitorUpdateStep, LATENCY_GRACE_PERIOD_BLOCKS}; + use crate::chain::channelmonitor::{ChannelMonitor, ChannelMonitorUpdate, ChannelMonitorUpdateStep, LATENCY_GRACE_PERIOD_BLOCKS, CLOSED_CHANNEL_UPDATE_ID}; use crate::chain::transaction::{OutPoint, TransactionData}; use crate::chain::keysinterface::{WriteableEcdsaChannelSigner, EntropySource, ChannelSigner, SignerProvider, NodeSigner, Recipient}; +use crate::events::ClosureReason; use crate::routing::gossip::NodeId; -use crate::util::events::ClosureReason; use crate::util::ser::{Readable, ReadableArgs, Writeable, Writer, VecWriter}; use crate::util::logger::Logger; use crate::util::errors::APIError;