Skip to content

Instantly share code, notes, and snippets.

@cachedout
Created December 5, 2013 20:15
Show Gist options
  • Save cachedout/7813079 to your computer and use it in GitHub Desktop.
Save cachedout/7813079 to your computer and use it in GitHub Desktop.
Index: salt/client/__init__.py
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- salt/client/__init__.py (date 1386195501000)
+++ salt/client/__init__.py (revision )
@@ -1028,6 +1028,7 @@
yield {}
# Wait for the hosts to check in
syndic_wait = 0
+ jinfo_previous = {}
while True:
raw = self.event.get_event(timeout, jid)
if raw is not None:
@@ -1072,12 +1073,13 @@
jinfo = self.gather_job_info(jid, tgt, tgt_type, **kwargs)
more_time = False
for id_ in jinfo:
- if jinfo[id_]:
+ if jinfo[id_] or jinfo_previous[id_]:
if verbose:
print(
'Execution is still running on {0}'.format(id_)
)
more_time = True
+ jinfo_previous = jinfo
if more_time:
timeout += inc_timeout
continue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment