feat(UI/Core): DB 디버거 팝업 리스트화, Optuna 적용 연동 및 Rust tail 코어 안정화

This commit is contained in:
Your Name
2026-09-03 02:29:30 +09:00
parent 93c6f711fa
commit ac1190f1fc
13 changed files with 529 additions and 34 deletions

View File

@@ -209,6 +209,7 @@ def load_breakout_ticks_by_code(
codes: Optional[Set[str]] = None,
*,
market: Optional[str] = None,
use_spill_fallback: bool = True,
) -> Tuple[Dict[str, Dict[str, List[Dict[str, Any]]]], int]:
"""
기간 내 체결 틱을 종목·분봉(YYYYMMDDHHMM) 단위로 로드.
@@ -322,9 +323,15 @@ def load_breakout_ticks_by_code(
for _mk, ticks in list(minutes.items()):
ticks.sort(key=lambda t: str(t.get("tick_time") or ""))
if mkt != "US":
filtered = merge_ticks_time_axis_fallback(ticks, main_src=main_src)
minutes[_mk] = filtered
kept += len(filtered)
if use_spill_fallback:
filtered = merge_ticks_time_axis_fallback(ticks, main_src=main_src)
minutes[_mk] = filtered
kept += len(filtered)
else:
# 스필 OFF: 메인 소스만 필터 없이 그냥 사용
filtered = [t for t in ticks if str(t.get("source") or "").strip().lower() == main_src]
minutes[_mk] = filtered if filtered else ticks # 메인이 없으면 보조라도 그대로 둠
kept += len(minutes[_mk])
else:
kept += len(ticks)
if kept != total:
@@ -335,8 +342,8 @@ def load_breakout_ticks_by_code(
raw_before_merge = total
total = kept
# 실매 3차 LS: 같은 초에 1·2차 없으면 ls_ws_ticks (나이=LIVE_FEED_FALLBACK, 기본 3초)
if mkt != "US" and get_env_bool("BT_TICK_LS_THIRD_FALLBACK", True):
# 실매 3차 LS: 스필 ON이고 같은 초에 1·2차 없으면 ls_ws_ticks
if use_spill_fallback and mkt != "US" and get_env_bool("BT_TICK_LS_THIRD_FALLBACK", True):
try:
from kis_trader.backtest.ls_history_loaders import load_ls_ticks_by_code