Browse Source

for now, use PR_PAID for onchain unconfirmed

dependabot/pip/contrib/deterministic-build/ecdsa-0.13.3
ThomasV 5 years ago
parent
commit
466c2bd293
  1. 6
      electrum/daemon.py
  2. 2
      electrum/wallet.py

6
electrum/daemon.py

@ -180,9 +180,9 @@ class HttpServer(Logger):
self.pending = defaultdict(asyncio.Event) self.pending = defaultdict(asyncio.Event)
self.daemon.network.register_callback(self.on_payment, ['payment_received']) self.daemon.network.register_callback(self.on_payment, ['payment_received'])
async def on_payment(self, evt, *args): async def on_payment(self, evt, wallet, key, status):
print(evt, args) if status == PR_PAID:
#await self.pending[key].set() await self.pending[key].set()
async def run(self): async def run(self):
host = self.config.get('http_host', 'localhost') host = self.config.get('http_host', 'localhost')

2
electrum/wallet.py

@ -1317,7 +1317,7 @@ class Abstract_Wallet(AddressSynchronizer):
else: else:
status = PR_UNPAID status = PR_UNPAID
else: else:
status = PR_INFLIGHT if conf <= 0 else PR_PAID status = PR_PAID
return status, conf return status, conf
def get_request(self, key): def get_request(self, key):

Loading…
Cancel
Save