From 48ac46bbb30c317508609d5d167f1073a0700643 Mon Sep 17 00:00:00 2001 From: Snowykami Date: Mon, 9 Dec 2024 00:26:16 +0800 Subject: [PATCH] =?UTF-8?q?:sparkles:=20=E5=A2=9E=E5=8A=A0=E5=AE=A2?= =?UTF-8?q?=E6=88=B7=E7=AB=AF=E5=90=AF=E5=8A=A8=E6=97=A5=E5=BF=97=E5=B9=B6?= =?UTF-8?q?=E4=BC=98=E5=8C=96=E7=BA=BF=E7=A8=8B=E5=90=AF=E5=8A=A8=E9=80=BB?= =?UTF-8?q?=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server_status/api.py | 4 ++++ server_status/cmd_parser.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/server_status/api.py b/server_status/api.py index 4e09764..03aed92 100644 --- a/server_status/api.py +++ b/server_status/api.py @@ -191,8 +191,12 @@ class Client: ) def start(self): + log("Starting client") threading.Thread(target=self._start_obs, daemon=True).start() threading.Thread(target=self._start_post, daemon=True).start() + + while True: + time.sleep(1) def _start_obs(self): """启动监控记录线程""" diff --git a/server_status/cmd_parser.py b/server_status/cmd_parser.py index bfde61e..cb67904 100644 --- a/server_status/cmd_parser.py +++ b/server_status/cmd_parser.py @@ -3,7 +3,7 @@ import socket from arclet.alconna import Alconna, Subcommand, Option, Args, MultiVar -server_status_alc = Alconna( +server_status_alc = Alconna( # type: ignore "server_status", Args["server", str]["token", str]["id", str], Subcommand(