fix: price_monitor策略追踪conn未定义——止盈止损触发检查持续报错,修复后恢复SL/TP告警链路

This commit is contained in:
hmo
2026-07-29 03:33:58 +08:00
parent c9e7079ee6
commit 228c40c970
+3 -1
View File
@@ -776,7 +776,9 @@ def run_once(round_label=""):
# ── 策略追踪评估(2026-07-27 老爸:检查推荐是否触发止盈/止损)──
try:
import mofin_db
tracked = mofin_db.check_strategy_outcomes(conn)
_conn = mofin_db.get_conn()
tracked = mofin_db.check_strategy_outcomes(_conn)
_conn.close()
if tracked:
print(f" [TRACK] {tracked}条推荐触发止盈/止损", flush=True)
except Exception as e: