Browse Source

joining of threads broke the tests

Ask Solem 14 years ago
parent
commit
f2911e4a5d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      celery/worker/heartbeat.py

+ 2 - 1
celery/worker/heartbeat.py

@@ -58,4 +58,5 @@ class Heart(threading.Thread):
         self._state = "CLOSE"
         self._shutdown.set()
         self._stopped.wait() # block until this thread is done
-        self.join(1e100)
+        if self.isAlive():
+            self.join(1e100)