From 27e9a74e4e04bc5f1f37a8582a410343903e11e4 Mon Sep 17 00:00:00 2001 From: seahi Date: Wed, 17 Dec 2025 12:31:16 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E7=BE=8E=E5=8C=96=E9=94=99=E8=AF=AF?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.py | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 59 insertions(+), 1 deletion(-) diff --git a/app.py b/app.py index 5ee68a9..f066f28 100644 --- a/app.py +++ b/app.py @@ -32,7 +32,65 @@ THEMES = { def hello(): # 模拟 v3.0-buggy 的问题 if BUGGY and random.random() < 0.5: - return "💥 服务异常:数据库连接失败", 500 + return ( + f""" + + + + 服务异常 + + + + + +
+
💥
+
服务异常:数据库连接失败
+
版本: {VERSION}
+
主机: {socket.gethostname()}
+
学号: s{os.getenv("STUDENT_ID", "00")}
+
🔄 页面每3秒自动刷新
+
+ + + """, + 500, + ) theme = THEMES.get(VERSION, THEMES["v1.0"])