更新 monitor_web.py

Signed-off-by: zikai <1621362626@qq.com>
This commit is contained in:
2026-06-05 08:57:11 +00:00
parent 5e0eaa33fa
commit 276e24e830

View File

@@ -3073,15 +3073,15 @@ def main():
_start_monitor_if_ready()
server = ThreadedServer(('0.0.0.0', PORT), Handler)
server = ThreadedServer(('localhost', PORT), Handler)
print(f"=> http://localhost:{PORT}", flush=True)
print("Ctrl+C 停止\n", flush=True)
try:
import webbrowser
webbrowser.open(f'http://localhost:{PORT}')
except Exception:
pass
# try:
# import webbrowser
# webbrowser.open(f'http://localhost:{PORT}')
# except Exception:
# pass
try:
server.serve_forever()