From 585b56cd2b0c6d0b823ccc61734b70dca350c893 Mon Sep 17 00:00:00 2001 From: Peter Surda Date: Thu, 3 Jan 2019 08:13:15 +0100 Subject: [PATCH] Fix logic - thanks @g1itch! --- src/randomtrackingdict.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/randomtrackingdict.py b/src/randomtrackingdict.py index c58a0194..6c3300ab 100644 --- a/src/randomtrackingdict.py +++ b/src/randomtrackingdict.py @@ -109,7 +109,7 @@ class RandomTrackingDict(object): with self.lock: # reset if we've requested all # and if last object received too long time ago - if self.pendingLen == self.len and self.lastObject + self.pendingTimeout > time(): + if self.pendingLen == self.len and self.lastObject + self.pendingTimeout < time(): self.pendingLen = 0 self.setLastObject() available = self.len - self.pendingLen