Mint: watchdog balance log and killswitch (#705)

* wip store balance

* store balances in watchdog worker

* move mint_auth_database setting

* auth db

* balances returned as Amount (instead of int)

* add test for balance change on invoice receive

* fix 1 test

* cancel tasks on shutdown

* watchdog can now abort

* remove wallet api server

* fix lndgrpc

* fix lnbits balance

* disable watchdog

* balance lnbits msat

* test db watcher with its own database connection

* init superclass only once

* wip: log balance in keysets table

* check max balance using new keyset balance

* fix test

* fix another test

* store fees in keysets

* format

* cleanup

* shorter

* add keyset migration to auth server

* fix fakewallet

* fix db tests

* fix postgres problems during migration 26 (mint)

* fix cln

* ledger

* working with pending

* super fast watchdog, errors

* test new pipeline

* delete walletapi

* delete unneeded files

* revert workflows
This commit is contained in:
callebtc
2025-05-11 20:29:13 +02:00
committed by GitHub
parent 38bdb9ce76
commit fc0e3fe663
41 changed files with 938 additions and 960 deletions

View File

@@ -23,7 +23,7 @@ from ..helpers import (
async def print_balance(ctx: Context):
wallet: Wallet = ctx.obj["WALLET"]
await wallet.load_proofs(reload=True)
print(f"Balance: {wallet.unit.str(wallet.available_balance)}")
print(f"Balance: {wallet.available_balance}")
async def get_unit_wallet(ctx: Context, force_select: bool = False):