Files
trex-core/docs/batches/bat-029_20260610_asset-keyed-intent-and-divergence/verification.md
T
genichinandClaude Opus 4.8 78a743a2ef feat(slot): BAT-029 M2(a)/M3 — holding 불일치 reconcile + slots 단일 뷰 (dcy-020/REQ-062·063)
- REQ-062 divergence: list_holding_slots(protocol+in_memory+PG) +
  reconcile_core_holdings(A=코어 holding/broker0→error, C=수량 불일치→warning,
  B=broker 보유/코어 없음→warning; 자동 청산 없음 issue #15). snapshot_scheduler
  자산 중심 모드에서 best-effort 호출, daemon slot_service 배선.
- REQ-063: slot_to_dict 에 universe_detached(retired_at) 추가 — slots 단일 뷰 tombstone 표시.
- 신규 테스트: test_holding_divergence(4).

M2(b) 청산 수량 브로커 정본(execution dispatch)은 라이브 집행 변경 → BAT-δ carry-over.

검증: 단위 393 passed / 36 skipped, PG-gated 18 passed, ruff clean. legacy 무파손.
REQ-061/062/063 Approved 유지(γ 경로 도입 검증; default 전환·M2(b) 는 BAT-δ).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-10 12:18:56 +09:00

2.3 KiB
Raw Blame History

BAT-029 Verification

  • Status: verified (배치 범위; M2(b) BAT-δ 이월)
  • Batch: BAT-029

Acceptance Mapping

REQ-061 (intent 계약 slot_id)

AC 상태 Evidence
매수 slot_id 활성화 + symbol 슬롯 resolve ✅ test_activates_by_slot_id
이미 활성 → already_active ✅ test_already_active_is_rejected
보유 아닌 슬롯 매도 거부 ✅ 기존 sell(_admit_sell slot_not_holding) 회귀
레거시 portfolio_id dual-accept ✅ test_activates_asset_slot(portfolio_id)
intent_id 멱등 ✅ 기존 intent dedup 회귀

REQ-062 (수량/불일치 해소)

AC 상태 Evidence
A 코어 holding/broker 0 → error ✅ test_A_core_holding_broker_flat_goes_error
B 코어 flat/broker 보유 → warning ✅ test_B_broker_holds_unmanaged_warns
C 수량만 → 미러 갱신/warning(상태 불변) ✅ test_C_qty_mismatch_warns_no_state_change
청산 수량 = 브로커 정본 ⏳ 이월(BAT-δ) execution dispatch qty 변경은 라이브 집행 — cutover 게이트

REQ-063 (운영자 slots 단일 뷰)

AC 상태 Evidence
slots 자산 포지션 단일 뷰 ✅ slot_to_dict(기존 envelope)
universe_detached(tombstone/soft-retire) 표시 ✅ slot_to_dict universe_detached + 회귀

Evidence

  • 단위 전체: 393 passed / 36 skipped / 1 deselected. ruff clean.
  • PG-gated(실 trex_core_test): persistence 18 passed(list_holding_slots·reconcile·드리프트 포함).

Carried-Over

  • REQ-062 청산 수량 브로커 정본: execution dispatch 매도 수량(int(slot.qty)) → 브로커 잔고 정본 변경은 라이브 집행 동작 → BAT-δ(cutover, 자산 중심 default 전환)와 같은 게이트.
  • sell slot_id 완전 폐기·literal inactive·컬럼 drop·자산 중심 default → BAT-δ.
  • 실 데몬 자산 중심 e2e(reconcile→slot_id 매수→divergence) run-the-app → BAT-δ confirm-release 전.
  • 따라서 REQ-061/062/063 은 본 배치에서 Approved 유지(경로 동작 검증; 전체 완성·default 전환은 BAT-δ).

Result

  • Ready for Release: false (dcy-020 전체 미완 — γ 경로 도입 완료, M2(b)·default 는 BAT-δ)
  • Blocking Issues: 없음(단위 393 + PG 18 green, legacy 무파손).