mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2025-03-13 19:37:42 +01:00
show progress (#987)
This commit is contained in:
parent
3bf3c91007
commit
d1302e4868
1 changed files with 2 additions and 2 deletions
|
@ -333,7 +333,7 @@ async def delete_expired_invoices(
|
||||||
"""
|
"""
|
||||||
)
|
)
|
||||||
logger.debug(f"Checking expiry of {len(rows)} invoices")
|
logger.debug(f"Checking expiry of {len(rows)} invoices")
|
||||||
for (payment_request,) in rows:
|
for i, (payment_request,) in enumerate(rows):
|
||||||
try:
|
try:
|
||||||
invoice = bolt11.decode(payment_request)
|
invoice = bolt11.decode(payment_request)
|
||||||
except:
|
except:
|
||||||
|
@ -343,7 +343,7 @@ async def delete_expired_invoices(
|
||||||
if expiration_date > datetime.datetime.utcnow():
|
if expiration_date > datetime.datetime.utcnow():
|
||||||
continue
|
continue
|
||||||
logger.debug(
|
logger.debug(
|
||||||
f"Deleting expired invoice: {invoice.payment_hash} (expired: {expiration_date})"
|
f"Deleting expired invoice {i}/{len(rows)}: {invoice.payment_hash} (expired: {expiration_date})"
|
||||||
)
|
)
|
||||||
await (conn or db).execute(
|
await (conn or db).execute(
|
||||||
"""
|
"""
|
||||||
|
|
Loading…
Add table
Reference in a new issue