mirror of
https://github.com/markqvist/Reticulum.git
synced 2024-10-01 03:15:44 -04:00
Fixed request packet receipts timing out in spite of delivery.
This commit is contained in:
parent
cdb08325cc
commit
781cb4712d
@ -440,7 +440,7 @@ class PacketReceipt:
|
|||||||
return (self.sent_at+self.timeout < time.time())
|
return (self.sent_at+self.timeout < time.time())
|
||||||
|
|
||||||
def check_timeout(self):
|
def check_timeout(self):
|
||||||
if self.is_timed_out():
|
if self.status == PacketReceipt.SENT and self.is_timed_out():
|
||||||
if self.timeout == -1:
|
if self.timeout == -1:
|
||||||
self.status = PacketReceipt.CULLED
|
self.status = PacketReceipt.CULLED
|
||||||
else:
|
else:
|
||||||
|
@ -864,6 +864,9 @@ class Transport:
|
|||||||
if receipt.hash == proof_hash:
|
if receipt.hash == proof_hash:
|
||||||
receipt_validated = receipt.validate_proof_packet(packet)
|
receipt_validated = receipt.validate_proof_packet(packet)
|
||||||
else:
|
else:
|
||||||
|
# TODO: This looks like it should actually
|
||||||
|
# be rewritten when implicit proofs are added.
|
||||||
|
|
||||||
# In case of an implicit proof, we have
|
# In case of an implicit proof, we have
|
||||||
# to check every single outstanding receipt
|
# to check every single outstanding receipt
|
||||||
receipt_validated = receipt.validate_proof_packet(packet)
|
receipt_validated = receipt.validate_proof_packet(packet)
|
||||||
|
Loading…
Reference in New Issue
Block a user