Skip to content

feat(ffi): expose mint_unissued_quotes#2201

Merged
thesimplekid merged 1 commit into
cashubtc:mainfrom
j-kon:feat/ffi-mint-unissued-quotes
Jul 8, 2026
Merged

feat(ffi): expose mint_unissued_quotes#2201
thesimplekid merged 1 commit into
cashubtc:mainfrom
j-kon:feat/ffi-mint-unissued-quotes

Conversation

@j-kon

@j-kon j-kon commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR exposes the existing CDK wallet mint_unissued_quotes method through the FFI Wallet.

The core Rust wallet already supports minting paid but unissued mint quotes as part of startup/recovery flows. Exposing this method through cdk-ffi makes the same capability available to generated bindings such as Dart.

Changes

  • Add Wallet::mint_unissued_quotes to crates/cdk-ffi
  • Convert the core return value into the correct FFI-compatible type
  • Generated binding outputs are not committed in this PR because the monorepo does not currently track the generated Dart file.

Testing

  • cargo fmt
  • cargo test -p cdk-ffi

@github-project-automation github-project-automation Bot moved this to Backlog in CDK Jul 4, 2026
@codecov

codecov Bot commented Jul 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.11%. Comparing base (ba17883) to head (c6957ac).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2201      +/-   ##
==========================================
+ Coverage   73.00%   73.11%   +0.11%     
==========================================
  Files         359      359              
  Lines       79608    79639      +31     
==========================================
+ Hits        58114    58232     +118     
+ Misses      21494    21407      -87     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@j-kon j-kon force-pushed the feat/ffi-mint-unissued-quotes branch 2 times, most recently from 87465e5 to 92b7d63 Compare July 4, 2026 22:33
@j-kon

j-kon commented Jul 4, 2026

Copy link
Copy Markdown
Contributor Author

@cdk-bot review

@thesimplekid

Copy link
Copy Markdown
Collaborator

This is missing from the trait I guess if it wasn't forced to be exported on the FFI so should add it there.

@j-kon j-kon force-pushed the feat/ffi-mint-unissued-quotes branch from 92b7d63 to 220c2a0 Compare July 7, 2026 10:15
@j-kon

j-kon commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

Addressed this by adding mint_unissued_quotes to cdk_common::wallet::Wallet, then forwarding it in both the core Wallet trait implementation and the FFI Wallet trait implementation. I also added a small FFI test that calls both the concrete wallet method and the trait method against an empty in-memory store.

crodas
crodas previously approved these changes Jul 7, 2026
@thesimplekid thesimplekid added this to the 0.18.0 milestone Jul 8, 2026
@thesimplekid thesimplekid force-pushed the feat/ffi-mint-unissued-quotes branch 2 times, most recently from db8a9f9 to 69e04b9 Compare July 8, 2026 10:05
thesimplekid
thesimplekid previously approved these changes Jul 8, 2026
@github-project-automation github-project-automation Bot moved this from Backlog to Todo in CDK Jul 8, 2026
@thesimplekid thesimplekid dismissed stale reviews from crodas and themself via c6957ac July 8, 2026 10:09
@thesimplekid thesimplekid force-pushed the feat/ffi-mint-unissued-quotes branch from 69e04b9 to c6957ac Compare July 8, 2026 10:09
@thesimplekid thesimplekid merged commit c6957ac into cashubtc:main Jul 8, 2026
@github-project-automation github-project-automation Bot moved this from Todo to Done in CDK Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants