[GAP-030]: ORB hydration verification complete
- tests/NT8.Core.Tests/Strategies/SimpleORBHydrationTests.cs: cover full and partial delivered-bar ORB hydration - tests/NT8.Core.Tests/Adapters/NT8StrategyBaseHistoricalGuardTests.cs: assert historical bars reach SDK hydration and orders are blocked before submission - SPRINT_BOARD.md: GAP-030 prompted -> implemented/deployed - docs/00-governance/current_status.md: record GAP-030 test-only outcome - docs/00-governance/decisions.md: record DEC-20260826-06 Build: clean | Tests: 576 passing | Dual-deployed: yes, backup 20260826_010653
This commit is contained in:
@@ -1,5 +1,13 @@
|
||||
# Current Status — NT8 SDK
|
||||
**Last Updated:** 2026-08-26 (GAP-025 implemented; GAP-030 next)
|
||||
**Last Updated:** 2026-08-26 (GAP-030 implemented/deployed test-only)
|
||||
|
||||
---
|
||||
|
||||
## 2026-08-26 — GAP-030 verified; repo-side fix is test coverage only
|
||||
|
||||
Implemented `TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md` as a verify-first, test-only task. The source trace checked out: `SimpleORBStrategy.OnBar()` has no historical/realtime state input and builds the ORB range from every delivered in-window bar; `NT8StrategyBase.OnBarUpdate()` does not block `State.Historical` bars before `_sdkStrategy.OnBar()`; `ProcessStrategyIntent()` retains the live-account `State == State.Historical && Account != null` guard before portfolio risk, sizing, and submission. No production hydration logic was added.
|
||||
|
||||
Added tests proving full-window replay hydrates `_openingRangeHigh`/`_openingRangeLow` and marks `OpeningRangeReady` on the first post-window bar, partial-window delivered bars hydrate from the bars actually delivered, `OnBarUpdate()` does not contain an executable pre-`OnBar` historical block, and `ProcessStrategyIntent()` keeps the `HistoricalReplayCatchup` order-submission guard. Focused GAP-030 tests passed 4/4; `verify-build.bat` passed 576/576. Deploy completed with backup `20260826_010653`; `NinjaTrader.Custom.dll` was already absent. External NT8 docs fetched during the task did not prove whether a late enable always receives same-day historical bars, so that platform behavior remains an operator observation point rather than a source-code defect.
|
||||
|
||||
---
|
||||
|
||||
|
||||
@@ -13,6 +13,29 @@ Use this file to record durable project decisions that affect implementation pat
|
||||
|
||||
## Decision Log
|
||||
|
||||
### DEC-20260826-06
|
||||
- **ID:** DEC-20260826-06
|
||||
- **Date:** 2026-08-26
|
||||
- **Status:** implemented — test-only repo change, deployed by operator request
|
||||
- **Context:** GAP-030 asked whether late strategy enable correctly hydrates the current day's ORB range from historical bars and prevents live-account orders from historical catch-up bars. Source verification confirmed the repo-side trace from `DEC-20260826-03`: Core `SimpleORBStrategy` cannot distinguish historical from realtime because `StrategyContext` has no such field, `UpdateOpeningRange()` accumulates from any delivered in-window `BarData`, `NT8StrategyBase.OnBarUpdate()` does not block `State.Historical` bars before `_sdkStrategy.OnBar()`, and `ProcessStrategyIntent()` blocks `State == State.Historical && Account != null` before risk/sizing/submission. Fetched NT8 `OnBarUpdate()` documentation did not expose enough body text to prove whether late enable always receives same-day historical catch-up bars, so that platform-delivery assumption remains an operator observation point.
|
||||
- **Decision:** Do not add redundant production hydration logic. Close the repo-side coverage gap with tests proving the existing behavior and guard placement.
|
||||
- **Proof:** Added `SimpleORBHydrationTests` proving full-window delivered bars hydrate the expected ORB high/low and mark `OpeningRangeReady` on the first post-window bar, and partial-window delivered bars hydrate from the bars actually delivered. Added `NT8StrategyBaseHistoricalGuardTests` proving `OnBarUpdate()` has no executable pre-`_sdkStrategy.OnBar()` `State.Historical` block and `ProcessStrategyIntent()` still contains the `HistoricalReplayCatchup` live-account guard before portfolio risk and order submission.
|
||||
- **Verification:** `dotnet test tests\NT8.Core.Tests\NT8.Core.Tests.csproj --configuration Release --filter "FullyQualifiedName~SimpleORBHydration|FullyQualifiedName~NT8StrategyBaseHistoricalGuard" --verbosity minimal` passed 4/4. `verify-build.bat` passed 576/576. Deploy completed with backup `20260826_010653`; `NinjaTrader.Custom.dll` was already absent.
|
||||
- **Related Files:** `TASK_GAP030_ORB_HYDRATION_VERIFY_PROMPT.md`, `tests/NT8.Core.Tests/Strategies/SimpleORBHydrationTests.cs`, `tests/NT8.Core.Tests/Adapters/NT8StrategyBaseHistoricalGuardTests.cs`, `src/NT8.Strategies/Examples/SimpleORBStrategy.cs`, `src/NT8.Adapters/Strategies/NT8StrategyBase.cs`, `SPRINT_BOARD.md`, `docs/00-governance/current_status.md`.
|
||||
- **Action Required:** Manual NinjaScript compile after deploy. On the next SIM late-enable check, confirm whether NT8 delivers same-day ORB-window historical bars as expected; if it does not, stage a new production fix based on that observed platform behavior.
|
||||
|
||||
### DEC-20260826-05
|
||||
- **ID:** DEC-20260826-05
|
||||
- **Date:** 2026-08-26
|
||||
- **Status:** decided — prompted; DASH-002 re-prompt averted
|
||||
- **Context:** Continuing "what comes next" after GAP-025/GAP-030. Two candidates were checked against current source before prompting either, to avoid wasting Kilocode effort on stale backlog framing:
|
||||
- **DASH-002** was about to be re-prompted with a refreshed deadline framing, but a `git status`/grep check first found `EnableStateTelemetry` already fully implemented in `NT8StrategyBase.cs` (property, default-true assignment commented "DASH-002: additive realtime observability", the `MaybeWriteStateTelemetry` gate, and the settings-export line) and confirmed live via this session's own prior `STATE:`/`STATE_CONTEXT` investigations (GAP-047/059/060/061 all read from telemetry DASH-002 produces). SPRINT_BOARD's "🔵 ACTIVE... no implementation has landed" framing was stale. **Not re-prompted** — would have been duplicate work. The refreshed `TASK_DASH-002_PROMPT.md` draft was reverted back to its original 2026-08-16 content since DASH-002 needs no further action.
|
||||
- **GAP-022-FOLLOWUP** checked out as still genuinely open: `ScenarioTests.cs`'s own TODO block (more precise than SPRINT_BOARD's old one-liner) names `NEWS_DAY_REDUCED_SIZE` (needs a calendar + sizing-policy API that doesn't exist — separate, larger, undesigned scope), `MID_TRADE_DISCONNECT`, and `PRE_ENTRY_DISCONNECT` (both blocked on the missing connection-state seam). Confirmed via source read: `_connectionLost` is checked once early in `OnBarUpdate` with no re-check immediately before order submission — `PRE_ENTRY_DISCONNECT`'s TODO description is accurate, not stale.
|
||||
- **Decision:** Prompted `TASK_GAP022_FOLLOWUP_CONNECTION_SEAM_PROMPT.md`, scoped to only the two seam-blocked scenarios (extract connection state into a new, plain, unit-testable class; add the missing pre-submit re-check; implement `MID_TRADE_DISCONNECT`/`PRE_ENTRY_DISCONNECT` as real execution tests). `NEWS_DAY_REDUCED_SIZE` explicitly excluded — flagged as a separate future task once a news-calendar/sizing-policy design exists.
|
||||
- **Consequences:** Avoided handing Kilocode a redundant DASH-002 re-implementation. GAP-022-FOLLOWUP's scope is now honest and matches what `ScenarioTests.cs`'s own TODO says is actually missing, rather than the three-scenario bundle SPRINT_BOARD previously implied.
|
||||
- **Related Files:** `TASK_GAP022_FOLLOWUP_CONNECTION_SEAM_PROMPT.md`, `tests/NT8.Core.Tests/Scenarios/ScenarioTests.cs`, `src/NT8.Adapters/Strategies/NT8StrategyBase.cs`, `SPRINT_BOARD.md`.
|
||||
- **Action Required:** Await Kilocode's implementation and commit; verify by reading the diff directly per standing practice.
|
||||
|
||||
### DEC-20260826-04
|
||||
- **ID:** DEC-20260826-04
|
||||
- **Date:** 2026-08-26
|
||||
|
||||
Reference in New Issue
Block a user