From b89d61b80a7e94762b63748553beee8854d22816 Mon Sep 17 00:00:00 2001 From: Cryp Toon Date: Fri, 14 Jun 2024 20:47:07 +0200 Subject: [PATCH] Fix issue with unconfirmed txs in Service class --- bitcoinlib/services/services.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bitcoinlib/services/services.py b/bitcoinlib/services/services.py index 82d96d4f..48b6cc79 100644 --- a/bitcoinlib/services/services.py +++ b/bitcoinlib/services/services.py @@ -374,7 +374,7 @@ def gettransactions(self, address, after_txid='', limit=MAX_TRANSACTIONS): if txs is False: raise ServiceError("Error when retrieving transactions from service provider") for tx in txs: - if not tx.date.tzinfo: + if tx.date and not tx.date.tzinfo: tx.date = tx.date.replace(tzinfo=timezone.utc) # Store transactions and address in cache