File tree Expand file tree Collapse file tree 1 file changed +4
-5
lines changed
lib/galaxy/tool_util/deps/mulled Expand file tree Collapse file tree 1 file changed +4
-5
lines changed Original file line number Diff line number Diff line change 88import sys
99import tarfile
1010import threading
11- import time
1211from io import BytesIO
1312
1413import packaging .version
@@ -293,21 +292,21 @@ def split_container_name(name):
293292class PrintProgress (object ):
294293 def __init__ (self ):
295294 self .thread = threading .Thread (target = self .progress )
296- self .stop = False
295+ self .stop = threading . Event ()
297296
298297 def progress (self ):
299- while not self .stop :
298+ while not self .stop . is_set () :
300299 print ("." , end = "" )
301300 sys .stdout .flush ()
302- time . sleep (60 )
301+ self . stop . wait (60 )
303302 print ("" )
304303
305304 def __enter__ (self ):
306305 self .thread .start ()
307306 return self
308307
309308 def __exit__ (self , exc_type , exc_val , exc_tb ):
310- self .stop = True
309+ self .stop . set ()
311310 self .thread .join ()
312311
313312
You can’t perform that action at this time.
0 commit comments