Skip to content

Commit 64c1243

Browse files
committed
Drop lightning::ln::features::* type aliases
These were deprecated in 0.0.124, and we drop them here in favor of `lightning::types::features::*`.
1 parent ad19d93 commit 64c1243

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+80
-89
lines changed

fuzz/src/invoice_request_deser.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ use lightning::blinded_path::payment::{
1515
PaymentForwardNode, PaymentRelay, ReceiveTlvs,
1616
};
1717
use lightning::ln::channelmanager::MIN_FINAL_CLTV_EXPIRY_DELTA;
18-
use lightning::ln::features::BlindedHopFeatures;
1918
use lightning::ln::types::PaymentSecret;
2019
use lightning::ln::PaymentHash;
2120
use lightning::offers::invoice::UnsignedBolt12Invoice;
2221
use lightning::offers::invoice_request::{InvoiceRequest, InvoiceRequestFields};
2322
use lightning::offers::offer::OfferId;
2423
use lightning::offers::parse::Bolt12SemanticError;
2524
use lightning::sign::EntropySource;
25+
use lightning::types::features::BlindedHopFeatures;
2626
use lightning::util::ser::Writeable;
2727
use lightning::util::string::UntrustedString;
2828

fuzz/src/onion_message.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ use lightning::blinded_path::message::{
99
AsyncPaymentsContext, BlindedMessagePath, MessageContext, OffersContext,
1010
};
1111
use lightning::blinded_path::EmptyNodeIdLookUp;
12-
use lightning::ln::features::InitFeatures;
1312
use lightning::ln::msgs::{self, DecodeError, OnionMessageHandler};
1413
use lightning::ln::peer_handler::IgnoringMessageHandler;
1514
use lightning::ln::script::ShutdownScript;
@@ -25,6 +24,7 @@ use lightning::onion_message::messenger::{
2524
use lightning::onion_message::offers::{OffersMessage, OffersMessageHandler};
2625
use lightning::onion_message::packet::OnionMessageContents;
2726
use lightning::sign::{EntropySource, KeyMaterial, NodeSigner, Recipient, SignerProvider};
27+
use lightning::types::features::InitFeatures;
2828
use lightning::util::logger::Logger;
2929
use lightning::util::ser::{Readable, Writeable, Writer};
3030
use lightning::util::test_channel_signer::TestChannelSigner;

fuzz/src/refund_deser.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ use lightning::blinded_path::payment::{
1515
PaymentForwardNode, PaymentRelay, ReceiveTlvs,
1616
};
1717
use lightning::ln::channelmanager::MIN_FINAL_CLTV_EXPIRY_DELTA;
18-
use lightning::ln::features::BlindedHopFeatures;
1918
use lightning::ln::types::PaymentSecret;
2019
use lightning::ln::PaymentHash;
2120
use lightning::offers::invoice::UnsignedBolt12Invoice;
2221
use lightning::offers::parse::Bolt12SemanticError;
2322
use lightning::offers::refund::Refund;
2423
use lightning::sign::EntropySource;
24+
use lightning::types::features::BlindedHopFeatures;
2525
use lightning::util::ser::Writeable;
2626

2727
#[inline]

fuzz/src/router.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ use lightning::blinded_path::BlindedHop;
1717
use lightning::chain::transaction::OutPoint;
1818
use lightning::ln::channel_state::{ChannelCounterparty, ChannelDetails, ChannelShutdownState};
1919
use lightning::ln::channelmanager;
20-
use lightning::ln::features::{BlindedHopFeatures, Bolt12InvoiceFeatures};
2120
use lightning::ln::msgs;
2221
use lightning::ln::types::ChannelId;
2322
use lightning::routing::gossip::{NetworkGraph, RoutingFees};
@@ -28,6 +27,7 @@ use lightning::routing::scoring::{
2827
ProbabilisticScorer, ProbabilisticScoringDecayParameters, ProbabilisticScoringFeeParameters,
2928
};
3029
use lightning::routing::utxo::{UtxoFuture, UtxoLookup, UtxoLookupError, UtxoResult};
30+
use lightning::types::features::{BlindedHopFeatures, Bolt12InvoiceFeatures};
3131
use lightning::util::config::UserConfig;
3232
use lightning::util::hash_tables::*;
3333
use lightning::util::ser::Readable;

lightning-background-processor/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1087,7 +1087,6 @@ mod tests {
10871087
use lightning::ln::channelmanager::{
10881088
ChainParameters, PaymentId, BREAKDOWN_TIMEOUT, MIN_CLTV_EXPIRY_DELTA,
10891089
};
1090-
use lightning::ln::features::{ChannelFeatures, NodeFeatures};
10911090
use lightning::ln::functional_test_utils::*;
10921091
use lightning::ln::msgs::{ChannelMessageHandler, Init};
10931092
use lightning::ln::peer_handler::{
@@ -1099,6 +1098,7 @@ mod tests {
10991098
use lightning::routing::router::{CandidateRouteHop, DefaultRouter, Path, RouteHop};
11001099
use lightning::routing::scoring::{ChannelUsage, LockableScore, ScoreLookUp, ScoreUpdate};
11011100
use lightning::sign::{ChangeDestinationSource, InMemorySigner, KeysManager};
1101+
use lightning::types::features::{ChannelFeatures, NodeFeatures};
11021102
use lightning::util::config::UserConfig;
11031103
use lightning::util::persist::{
11041104
KVStore, CHANNEL_MANAGER_PERSISTENCE_KEY, CHANNEL_MANAGER_PERSISTENCE_PRIMARY_NAMESPACE,

lightning-custom-message/src/lib.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@
2121
//! # use bitcoin::secp256k1::PublicKey;
2222
//! # use lightning::io;
2323
//! # use lightning::ln::msgs::{DecodeError, Init, LightningError};
24-
//! # use lightning::ln::features::{InitFeatures, NodeFeatures};
2524
//! use lightning::ln::peer_handler::CustomMessageHandler;
2625
//! use lightning::ln::wire::{CustomMessageReader, self};
26+
//! # use lightning::types::features::{InitFeatures, NodeFeatures};
2727
//! use lightning::util::ser::Writeable;
2828
//! # use lightning::util::ser::Writer;
2929
//!
@@ -321,17 +321,17 @@ macro_rules! composite_custom_message_handler {
321321
result
322322
}
323323

324-
fn provided_node_features(&self) -> $crate::lightning::ln::features::NodeFeatures {
325-
$crate::lightning::ln::features::NodeFeatures::empty()
324+
fn provided_node_features(&self) -> $crate::lightning::types::features::NodeFeatures {
325+
$crate::lightning::types::features::NodeFeatures::empty()
326326
$(
327327
| self.$field.provided_node_features()
328328
)*
329329
}
330330

331331
fn provided_init_features(
332332
&self, their_node_id: $crate::bitcoin::secp256k1::PublicKey
333-
) -> $crate::lightning::ln::features::InitFeatures {
334-
$crate::lightning::ln::features::InitFeatures::empty()
333+
) -> $crate::lightning::types::features::InitFeatures {
334+
$crate::lightning::types::features::InitFeatures::empty()
335335
$(
336336
| self.$field.provided_init_features(their_node_id)
337337
)*

lightning-net-tokio/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -624,10 +624,10 @@ mod tests {
624624
use bitcoin::secp256k1::{PublicKey, Secp256k1, SecretKey};
625625
use bitcoin::Network;
626626
use lightning::events::*;
627-
use lightning::ln::features::*;
628627
use lightning::ln::msgs::*;
629628
use lightning::ln::peer_handler::{IgnoringMessageHandler, MessageHandler, PeerManager};
630629
use lightning::routing::gossip::NodeId;
630+
use lightning::types::features::*;
631631
use lightning::util::test_utils::TestNodeSigner;
632632

633633
use tokio::sync::mpsc;

lightning-rapid-gossip-sync/src/processing.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use std::time::{SystemTime, UNIX_EPOCH};
2222

2323
#[cfg(all(not(feature = "std"), not(test)))]
2424
use alloc::{borrow::ToOwned, vec::Vec};
25-
use lightning::ln::features::NodeFeatures;
25+
use lightning::types::features::NodeFeatures;
2626

2727
/// The purpose of this prefix is to identify the serialization format, should other rapid gossip
2828
/// sync formats arise in the future.

lightning/src/blinded_path/payment.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use crate::io;
1818
use crate::io::Cursor;
1919
use crate::ln::types::PaymentSecret;
2020
use crate::ln::channel_state::CounterpartyForwardingInfo;
21-
use crate::ln::features::BlindedHopFeatures;
21+
use crate::types::features::BlindedHopFeatures;
2222
use crate::ln::msgs::DecodeError;
2323
use crate::ln::onion_utils;
2424
use crate::offers::invoice_request::InvoiceRequestFields;
@@ -633,7 +633,7 @@ mod tests {
633633
use bitcoin::secp256k1::PublicKey;
634634
use crate::blinded_path::payment::{PaymentForwardNode, ForwardTlvs, ReceiveTlvs, PaymentConstraints, PaymentContext, PaymentRelay};
635635
use crate::ln::types::PaymentSecret;
636-
use crate::ln::features::BlindedHopFeatures;
636+
use crate::types::features::BlindedHopFeatures;
637637
use crate::ln::functional_test_utils::TEST_FINAL_CLTV;
638638

639639
#[test]

lightning/src/chain/channelmonitor.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5018,7 +5018,7 @@ mod tests {
50185018
use crate::util::logger::Logger;
50195019
use crate::sync::Arc;
50205020
use crate::io;
5021-
use crate::ln::features::ChannelTypeFeatures;
5021+
use crate::types::features::ChannelTypeFeatures;
50225022

50235023
#[allow(unused_imports)]
50245024
use crate::prelude::*;

lightning/src/chain/onchaintx.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ use core::cmp;
4444
use core::ops::Deref;
4545
use core::mem::replace;
4646
use core::mem::swap;
47-
use crate::ln::features::ChannelTypeFeatures;
47+
use crate::types::features::ChannelTypeFeatures;
4848

4949
const MAX_ALLOC_SIZE: usize = 64*1024;
5050

lightning/src/chain/package.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ use bitcoin::transaction::Version;
2626

2727
use crate::ln::types::PaymentPreimage;
2828
use crate::ln::chan_utils::{self, TxCreationKeys, HTLCOutputInCommitment};
29-
use crate::ln::features::ChannelTypeFeatures;
29+
use crate::types::features::ChannelTypeFeatures;
3030
use crate::ln::channel_keys::{DelayedPaymentBasepoint, HtlcBasepoint};
3131
use crate::ln::msgs::DecodeError;
3232
use crate::chain::chaininterface::{FeeEstimator, ConfirmationTarget, MIN_RELAY_FEE_SAT_PER_1000_WEIGHT, compute_feerate_sat_per_1000_weight, FEERATE_FLOOR_SATS_PER_KW};
@@ -1211,7 +1211,7 @@ mod tests {
12111211

12121212
use bitcoin::secp256k1::{PublicKey,SecretKey};
12131213
use bitcoin::secp256k1::Secp256k1;
1214-
use crate::ln::features::ChannelTypeFeatures;
1214+
use crate::types::features::ChannelTypeFeatures;
12151215

12161216
use std::str::FromStr;
12171217

lightning/src/events/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ use crate::blinded_path::payment::{Bolt12OfferContext, Bolt12RefundContext, Paym
2323
use crate::chain::transaction;
2424
use crate::ln::channelmanager::{InterceptId, PaymentId, RecipientOnionFields};
2525
use crate::ln::channel::FUNDING_CONF_DEADLINE_BLOCKS;
26-
use crate::ln::features::ChannelTypeFeatures;
26+
use crate::types::features::ChannelTypeFeatures;
2727
use crate::ln::msgs;
2828
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash, PaymentSecret};
2929
use crate::offers::invoice::Bolt12Invoice;

lightning/src/ln/blinded_payment_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ use crate::events::{Event, HTLCDestination, MessageSendEvent, MessageSendEventsP
1717
use crate::ln::types::{ChannelId, PaymentHash, PaymentSecret};
1818
use crate::ln::channelmanager;
1919
use crate::ln::channelmanager::{HTLCFailureMsg, PaymentId, RecipientOnionFields};
20-
use crate::ln::features::{BlindedHopFeatures, ChannelFeatures, NodeFeatures};
20+
use crate::types::features::{BlindedHopFeatures, ChannelFeatures, NodeFeatures};
2121
use crate::ln::functional_test_utils::*;
2222
use crate::ln::msgs;
2323
use crate::ln::msgs::{ChannelMessageHandler, UnsignedGossipMessage};

lightning/src/ln/chan_utils.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ use crate::util::transaction_utils::sort_outputs;
4545
use crate::ln::channel::{INITIAL_COMMITMENT_NUMBER, ANCHOR_OUTPUT_VALUE_SATOSHI};
4646
use core::ops::Deref;
4747
use crate::chain;
48-
use crate::ln::features::ChannelTypeFeatures;
48+
use crate::types::features::ChannelTypeFeatures;
4949
use crate::crypto::utils::{sign, sign_with_aux_rand};
5050
use super::channel_keys::{DelayedPaymentBasepoint, DelayedPaymentKey, HtlcKey, HtlcBasepoint, RevocationKey, RevocationBasepoint};
5151

@@ -1903,7 +1903,7 @@ mod tests {
19031903
use bitcoin::hex::FromHex;
19041904
use crate::ln::types::PaymentHash;
19051905
use bitcoin::PublicKey as BitcoinPublicKey;
1906-
use crate::ln::features::ChannelTypeFeatures;
1906+
use crate::types::features::ChannelTypeFeatures;
19071907

19081908
#[allow(unused_imports)]
19091909
use crate::prelude::*;

lightning/src/ln/channel.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ use bitcoin::secp256k1::{Secp256k1,ecdsa::Signature};
2626
use bitcoin::secp256k1;
2727

2828
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash};
29-
use crate::ln::features::{ChannelTypeFeatures, InitFeatures};
29+
use crate::types::features::{ChannelTypeFeatures, InitFeatures};
3030
use crate::ln::msgs;
3131
use crate::ln::msgs::{ClosingSigned, ClosingSignedFeeRange, DecodeError};
3232
use crate::ln::script::{self, ShutdownScript};
@@ -9611,7 +9611,7 @@ mod tests {
96119611
use crate::ln::channel::InitFeatures;
96129612
use crate::ln::channel::{AwaitingChannelReadyFlags, Channel, ChannelState, InboundHTLCOutput, OutboundV1Channel, InboundV1Channel, OutboundHTLCOutput, InboundHTLCState, OutboundHTLCState, HTLCCandidate, HTLCInitiator, HTLCUpdateAwaitingACK, commit_tx_fee_sat};
96139613
use crate::ln::channel::{MAX_FUNDING_SATOSHIS_NO_WUMBO, TOTAL_BITCOIN_SUPPLY_SATOSHIS, MIN_THEIR_CHAN_RESERVE_SATOSHIS};
9614-
use crate::ln::features::{ChannelFeatures, ChannelTypeFeatures, NodeFeatures};
9614+
use crate::types::features::{ChannelFeatures, ChannelTypeFeatures, NodeFeatures};
96159615
use crate::ln::msgs;
96169616
use crate::ln::msgs::{ChannelUpdate, DecodeError, UnsignedChannelUpdate, MAX_VALUE_MSAT};
96179617
use crate::ln::script::ShutdownScript;

lightning/src/ln/channel_state.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,10 +17,10 @@ use crate::chain::chaininterface::{FeeEstimator, LowerBoundedFeeEstimator};
1717
use crate::chain::transaction::OutPoint;
1818
use crate::io;
1919
use crate::ln::channel::ChannelContext;
20-
use crate::ln::features::{ChannelTypeFeatures, InitFeatures};
2120
use crate::ln::msgs::DecodeError;
2221
use crate::ln::types::{ChannelId, PaymentHash};
2322
use crate::sign::SignerProvider;
23+
use crate::types::features::{ChannelTypeFeatures, InitFeatures};
2424
use crate::util::config::ChannelConfig;
2525
use crate::util::ser::{Readable, Writeable, Writer};
2626

lightning/src/ln/channelmanager.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ use crate::ln::inbound_payment;
5050
use crate::ln::types::{ChannelId, PaymentHash, PaymentPreimage, PaymentSecret};
5151
use crate::ln::channel::{self, Channel, ChannelPhase, ChannelContext, ChannelError, ChannelUpdateStatus, ShutdownResult, UnfundedChannelContext, UpdateFulfillCommitFetch, OutboundV1Channel, InboundV1Channel, WithChannelContext};
5252
use crate::ln::channel_state::ChannelDetails;
53-
use crate::ln::features::{Bolt12InvoiceFeatures, ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
53+
use crate::types::features::{Bolt12InvoiceFeatures, ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
5454
#[cfg(any(feature = "_test_utils", test))]
55-
use crate::ln::features::Bolt11InvoiceFeatures;
55+
use crate::types::features::Bolt11InvoiceFeatures;
5656
use crate::routing::router::{BlindedTail, InFlightHtlcs, Path, Payee, PaymentParameters, Route, RouteParameters, Router};
5757
use crate::ln::onion_payment::{check_incoming_htlc_cltv, create_recv_pending_htlc_info, create_fwd_pending_htlc_info, decode_incoming_update_add_htlc_onion, InboundHTLCErr, NextPacketDetails};
5858
use crate::ln::msgs;

lightning/src/ln/features.rs

Lines changed: 6 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,12 @@
77
// You may not use this file except in accordance with one or both of these
88
// licenses.
99

10-
//! Feature flag definitions for the Lightning protocol according to [BOLT #9].
11-
//!
12-
//! See [`lightning_types::features`] for the list of features currently supported.
13-
//!
14-
//! Note that the use of types via this module is deprecated and will be removed in a future
15-
//! version. Instead, use feature objects via [`lightning::types::features`].
16-
//!
17-
//! [`lightning::types::features`]: crate::types::features
18-
//! [BOLT #9]: https://github.com/lightning/bolts/blob/master/09-features.md
19-
20-
pub use lightning_types::features::Features;
21-
pub use lightning_types::features::{InitFeatures, NodeFeatures, ChannelFeatures};
22-
pub use lightning_types::features::{Bolt11InvoiceFeatures, OfferFeatures, InvoiceRequestFeatures};
23-
pub use lightning_types::features::{Bolt12InvoiceFeatures, BlindedHopFeatures};
24-
pub use lightning_types::features::ChannelTypeFeatures;
10+
//! Implementations of extensions on features.
11+
12+
use lightning_types::features::{InitFeatures, NodeFeatures, ChannelFeatures};
13+
use lightning_types::features::{Bolt11InvoiceFeatures, OfferFeatures, InvoiceRequestFeatures};
14+
use lightning_types::features::{Bolt12InvoiceFeatures, BlindedHopFeatures};
15+
use lightning_types::features::ChannelTypeFeatures;
2516

2617
#[allow(unused_imports)]
2718
use crate::prelude::*;

lightning/src/ln/functional_test_utils.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ use crate::events::{ClaimedHTLC, ClosureReason, Event, HTLCDestination, MessageS
1717
use crate::events::bump_transaction::{BumpTransactionEvent, BumpTransactionEventHandler, Wallet, WalletSource};
1818
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash, PaymentSecret};
1919
use crate::ln::channelmanager::{AChannelManager, ChainParameters, ChannelManager, ChannelManagerReadArgs, RAACommitmentOrder, PaymentSendFailure, RecipientOnionFields, PaymentId, MIN_CLTV_EXPIRY_DELTA};
20-
use crate::ln::features::InitFeatures;
20+
use crate::types::features::InitFeatures;
2121
use crate::ln::msgs;
2222
use crate::ln::msgs::{ChannelMessageHandler, OnionMessageHandler, RoutingMessageHandler};
2323
use crate::ln::peer_handler::IgnoringMessageHandler;

lightning/src/ln/functional_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ use crate::ln::{chan_utils, onion_utils};
2727
use crate::ln::chan_utils::{commitment_tx_base_weight, COMMITMENT_TX_WEIGHT_PER_HTLC, OFFERED_HTLC_SCRIPT_WEIGHT, htlc_success_tx_weight, htlc_timeout_tx_weight, HTLCOutputInCommitment};
2828
use crate::routing::gossip::{NetworkGraph, NetworkUpdate};
2929
use crate::routing::router::{Path, PaymentParameters, Route, RouteHop, get_route, RouteParameters};
30-
use crate::ln::features::{ChannelFeatures, ChannelTypeFeatures, NodeFeatures};
30+
use crate::types::features::{ChannelFeatures, ChannelTypeFeatures, NodeFeatures};
3131
use crate::ln::msgs;
3232
use crate::ln::msgs::{ChannelMessageHandler, RoutingMessageHandler, ErrorAction};
3333
use crate::util::test_channel_signer::TestChannelSigner;

lightning/src/ln/max_payment_path_len_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ use crate::events::{Event, MessageSendEventsProvider};
1717
use crate::ln::PaymentSecret;
1818
use crate::ln::blinded_payment_tests::get_blinded_route_parameters;
1919
use crate::ln::channelmanager::PaymentId;
20-
use crate::ln::features::BlindedHopFeatures;
20+
use crate::types::features::BlindedHopFeatures;
2121
use crate::ln::functional_test_utils::*;
2222
use crate::ln::msgs;
2323
use crate::ln::msgs::OnionMessageHandler;

lightning/src/ln/msgs.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ use bitcoin::hash_types::Txid;
3333

3434
use crate::blinded_path::payment::{BlindedPaymentTlvs, ForwardTlvs, ReceiveTlvs};
3535
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash, PaymentSecret};
36-
use crate::ln::features::{ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
36+
use crate::types::features::{ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
3737
use crate::ln::onion_utils;
3838
use crate::onion_message;
3939
use crate::sign::{NodeSigner, Recipient};
@@ -1747,7 +1747,7 @@ mod fuzzy_internal_msgs {
17471747
use bitcoin::secp256k1::PublicKey;
17481748
use crate::blinded_path::payment::{PaymentConstraints, PaymentContext, PaymentRelay};
17491749
use crate::ln::types::{PaymentPreimage, PaymentSecret};
1750-
use crate::ln::features::BlindedHopFeatures;
1750+
use crate::types::features::BlindedHopFeatures;
17511751
use super::{FinalOnionHopData, TrampolineOnionPacket};
17521752

17531753
#[allow(unused_imports)]
@@ -3299,7 +3299,7 @@ mod tests {
32993299
use bitcoin::{Amount, Transaction, TxIn, ScriptBuf, Sequence, Witness, TxOut};
33003300
use bitcoin::hex::DisplayHex;
33013301
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash, PaymentSecret};
3302-
use crate::ln::features::{ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
3302+
use crate::types::features::{ChannelFeatures, ChannelTypeFeatures, InitFeatures, NodeFeatures};
33033303
use crate::ln::msgs::{self, FinalOnionHopData, OnionErrorPacket, CommonOpenChannelFields, CommonAcceptChannelFields, TrampolineOnionPacket};
33043304
use crate::ln::msgs::SocketAddress;
33053305
use crate::routing::gossip::{NodeAlias, NodeId};

lightning/src/ln/offers_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ use crate::blinded_path::payment::{Bolt12OfferContext, Bolt12RefundContext, Paym
4949
use crate::blinded_path::message::{MessageContext, OffersContext};
5050
use crate::events::{ClosureReason, Event, MessageSendEventsProvider, PaymentFailureReason, PaymentPurpose};
5151
use crate::ln::channelmanager::{Bolt12PaymentError, MAX_SHORT_LIVED_RELATIVE_EXPIRY, PaymentId, RecentPaymentDetails, Retry, self};
52-
use crate::ln::features::Bolt12InvoiceFeatures;
52+
use crate::types::features::Bolt12InvoiceFeatures;
5353
use crate::ln::functional_test_utils::*;
5454
use crate::ln::inbound_payment::ExpandedKey;
5555
use crate::ln::msgs::{ChannelMessageHandler, Init, NodeAnnouncement, OnionMessage, OnionMessageHandler, RoutingMessageHandler, SocketAddress, UnsignedGossipMessage, UnsignedNodeAnnouncement};

lightning/src/ln/onion_payment.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use crate::blinded_path::payment::{PaymentConstraints, PaymentRelay};
1313
use crate::chain::channelmonitor::{HTLC_FAIL_BACK_BUFFER, LATENCY_GRACE_PERIOD_BLOCKS};
1414
use crate::ln::types::PaymentHash;
1515
use crate::ln::channelmanager::{BlindedFailure, BlindedForward, CLTV_FAR_FAR_AWAY, HTLCFailureMsg, MIN_CLTV_EXPIRY_DELTA, PendingHTLCInfo, PendingHTLCRouting};
16-
use crate::ln::features::BlindedHopFeatures;
16+
use crate::types::features::BlindedHopFeatures;
1717
use crate::ln::msgs;
1818
use crate::ln::onion_utils;
1919
use crate::ln::onion_utils::{HTLCFailReason, INVALID_ONION_BLINDING};
@@ -510,7 +510,7 @@ mod tests {
510510
use bitcoin::secp256k1::{PublicKey, Secp256k1, SecretKey};
511511
use crate::ln::types::{ChannelId, PaymentPreimage, PaymentHash, PaymentSecret};
512512
use crate::ln::channelmanager::RecipientOnionFields;
513-
use crate::ln::features::{ChannelFeatures, NodeFeatures};
513+
use crate::types::features::{ChannelFeatures, NodeFeatures};
514514
use crate::ln::msgs;
515515
use crate::ln::onion_utils::create_payment_onion;
516516
use crate::routing::router::{Path, RouteHop};

lightning/src/ln/onion_route_tests.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use crate::ln::channelmanager::{HTLCForwardInfo, FailureCode, CLTV_FAR_FAR_AWAY,
2020
use crate::ln::onion_utils;
2121
use crate::routing::gossip::{NetworkUpdate, RoutingFees};
2222
use crate::routing::router::{get_route, PaymentParameters, Route, RouteParameters, RouteHint, RouteHintHop};
23-
use crate::ln::features::{InitFeatures, Bolt11InvoiceFeatures};
23+
use crate::types::features::{InitFeatures, Bolt11InvoiceFeatures};
2424
use crate::ln::functional_test_utils::test_default_channel_config;
2525
use crate::ln::msgs;
2626
use crate::ln::msgs::{ChannelMessageHandler, ChannelUpdate, OutboundTrampolinePayload};

0 commit comments

Comments
 (0)