feat: 운영 시작 시 누락 봉 증분 동기화 및 B-1 실거래 설정

05/06 시작 전 ops_sync로 지연 간격만 증분 보완하고, Phase B-1 live env·ncue 실행 래퍼를 반영한다.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
dsyoon
2026-06-03 13:46:59 +01:00
parent 1fc560744d
commit a16c942be4
14 changed files with 301 additions and 14 deletions

24
scripts/00_sync_ops.py Normal file
View File

@@ -0,0 +1,24 @@
#!/usr/bin/env python3
"""운영 전 누락 봉 증분 보완 (05/06 시작 시 자동 호출과 동일)."""
import argparse
import runpy
from pathlib import Path
runpy.run_path(str(Path(__file__).resolve().parent / "_bootstrap.py"))
from deepcoin.data.ops_sync import ensure_ops_candles
if __name__ == "__main__":
parser = argparse.ArgumentParser(description="운영 전 coins.db 누락 봉 동기화")
parser.add_argument(
"--force",
action="store_true",
help="최신 간격도 전부 재수집",
)
parser.add_argument(
"--verbose",
action="store_true",
help="API 수집 진행 로그 출력",
)
args = parser.parse_args()
ensure_ops_candles(force=args.force, verbose_download=args.verbose)

20
scripts/run.ps1 Normal file
View File

@@ -0,0 +1,20 @@
# DeepCoin CLI wrapper — conda 환경 ncue 고정
# 사용: .\scripts\run.ps1 06_execute_live.py --once
param(
[Parameter(Mandatory = $true, Position = 0)]
[string]$Script,
[Parameter(ValueFromRemainingArguments = $true)]
[string[]]$Rest
)
$ErrorActionPreference = "Stop"
$root = Split-Path $PSScriptRoot -Parent
Set-Location $root
$env:PYTHONUNBUFFERED = "1"
$scriptPath = Join-Path $root "scripts" $Script
if (-not (Test-Path $scriptPath)) {
throw "스크립트 없음: $scriptPath"
}
& conda run -n ncue --no-capture-output python $scriptPath @Rest