feat: 完善 QMT 交易模块文档和配置展示功能
- 优化前端仪表盘界面 - 添加配置文件可视化展示 - 编写 QMT 模块配置文档 - 完善项目规则体系(KiloCode)
This commit is contained in:
11
qmt/run.py
11
qmt/run.py
@@ -64,6 +64,17 @@ def main():
|
||||
print("\n>>> Shutdown signal received. Closing terminals...")
|
||||
manager.stop()
|
||||
print(">>> System safely closed.")
|
||||
_write_exit_code(0)
|
||||
sys.exit(0)
|
||||
|
||||
def _write_exit_code(code):
|
||||
"""将退出码写入临时文件,供 start.bat 读取"""
|
||||
try:
|
||||
exit_code_file = os.path.join(os.environ.get('TEMP', ''), 'exit_code.txt')
|
||||
with open(exit_code_file, 'w') as f:
|
||||
f.write(str(code))
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
if __name__ == '__main__':
|
||||
# 最佳实践:使用 python -u run.py 运行以获得实时日志输出
|
||||
|
||||
Reference in New Issue
Block a user