Skip to content

Conversation

@create-pr-actions
Copy link

Automated update to Github CI workflow cont_integration.yml by create-pull-request GitHub action

@ValuedMammal
Copy link
Collaborator

Some lifetimes were hidden. Using a named (or anonymous) lifetime seems to fix it.

diff --git a/wallet/src/descriptor/policy.rs b/wallet/src/descriptor/policy.rs
index eb9014cb..100348f6 100644
--- a/wallet/src/descriptor/policy.rs
+++ b/wallet/src/descriptor/policy.rs
@@ -1053,9 +1053,9 @@ impl<Ctx: ScriptContext + 'static> ExtractPolicy for Miniscript<DescriptorPublic
         })
     }
 }
 
-fn psbt_inputs_sat(psbt: &Psbt) -> impl Iterator<Item = PsbtInputSatisfier> {
+fn psbt_inputs_sat(psbt: &Psbt) -> impl Iterator<Item = PsbtInputSatisfier<'_>> {
     (0..psbt.inputs.len()).map(move |i| PsbtInputSatisfier::new(psbt, i))
 }
 
 /// Options to build the satisfaction field in the policy
diff --git a/wallet/src/wallet/mod.rs b/wallet/src/wallet/mod.rs
index c1aab082..e1f957cd 100644
--- a/wallet/src/wallet/mod.rs
+++ b/wallet/src/wallet/mod.rs
@@ -1164,9 +1164,9 @@ impl Wallet {
     /// }
     /// ```
     ///
     /// [`Anchor`]: bdk_chain::Anchor
-    pub fn get_tx(&self, txid: Txid) -> Option<WalletTx> {
+    pub fn get_tx(&self, txid: Txid) -> Option<WalletTx<'_>> {
         let graph = self.indexed_graph.graph();
         graph
             .list_canonical_txs(
                 &self.chain,
@@ -1186,9 +1186,9 @@ impl Wallet {
     /// [`TxGraph::full_txs`].
     ///
     /// To iterate over all canonical transactions, including those that are irrelevant, use
     /// [`TxGraph::list_canonical_txs`].
-    pub fn transactions(&self) -> impl Iterator<Item = WalletTx> + '_ {
+    pub fn transactions<'a>(&'a self) -> impl Iterator<Item = WalletTx<'a>> + 'a {
         let tx_graph = self.indexed_graph.graph();
         let tx_index = &self.indexed_graph.index;
         tx_graph
             .list_canonical_txs(
@@ -1214,9 +1214,9 @@ impl Wallet {
     /// let sorted_txs: Vec<WalletTx> =
     ///     wallet.transactions_sort_by(|tx1, tx2| tx2.chain_position.cmp(&tx1.chain_position));
     /// # Ok::<(), anyhow::Error>(())
     /// ```
-    pub fn transactions_sort_by<F>(&self, compare: F) -> Vec<WalletTx>
+    pub fn transactions_sort_by<F>(&self, compare: F) -> Vec<WalletTx<'_>>
     where
         F: FnMut(&WalletTx, &WalletTx) -> Ordering,
     {

Copy link
Collaborator

@ValuedMammal ValuedMammal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 00ee0ae

@ValuedMammal ValuedMammal merged commit c21ff21 into master Aug 21, 2025
55 of 56 checks passed
@ValuedMammal ValuedMammal added this to the Wallet 2.2.0 milestone Aug 21, 2025
@ValuedMammal ValuedMammal deleted the create-pull-request/update-rust-version branch August 27, 2025 15:01
ValuedMammal added a commit that referenced this pull request Sep 20, 2025
42d9b90 refactor!: have a structured IndexOutOfBoundsError type (chaitika)

Pull request description:

  ### Description
  Fixes #267

  ### Notes to the reviewers
  I can rebase to master after #298 is merged to fix fmt errors.

  ### Changelog notice

  ```md
  Added
  - newtype `IndexOutOfBoundsError`

  Changed
  - `PolicyError::IndexOutOfRange` now wraps a `IndexOutOfBoundsError`
  - `SignerError::InputIndexOutOfRange` now wraps a `IndexOutOfBoundsError`
  ```

  ### Checklists

  #### All Submissions:

  * [X] I've signed all my commits
  * [X] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md)
  * [X] I ran `just p` before pushing

  #### New Features:

  * [ ] I've added tests for the new feature
  * [ ] I've added docs for the new feature

  #### Bugfixes:

  * [x] This pull request breaks the existing API
  * [ ] I've added tests to reproduce the issue which are now passing
  * [X] I'm linking the issue being fixed by this PR

ACKs for top commit:
  ValuedMammal:
    ACK 42d9b90

Tree-SHA512: 1ea31ff611f4ab03aba4b01ee898a3bbb2ef9393554408ccc5f70a2f04ec73e26b7654455e935537ef2c63d0cc5acf4330cfd964608462568d84f0b43147013a
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

3 participants