From: Patrick Donnelly Date: Fri, 19 Apr 2024 03:31:07 +0000 (-0400) Subject: qa/tasks/vstart_runner: add missing poll method X-Git-Tag: v19.2.3~409^2~3 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=f5926935e4903bbd049c626a70cb30b470074ce7;p=ceph.git qa/tasks/vstart_runner: add missing poll method Otherwise you cannot use LocalDaemon.check_status. Signed-off-by: Patrick Donnelly (cherry picked from commit 9748d0c465f88a5118bf3c694fc5e33116229d12) --- diff --git a/qa/tasks/vstart_runner.py b/qa/tasks/vstart_runner.py index 4fcd0cfe1bb1..8e45b45d65d9 100644 --- a/qa/tasks/vstart_runner.py +++ b/qa/tasks/vstart_runner.py @@ -280,6 +280,16 @@ class LocalRemoteProcess(object): else: return False + def poll(self): + if self.finished: + if self.exitstatus is not None: + if self.check_status and self.exitstatus != 0: + raise CommandFailedError(self.args, self.exitstatus) + else: + return self.exitstatus + else: + return None + def kill(self): log.debug("kill ") if self.subproc.pid and not self.finished: