When a synch job fails and we stop other entries, set the host back to "Ready" if it was "Pending". Otherwise it'll sit in state "Pending" forever.
git-svn-id: http://test.kernel.org/svn/autotest/trunk@2385 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/scheduler/monitor_db.py b/scheduler/monitor_db.py
index 1c7f8d4..7b77f45 100644
--- a/scheduler/monitor_db.py
+++ b/scheduler/monitor_db.py
@@ -2160,6 +2160,8 @@
def stop_all_entries(self):
for child_entry in self.get_host_queue_entries():
if not child_entry.complete:
+ if child_entry.status == 'Pending':
+ child_entry.host.set_status('Ready')
child_entry.set_status('Stopped')