mirror of
https://github.com/RoboSats/robosats.git
synced 2024-12-13 19:06:26 +00:00
Do not watch all locked invoices in follow-invoices
This commit is contained in:
parent
66f1a68963
commit
547a7212a0
@ -58,15 +58,15 @@ class Command(BaseCommand):
|
|||||||
LND Background: SubscribeInvoices stub iterator would be great to use here.
|
LND Background: SubscribeInvoices stub iterator would be great to use here.
|
||||||
However, it only sends updates when the invoice is OPEN (new) or SETTLED.
|
However, it only sends updates when the invoice is OPEN (new) or SETTLED.
|
||||||
We are very interested on the other two states (CANCELLED and ACCEPTED).
|
We are very interested on the other two states (CANCELLED and ACCEPTED).
|
||||||
Therefore, this thread (follow_invoices) will iterate over all LNpayment
|
Therefore, this thread (follow_invoices) will iterate over all LNpayments in
|
||||||
objects and do InvoiceLookupV2 every X seconds to update their state 'live'
|
INVGEN status and do InvoiceLookupV2 every X seconds to update their status.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
# time it for debugging
|
# time it for debugging
|
||||||
t0 = time.time()
|
t0 = time.time()
|
||||||
queryset = LNPayment.objects.filter(
|
queryset = LNPayment.objects.filter(
|
||||||
type=LNPayment.Types.HOLD,
|
type=LNPayment.Types.HOLD,
|
||||||
status__in=[LNPayment.Status.INVGEN, LNPayment.Status.LOCKED],
|
status=LNPayment.Status.INVGEN,
|
||||||
)
|
)
|
||||||
|
|
||||||
debug = {}
|
debug = {}
|
||||||
|
Loading…
Reference in New Issue
Block a user