Skip to content

Commit

Permalink
[batch-] sync should not wait for outputProgress Thread
Browse files Browse the repository at this point in the history
  • Loading branch information
anjakefala committed Oct 8, 2023
1 parent edc81be commit 60d6f22
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion visidata/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ def main_vd():
vs = eval_vd(vdfile, *fmtargs, **fmtkwargs)
vd.sync(vs.reload())
if args.batch:
visidata.VisiData.execAsync(vd, vd.outputProgressEvery, vs, seconds=0.5, sheet=BaseSheet()) #1182
vd.outputProgressThread = visidata.VisiData.execAsync(vd, vd.outputProgressEvery, vs, seconds=0.5, sheet=BaseSheet()) #1182
if vd.replay_sync(vs): # error
return 1

Expand Down
2 changes: 1 addition & 1 deletion visidata/threads.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ def sync(self, *joiningThreads):
while True:
deads = set() # dead threads
threads = joiningThreads or set(self.unfinishedThreads)
threads -= set([threading.current_thread(), getattr(vd, 'drawThread', None)])
threads -= set([threading.current_thread(), getattr(vd, 'drawThread', None), getattr(vd, 'outputProgressThread', None)])
threads -= deads
threads -= set([None])
for t in threads:
Expand Down

0 comments on commit 60d6f22

Please sign in to comment.