Skip to content

A Simple and Universal Swarm Intelligence Engine, Predicting Anything. 简洁通用的群体智能引擎,预测万物

Remove startup message logging from the Flask application in `run.py` to streamline output during server initialization. This change simplifies the code and reduces unnecessary console output, particularly in debug mode.

666ghj8d63f40b7138
diff --git a/backend/run.py b/backend/run.py
index 7f22ba8c..78e0ccf4 100644
--- a/backend/run.py
+++ b/backend/run.py
@@ -31,27 +31,6 @@ def main():
port = int(os.environ.get('FLASK_PORT', 5001))
debug = Config.DEBUG
- # 只在 reloader 子进程中打印启动信息(避免 debug 模式下打印两次)
- # WERKZEUG_RUN_MAIN=true 表示当前是 reloader 启动的子进程
- is_reloader_process = os.environ.get('WERKZEUG_RUN_MAIN') == 'true'
- if not debug or is_reloader_process:
- print(f"""
-╔══════════════════════════════════════════════════╗
-║ MiroFish Backend Server ║
-╠══════════════════════════════════════════════════╣
-║ Running on: http://{host}:{port} ║
-║ Debug mode: {debug} ║
-║ ║
-║ API Endpoints: ║
-║ POST /api/graph/ontology/generate - 生成本体 ║
-║ POST /api/graph/build - 构建图谱 ║
-║ GET /api/graph/task/<task_id> - 查询任务 ║
-║ GET /api/graph/tasks - 列出任务 ║
-║ GET /api/graph/data/<graph_id> - 获取图数据║
-║ DELETE /api/graph/delete/<graph_id>- 删除图谱 ║
-╚══════════════════════════════════════════════════╝
- """)
-
# 启动服务
app.run(host=host, port=port, debug=debug, threaded=True)