Commit Graph

1430 Commits

Author SHA1 Message Date
thesimplekid
2bd97e4d80 Merge pull request #928 from lollerfirst/new-secret-derivation
New Secret Derivation
2025-08-04 10:08:21 -04:00
thesimplekid
9ed8536cd0 Merge pull request #934 from thesimplekid/doc_tests
chore: stop test from running
2025-08-03 12:51:55 -04:00
thesimplekid
9f9c96577f chore: stop test from running 2025-08-03 10:14:43 -04:00
thesimplekid
d61a73d5bc docs(DEVELOPMENT.md): clarify Nix usage and add alternative setup instructions (#933) 2025-08-03 00:45:54 -04:00
lollerfirst
92eea181fd new secret derivation
Wallet holds `seed` instead of `xpriv`

fix doctest  errors

update examples

adjustments

fix doctests

fix all doctests

Update crates/cdk/src/wallet/multi_mint_wallet.rs

Co-authored-by: thesimplekid <tsk@thesimplekid.com>

fix

remove clone call
2025-08-02 19:36:20 +02:00
thesimplekid
4b8c8b08da docs(DEVELOPMENT.md): clarify Nix usage and add alternative setup instructions 2025-08-01 22:42:00 -04:00
thesimplekid
3c4fce5c45 feat: add keyset u32 mapping migration (#926)
* feat: add keyset u32 mapping migration and duplicate handling

- Add new database migration (version 3) to include u32 representation for keysets
- Implement migration for both redb and SQL databases
- Add duplicate detection and handling for keyset entries
- Create unique index constraint for keyset_u32 column in SQL
- Update keyset storage to include u32 identifiers
- Handle backwards compatibility for existing databases

* chore: clippy

* refactor(cashu): simplify keyset ID verification logic

- Consolidate match expression into a single expression
- Use direct comparison with ensure_cdk macro
- Improve readability of keyset ID validation

* refactor(cdk): rename `fetch_keyset_keys` to `load_keyset_keys` for clarity

- Renamed `fetch_keyset_keys` to `load_keyset_keys` across multiple modules to better reflect its behavior of loading keys from local storage or fetching from mint when missing.
- Added debug logging to indicate when keys are being fetched from the mint.
- Simplified key loading logic in `update_mint_keysets` by removing redundant existence checks.

* chore: remove unused vec
2025-07-31 10:04:38 -04:00
thesimplekid
3a3cd88ee9 Mintd lib (#914)
* feat(cdk-integration-tests): refactor regtest setup and mintd integration

- Replace shell-based regtest setup with Rust binary (start_regtest_mints)
- Add cdk-mintd crate to workspace and integration tests
- Improve environment variable handling for test configurations
- Update integration tests to use proper temp directory management
- Remove deprecated start_regtest.rs binary
- Enhance CLN client connection with retry logic
- Simplify regtest shell script (itests.sh) to use new binary
- Fix tracing filters and improve error handling in setup
- Update dependencies and configurations for integration tests

fix: killing

chore: comment tests for ci debugging

chore: compile

Revert "chore: comment tests for ci debugging"

This reverts commit bfc594c11cf37caeaa6445cb854ae5567d2da6bd.

* chore: sql cipher

* fix: removal of sqlite cipher

* fix: auth password

* refactor(cdk-mintd): improve database password handling and function signatures

- Pass database password as parameter instead of parsing CLI args in setup_database
- Update function signatures for run_mintd and run_mintd_with_shutdown to accept db_password
- Remove direct CLI parsing from database setup logic
- Fix auth database initialization to use correct type when sqlcipher feature enabled
2025-07-31 00:43:43 -04:00
thesimplekid
9e4b768657 Merge pull request #927 from thesimplekid/goose_in_ci
Goose changelog recipes
2025-07-30 23:56:13 -04:00
thesimplekid
dc19798201 feat(dev): add Goose recipes for changelog and commit message generation
- Add new Goose recipes for generating conventional commit messages and updating changelogs
- Include recipes for both staged changes and recent commits analysis
- Add convenient Just commands for running the new recipes
- Update README with usage instructions for the new recipes ([thesimplekid]).
2025-07-30 23:51:16 -04:00
David Caseria
6ebcbba0c4 refactor: update send functionality across wallet components (#925)
* refactor: update send functionality across wallet components

---------
Co-authored-by: thesimplekid <tsk@thesimplekid.com>
2025-07-30 23:37:41 -04:00
thesimplekid
f663a6e41c Merge pull request #923 from thesimplekid/debug_20_auth
feat(cdk): enable NUT-20 support in mint builder configuration
2025-07-30 20:27:49 -04:00
thesimplekid
cb30b092a5 Merge pull request #920 from vnprc/payment_method_unit_tests
test: add PaymentMethod parsing and db read/write tests
2025-07-30 10:20:06 -04:00
thesimplekid
b5fc4a17c3 fix: include axum in swagger 2025-07-30 10:07:22 -04:00
thesimplekid
9a784fbacd feat(cdk): enable NUT-20 support in mint builder configuration 2025-07-30 09:21:01 -04:00
thesimplekid
d8acf5e5ac chore: update change log (#921) 2025-07-29 22:24:25 -04:00
thesimplekid
c6f6eea1aa chore: update change log 2025-07-29 21:59:29 -04:00
C
8e0c44248b Add NUT-19 support in the wallet (#912)
* Add NUT-19 support in the wallet
2025-07-29 21:45:30 -04:00
thesimplekid
72887341ca Merge pull request #919 from crodas/fix/add-missing-migration
Add missing migrations for wallet and auth db
2025-07-29 21:41:55 -04:00
vnprc
714022fe14 test: add PaymentMethod parsing and db read/write tests 2025-07-29 21:41:45 -04:00
Cesar Rodas
ed7b64b71a Add missing migrations for wallet and auth db 2025-07-29 20:28:09 -03:00
C
f0af2121b2 Merge pull request #890 from crodas/feature/sql-base
Introduce `cdk-sql-common`
2025-07-29 17:03:32 -03:00
Cesar Rodas
0041c135f7 Fix get_mint_quote_by_request_lookup_id
Fixes #916

The two functions (read and transaction) got out of sync
2025-07-29 11:31:29 -03:00
Cesar Rodas
659518f241 Improve migrations
Add the namespaced migrations and global migrations
2025-07-29 11:31:29 -03:00
C
99ced01e67 Apply suggestions from code review
Co-authored-by: thesimplekid <tsk@thesimplekid.com>
2025-07-29 11:31:29 -03:00
Cesar Rodas
fb4c470a9a Rename still_active to stale 2025-07-29 11:31:29 -03:00
Cesar Rodas
1f85d0fd7a Changes
1. Fix migration to avoid re-running migration twice
2. Remove tokio dependency
2025-07-29 11:31:28 -03:00
Cesar Rodas
034af74013 Add Cache to SQL stmt
The cache will store the placeholders and if possible the RAW SQL with position
placeholders, to avoid repetitive computations
2025-07-29 11:31:28 -03:00
Cesar Rodas
349c773406 Introduce cdk-sql-common
The primary purpose of this new crate is to have a common and shared codebase
for all SQL storage systems. It would force us to write standard SQL using best
practices for all databases.

This crate has been extracted from #878
2025-07-29 11:31:23 -03:00
C
0b79121de4 Merge pull request #917 from crodas/bug/get_mint_quote_by_request_lookup_id
Fix `get_mint_quote_by_request_lookup_id`
2025-07-29 11:29:00 -03:00
Cesar Rodas
d14cfff8b8 Fix get_mint_quote_by_request_lookup_id
Fixes #916

The two functions (read and transaction) got out of sync
2025-07-28 22:30:25 -03:00
thesimplekid
db04537a34 Merge pull request #915 from BitcreditProtocol/peanut/transactionid_panic
TransactionId::from_hex check bytes len before copy_from_slice
2025-07-28 09:25:27 -04:00
codingpeanut157
29a2866326 TransactionId::from_hex check bytes len before copy_from_slice
avoid panicking when the input does not convert to an [u8;32] byte array
2025-07-28 12:24:03 +02:00
thesimplekid
e346ab638e Merge pull request #907 from thesimplekid/update_flake
refactor(flake): remove crane build system and simplify flake depende…
2025-07-27 07:29:51 -04:00
thesimplekid
735de32161 feat: sig all (#862)
* feat: swap sig all

* feat: melt sig all

* feat: swap and melt sig flag verify for mint

* feat: msg to sign tests
2025-07-26 09:51:28 -04:00
thesimplekid
fef1cda009 refactor(flake): remove crane build system and simplify flake dependencies
Remove crane and fenix dependencies along with their associated build
infrastructure. This simplifies the flake to focus on development
environments while removing package builds and applications.
2025-07-26 08:01:29 -04:00
thesimplekid
fb08e88457 Merge pull request #909 from thesimplekid/fix_unit_ser
fix(cashu): preserve original case for custom CurrencyUnit values
2025-07-24 16:59:33 +01:00
thesimplekid
0605eddf6f Merge pull request #910 from thesimplekid/flake_check_as_daily_check
refactor(ci): move flake check from CI to separate daily workflow
2025-07-24 09:18:09 +01:00
thesimplekid
4997af879a refactor(ci): move flake check from CI to separate daily workflow
Move Nix flake input checking from the main CI pipeline to a dedicated
daily scheduled workflow to reduce CI build time while maintaining
regular dependency monitoring.
2025-07-24 09:14:43 +01:00
thesimplekid
9df904648e fix(cashu): preserve original case for custom CurrencyUnit values
Custom currency units were incorrectly being converted to uppercase
during deserialization. This change ensures custom units maintain
their original case while still allowing case-insensitive matching
for standard units.
2025-07-24 09:00:06 +01:00
thesimplekid
7b2e31a3df Merge pull request #903 from thesimplekid/mint_start
feat(cdk): add mint lifecycle management with start/stop methods
2025-07-23 20:50:19 +01:00
thesimplekid
d2e9f1a626 Merge pull request #901 from thesimplekid/refresh_keys
feat: refactor wallet keyset management for better clarity
2025-07-23 20:49:42 +01:00
thesimplekid
af2762e5ef fix: waiting start stop tests 2025-07-23 15:58:47 +01:00
thesimplekid
8ab545ae44 Merge pull request #889 from gudnuf/fix/ws-melt-updates-include-change
fix: include change in melt quote state updates
2025-07-23 15:01:33 +01:00
lollerfirst
d07388d1ce refactor Nut10SecretRequest and add tests with provided test vectors (#900)
* refactor Nut10SecretRequest and add tests with provided test vectors
2025-07-23 14:55:27 +01:00
thesimplekid
6e0c3a3f7f feat(cdk): add mint lifecycle management with start/stop methods
- Add background service management with graceful shutdown handling
- Refactor invoice payment monitoring to use centralized task supervision
- Update cdk-mintd and integration tests to use new lifecycle methods
- Add comprehensive documentation and lifecycle tests
2025-07-23 13:38:20 +01:00
thesimplekid
49a05f410d Merge pull request #902 from thesimplekid/goose_recipe
feat(misc): add Goose AI recipes for automated changelog and git message
2025-07-23 08:45:26 +01:00
thesimplekid
7ee0fe0385 feat(misc): add Goose AI recipes for automated changelog and git message generation
- Add changelog-update.yaml recipe for analyzing staged changes and updating CHANGELOG.md
- Add git-commit-message.yaml recipe for creating conventional commit messages
- Add justfile commands (goose-changelog-update, goose-git-msg) for running recipes
- Update CHANGELOG.md with new recipe functionality entries
2025-07-22 23:54:09 +01:00
asmo
e639bd4021 fakewallet: convert sat to msat (#899) 2025-07-22 15:27:18 +02:00
David Caseria
f018465aa6 Refactor MintBuilder (#887)
* Refactor MintBuilder
* Validate azp instead of aud for client id
2025-07-19 18:13:11 +02:00