From d8bd16e6b95dd9dfb632d6f9cc94eea9dead40d6 Mon Sep 17 00:00:00 2001 From: TPTBusiness Date: Wed, 29 Apr 2026 21:23:02 +0200 Subject: [PATCH] fix(security): real fix for B110 (logging in factor_proposal.py #746) --- rdagent/scenarios/qlib/proposal/factor_proposal.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/rdagent/scenarios/qlib/proposal/factor_proposal.py b/rdagent/scenarios/qlib/proposal/factor_proposal.py index fa8bda9c..4e4391e7 100644 --- a/rdagent/scenarios/qlib/proposal/factor_proposal.py +++ b/rdagent/scenarios/qlib/proposal/factor_proposal.py @@ -1,3 +1,4 @@ +import logging import json import os from typing import List, Tuple @@ -38,7 +39,7 @@ def _build_compressed_history(trace: Trace, max_history: int) -> str: if exp.result is not None and "IC" in exp.result.index: ic_str = f" IC={exp.result.loc['IC']:.4f}" except Exception: - pass + logging.debug("Exception caught", exc_info=True) decision = "PASS" if fb.decision else "FAIL" obs = (fb.observations or "")[:120].replace("\n", " ") lines.append(f"- [{decision}]{ic_str} {', '.join(names) or 'unknown'}: {obs}")