From cd4d8c3f2efb7ab292957e4d97a3c114c73af865 Mon Sep 17 00:00:00 2001 From: Chronial Date: Thu, 27 Mar 2014 15:14:53 +0100 Subject: [PATCH] Wait for output after snapraid commands --- snapraid-runner.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/snapraid-runner.py b/snapraid-runner.py index 062858c..bdf2931 100644 --- a/snapraid-runner.py +++ b/snapraid-runner.py @@ -7,6 +7,7 @@ import os.path import subprocess import sys import threading +import time import traceback from collections import Counter, defaultdict from cStringIO import StringIO @@ -55,6 +56,8 @@ def snapraid_command(command, args={}): for t in threads: t.join() ret = p.wait() + # sleep for a while to make pervent output mixup + time.sleep(0.3) if ret == 0: return out else: