From 6a27ac97b2fa4b5e9d4beefe9a1a4ef3d9de814c Mon Sep 17 00:00:00 2001 From: xiaxinyue Date: Thu, 20 Nov 2025 03:25:02 +0000 Subject: [PATCH] =?UTF-8?q?update=20libs/locallibs/sleep=5Fwait.py.=20?= =?UTF-8?q?=E4=BF=AE=E5=A4=8Dsleep=5Fwait=20mode2=E6=A8=A1=E5=BC=8F?= =?UTF-8?q?=EF=BC=9A=E6=A3=80=E6=9F=A5=E5=A4=B1=E8=B4=A5=E6=97=B6=E6=9C=AA?= =?UTF-8?q?=E8=BF=94=E5=9B=9E=E9=9D=9E0=E5=80=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: xiaxinyue --- libs/locallibs/sleep_wait.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libs/locallibs/sleep_wait.py b/libs/locallibs/sleep_wait.py index 8914f33f8..d1f162a96 100644 --- a/libs/locallibs/sleep_wait.py +++ b/libs/locallibs/sleep_wait.py @@ -71,6 +71,7 @@ def sleep_wait(wait_time, cmd=None, mode=1): if cmd and mode == 2: init = 0 while init < wait_time: + init += 1 time.sleep(1) exitcode, output = subprocess.getstatusoutput(cmd) if exitcode == 0: @@ -79,8 +80,6 @@ def sleep_wait(wait_time, cmd=None, mode=1): elif init == wait_time: sys.exit(exitcode) - init += 1 - if __name__ == "__main__": parser = argparse.ArgumentParser(description="manual to this script") -- Gitee