Mint: Recover pending melts at startup (#499)

* wip works with fakewallet

* startup refactor

* add tests

* regtest tests for pending melts

* wip CLN

* remove db migration

* remove foreign key relation to keyset id

* fix: get_promise from db and restore DLEQs

* test: check for keyset not found error

* fix migrations

* lower-case all db column names

* add more tests for regtest

* simlate failure for lightning

* test wallet spent state with hodl invoices

* retry

* regtest with postgres

* retry postgres

* add sleeps

* longer sleep on github

* more sleep for github sigh

* increase sleep ffs

* add sleep loop

* try something

* do not pay with wallet but with ledger

* fix lnbits pending state

* fix pipeline to use fake admin from docker
This commit is contained in:
callebtc
2024-04-03 17:14:21 +02:00
committed by GitHub
parent 1f1daca232
commit b8ad0e0a8f
23 changed files with 868 additions and 177 deletions

View File

@@ -94,9 +94,7 @@ def mint():
async def ledger():
async def start_mint_init(ledger: Ledger):
await migrate_databases(ledger.db, migrations_mint)
if settings.mint_cache_secrets:
await ledger.load_used_proofs()
await ledger.init_keysets()
await ledger.startup_ledger()
if not settings.mint_database.startswith("postgres"):
# clear sqlite database