Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
67 changes: 67 additions & 0 deletions contracts/OMN-11887.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
---
schema_version: "1.0.0"
ticket_id: "OMN-11887"
title: "fix(OMN-11887): ship node-owned baselines projection migration"
summary: >-
node_projection_baselines (omnimarket) declared four omnidash_analytics tables — baselines_snapshots,
baselines_comparisons, baselines_trend, baselines_breakdown — under db_io.db_tables, but every row referenced
0001_omnidash_analytics_read_model.sql, a file that exists in no repo, and the node shipped no migrations/
directory. The omnimarket projection migration runner (scripts/run-projection-migrations.py) discovers
node-owned SQL by globbing src/omnimarket/nodes/<node>/migrations/*.sql, so the four tables were never
created and the projection could never materialize. This adds migrations/0001_create_baselines_tables.sql
— idempotent (CREATE TABLE IF NOT EXISTS) DDL whose column shapes mirror BaselinesProjectionRunner (handler_baselines.py),
the handler whose contract db_tables roles (snapshots/comparisons/trend/breakdown) back these tables
— repoints all four db_tables[].migration values at the new file, and reconciles the sibling node_projection_overnight
db_tables[].migration values from the stale schema_overnight_sessions.sql to the shipped 0000_create_overnight_sessions_tables.sql
(the 0001 file is the readiness view, not a base table). No live deploy is performed; this is a migration
+ contract-metadata change.
is_seam_ticket: false
interface_change: false
interfaces_touched: []
evidence_requirements:
- kind: "tests"
description: "Focused migration test and the full omnimarket suite pass."
command: >-
grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-implementation/command.yaml
- kind: "ci"
description: "ruff, node-drift, runtime-sweep import-check, and pre-commit clean."
command: >-
grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-implementation/command.yaml
emergency_bypass:
enabled: false
justification: ""
follow_up_ticket_id: ""
dod_evidence:
- id: "dod-implementation"
description: >-
omnimarket branch jonah/omn-11887-projection-baselines-migration commit b2cf5c578089fa272c803e721dab4e12dd9a2ca4
adds src/omnimarket/nodes/node_projection_baselines/migrations/0001_create_baselines_tables.sql
(idempotent CREATE TABLE IF NOT EXISTS for baselines_snapshots, baselines_comparisons, baselines_trend,
baselines_breakdown with columns mirroring BaselinesProjectionRunner's transactional INSERTs), repoints
all four node_projection_baselines db_tables[].migration values at the new filename, reconciles
node_projection_overnight db_tables[].migration from schema_overnight_sessions.sql to 0000_create_overnight_sessions_tables.sql,
and adds tests/test_projection_baselines_migration_omn11887.py. Probe: cd omni_worktrees/OMN-11887/omnimarket
&& uv run pytest tests/test_projection_baselines_migration_omn11887.py -q. Result: 6 passed. Full
suite: 11076 passed, 48 skipped, 0 failed. Evidence-Source SHA: b2cf5c578089fa272c803e721dab4e12dd9a2ca4
source: "manual"
checks:
- check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-implementation/command.yaml"
- id: "dod-deploy-assessment"
description: >-
Deploy-readiness assessment. The change adds one node-owned migration SQL file and edits two node
contract.yaml db_io.db_tables[].migration string values plus one test. It introduces no Dockerfile,
docker-compose, runtime-kernel, handler, topic, or node-archetype change, and performs no prod/judge/stability
mutation. The new migration is applied out of band by the omnimarket projection migration runner
against omnidash_analytics; this PR does not deploy it. Not deploy-required.
source: "manual"
checks:
- check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-deploy-assessment/command.yaml"
- id: "dod-occ-self"
description: >-
Self-binding OCC receipt: this onex_change_control PR carries the OMN-11887 contract and DoD receipts.
source: "manual"
checks:
- check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-occ-self/command.yaml"
28 changes: 28 additions & 0 deletions drift/dod_receipts/OMN-11887/dod-deploy-assessment/command.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
schema_version: "1.0.0"
ticket_id: "OMN-11887"
evidence_item_id: "dod-deploy-assessment"
check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-deploy-assessment/command.yaml"
contract_sha256: "sha256:4342bf9e32e832435e8bbe9962582b1693a63491f57f370714208701e8eb81ca"
status: PASS
run_timestamp: "2026-06-30T00:00:00Z"
commit_sha: "b2cf5c578089fa272c803e721dab4e12dd9a2ca4"
branch: "jonah/omn-11887-projection-baselines-migration"
pr_number: 1541
runner: "claude-code-bg-worker"
verifier: "claude-receipt-review-omn-11887"
probe_command: "cd omni_worktrees/OMN-11887/omnimarket && git show --stat b2cf5c578089fa272c803e721dab4e12dd9a2ca4"
probe_stdout: |
src/omnimarket/nodes/node_projection_baselines/contract.yaml
src/omnimarket/nodes/node_projection_baselines/migrations/0001_create_baselines_tables.sql
src/omnimarket/nodes/node_projection_overnight/contract.yaml
tests/test_projection_baselines_migration_omn11887.py
exit_code: 0
actual_output: >-
PASS: not deploy-required. The diff touches one node-owned migration SQL file, two node contract.yaml
db_io.db_tables[].migration string values, and one test file. No Dockerfile, docker-compose, runtime-kernel,
handler, topic, or node-archetype change is present, and no prod/judge/stability mutation is performed.
The migration is applied out of band by the omnimarket projection migration runner against omnidash_analytics;
this PR does not deploy it.
working_dir: "/Users/jonah/Code/omni_home/omni_worktrees/OMN-11887/omnimarket"
31 changes: 31 additions & 0 deletions drift/dod_receipts/OMN-11887/dod-implementation/command.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
schema_version: "1.0.0"
ticket_id: "OMN-11887"
evidence_item_id: "dod-implementation"
check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-implementation/command.yaml"
contract_sha256: "sha256:4342bf9e32e832435e8bbe9962582b1693a63491f57f370714208701e8eb81ca"
status: PASS
run_timestamp: "2026-06-30T00:00:00Z"
commit_sha: "b2cf5c578089fa272c803e721dab4e12dd9a2ca4"
branch: "jonah/omn-11887-projection-baselines-migration"
pr_number: 1541
runner: "claude-code-bg-worker"
verifier: "claude-receipt-review-omn-11887"
probe_command: "cd omni_worktrees/OMN-11887/omnimarket && uv run pytest tests/test_projection_baselines_migration_omn11887.py
-q; uv run pytest tests/ -m 'not kafka' -q"
probe_stdout: |
6 passed in 0.05s
11076 passed, 48 skipped, 9 deselected, 43 warnings in 384.81s
actual_output: >-
PASS: node_projection_baselines now ships migrations/0001_create_baselines_tables.sql with idempotent
CREATE TABLE IF NOT EXISTS DDL for all four contract-declared tables (baselines_snapshots, baselines_comparisons,
baselines_trend, baselines_breakdown), column shapes mirroring BaselinesProjectionRunner's transactional
INSERTs. All four db_tables[].migration values now point at the shipped file (the nonexistent 0001_omnidash_analytics_read_model.sql
reference is gone), and node_projection_overnight db_tables[].migration values point at 0000_create_overnight_sessions_tables.sql
instead of the stale schema_overnight_sessions.sql. New test tests/test_projection_baselines_migration_omn11887.py
(6 cases) pins file existence, idempotency, the four CREATE TABLEs, projection-write column coverage,
and that no baselines/overnight db_tables migration ref is missing. Focused test: 6 passed. Full omnimarket
suite: 11076 passed, 0 failed.
exit_code: 0
working_dir: "/Users/jonah/Code/omni_home/omni_worktrees/OMN-11887/omnimarket"
25 changes: 25 additions & 0 deletions drift/dod_receipts/OMN-11887/dod-occ-self/command.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
---
schema_version: "1.0.0"
ticket_id: "OMN-11887"
evidence_item_id: "dod-occ-self"
check_type: "command"
check_value: "grep -q '^status: PASS$' drift/dod_receipts/OMN-11887/dod-occ-self/command.yaml"
contract_sha256: "sha256:4342bf9e32e832435e8bbe9962582b1693a63491f57f370714208701e8eb81ca"
status: PASS
run_timestamp: "2026-06-30T00:00:00Z"
commit_sha: "b2cf5c578089fa272c803e721dab4e12dd9a2ca4"
branch: "jonah/omn-11887-occ-receipt"
pr_number: 3374
runner: "claude-code-bg-worker"
verifier: "claude-receipt-review-omn-11887"
probe_command: "cd omni_worktrees/OMN-11887/onex_change_control && ls contracts/OMN-11887.yaml drift/dod_receipts/OMN-11887/*/command.yaml"
probe_stdout: |
contracts/OMN-11887.yaml
drift/dod_receipts/OMN-11887/dod-deploy-assessment/command.yaml
drift/dod_receipts/OMN-11887/dod-implementation/command.yaml
drift/dod_receipts/OMN-11887/dod-occ-self/command.yaml
exit_code: 0
actual_output: >-
PASS: this onex_change_control PR carries the OMN-11887 contract and its three DoD receipts (dod-implementation,
dod-deploy-assessment, dod-occ-self), each a PASS ModelDodReceipt bound to contract_sha256 sha256:4342bf9e32e832435e8bbe9962582b1693a63491f57f370714208701e8eb81ca.
working_dir: "/Users/jonah/Code/omni_home/omni_worktrees/OMN-11887/onex_change_control"
Loading