diff --git a/contracts/OMN-14326.yaml b/contracts/OMN-14326.yaml new file mode 100644 index 00000000000..2c31b2a14bc --- /dev/null +++ b/contracts/OMN-14326.yaml @@ -0,0 +1,72 @@ +--- +schema_version: "1.0.0" +ticket_id: "OMN-14326" +title: "feat(OMN-14326): node_ast_node_analyzer + node_stub_detector — pure COMPUTE codegen-analysis nodes" +summary: >- + omnimarket product PR #1707 (branch jonah/omn-14326-ast-analyzer-stub-detector, head f6e379329894d7d57383f924463a72367b2dc1e3) + adds two pure COMPUTE nodes extracted from dormant codegen analysis logic. node_ast_node_analyzer parses + a single ONEX node's source TEXT with the standard-library ast module and returns {class_name, base_class, + mixins[], methods[], docstring, io_operations[]}, classifying I/O operation classes from import names + and source substrings. node_stub_detector walks class bodies and flags each async method carrying an + incomplete-method marker, matching comment markers against real comment tokens (tokenize) and NotImplementedError + against the AST (a real raise node) so a marker inside a string literal is never a false positive. Both + are stateless, deterministic, and perform NO I/O — they operate on source text supplied in the request + model, not on files read from disk. CONTRACT + NODE + HANDLER only (rule 7a canonical); no Plugin* base, + no node-calling-node. +is_seam_ticket: false +interface_change: true +interfaces_touched: + - "public_api" +emergency_bypass: + enabled: false + justification: "" + follow_up_ticket_id: "" +dod_evidence: + - id: "dod-001" + description: >- + Independent adversarial verification at product head f6e379329894d7d57383f924463a72367b2dc1e3 (verifier + did not implement the PR). Tests: node_ast_node_analyzer + node_stub_detector protocol suites pass + 34/34 (18 + 16). Mutation-discrimination: four semantic mutations across the two handlers were each + caught RED then reverted (analyzer HTTP-detection disabled -> 2 fail; analyzer mixin-extraction + disabled -> 1 fail; stub-detector marker guard inverted -> 10 fail; stub-detector NotImplementedError + changed from AST-Raise to naive substring -> the string-literal false-positive test failed by flagging + method 'describe'), proving the suites are behavior-discriminating, not vacuous; worktree left clean. + COMPUTE purity: neither handler performs file/network I/O — the analyzer parses request.source_text + (the module-name and "open("/"Path(" constants are detection needles matched against the analyzed + source, not imports/calls); the stub detector uses in-memory io.StringIO + tokenize only. No Plugin* + base and no cross-node imports (each node imports only its own models). Gates: ruff check clean, + ruff format clean (13 files), mypy --strict clean (13 source files), runtime import-check clean + (352 entry points, both new nodes registered), node metadata dependency scope PASS. + source: "manual" + status: "verified" + checks: + - check_type: "command" + check_value: >- + grep -q '^status: PASS$' drift/dod_receipts/OMN-14326/dod-001/command.yaml && grep -q '^pr_number: + 1707$' drift/dod_receipts/OMN-14326/dod-001/command.yaml && grep -q 'f6e379329894d7d57383f924463a72367b2dc1e3' + drift/dod_receipts/OMN-14326/dod-001/command.yaml + - id: "dod-deploy-assessment" + description: >- + Deploy-surface assessment: product PR #1707 adds two new pure-logic COMPUTE node source trees (contract + + handler + pydantic models) plus their protocol tests, and a two-line onex.nodes entry-point registration + in pyproject.toml (no new third-party dependency). No live deploy, restart, .201 mutation, topic + mutation, or migration was performed by this OCC companion; product PR merge relies on normal CI + gates and downstream deploy validation instead of a bypass. + source: "manual" + status: "verified" + checks: + - check_type: "command" + check_value: >- + grep -q '^status: PASS$' drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml && + grep -qi 'no live deploy' drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml + - id: "dod-occ-self" + description: >- + OCC companion self-binding: this onex_change_control PR carries the net-new OMN-14326 central contract + and PASS receipts consumed by omnimarket#1707 through its Evidence-Source line. Self-binds via the + first commit's SHA for occ-preflight eligibility (no PR-number prediction). + source: "manual" + status: "verified" + checks: + - check_type: "command" + check_value: >- + grep -q '^status: PASS$' drift/dod_receipts/OMN-14326/dod-occ-self/command.yaml diff --git a/drift/dod_receipts/OMN-14326/dod-001/command.yaml b/drift/dod_receipts/OMN-14326/dod-001/command.yaml new file mode 100644 index 00000000000..0070ea66917 --- /dev/null +++ b/drift/dod_receipts/OMN-14326/dod-001/command.yaml @@ -0,0 +1,37 @@ +--- +schema_version: "1.0.0" +ticket_id: "OMN-14326" +evidence_item_id: "dod-001" +check_type: "command" +check_value: "uv run pytest tests/nodes/node_ast_node_analyzer tests/nodes/node_stub_detector -v" +status: PASS +run_timestamp: "2026-07-10T20:29:00Z" +commit_sha: f6e379329894d7d57383f924463a72367b2dc1e3 +runner: "claude-opus-4-8" +verifier: "occ-independent-verify" +pr_number: 1707 +probe_command: >- + cd omni_worktrees/OMN-14326/omnimarket && env -u PYTHONPATH uv run pytest tests/nodes/node_ast_node_analyzer + tests/nodes/node_stub_detector -v; env -u PYTHONPATH uv run ruff check src/omnimarket/nodes/node_ast_node_analyzer + src/omnimarket/nodes/node_stub_detector; env -u PYTHONPATH uv run mypy src/omnimarket/nodes/node_ast_node_analyzer + src/omnimarket/nodes/node_stub_detector --strict; env -u PYTHONPATH uv run python -m omnimarket.nodes.node_runtime_sweep + --import-check +probe_stdout: | + 34 passed in 0.07s (node_ast_node_analyzer 18 + node_stub_detector 16) + ruff check: All checks passed! ruff format --check: 13 files already formatted + mypy --strict: Success: no issues found in 13 source files + runtime import-check: status "clean", entry_points_checked 352, findings [] + metadata dependency scope: PASS + mutation-discrimination (each mutation reverted, worktree left clean): + analyzer: disable HTTP detect -> 2 failed; disable mixin extract -> 1 failed + stub_detector: invert marker guard -> 10 failed; AST-Raise -> substring -> false-positive test flagged 'describe' +actual_output: >- + PASS: at head f6e379329894d7d57383f924463a72367b2dc1e3 both COMPUTE nodes are real and behavior-proven. + The 34 protocol tests pass and every one of the four semantic mutations was caught RED (then reverted), + so the suites are discriminating not vacuous. Both handlers are pure — the AST analyzer parses request.source_text + (never reads a file path) and the stub detector uses in-memory tokenize only; the module-name and "open("/"Path(" + tokens are detection needles, not imports. No Plugin* base, no cross-node imports. ruff, mypy --strict, + runtime import-check (352 entry points, both nodes registered) and metadata deps are all green. +exit_code: 0 +branch: "jonah/omn-14326-ast-analyzer-stub-detector" +contract_sha256: "sha256:38e77d8c832becc394827ed95260b26d335f6ca0446b0fce2aa8944665961e9c" diff --git a/drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml b/drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml new file mode 100644 index 00000000000..31d4520ea9c --- /dev/null +++ b/drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml @@ -0,0 +1,38 @@ +--- +schema_version: "1.0.0" +ticket_id: "OMN-14326" +evidence_item_id: "dod-deploy-assessment" +check_type: "command" +check_value: >- + grep -q '^status: PASS$' drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml && grep -qi + 'no live deploy' drift/dod_receipts/OMN-14326/dod-deploy-assessment/command.yaml +status: PASS +run_timestamp: "2026-07-10T20:29:00Z" +commit_sha: f6e379329894d7d57383f924463a72367b2dc1e3 +runner: "claude-opus-4-8" +verifier: "occ-independent-verify" +pr_number: 1707 +probe_command: >- + gh pr diff 1707 --repo OmniNode-ai/omnimarket --name-only +probe_stdout: | + pyproject.toml + src/omnimarket/nodes/node_ast_node_analyzer/contract.yaml + src/omnimarket/nodes/node_ast_node_analyzer/handlers/handler_ast_node_analyzer.py + src/omnimarket/nodes/node_ast_node_analyzer/metadata.yaml + src/omnimarket/nodes/node_ast_node_analyzer/models/model_ast_node_analyzer_request.py + src/omnimarket/nodes/node_ast_node_analyzer/models/model_node_analysis.py + src/omnimarket/nodes/node_stub_detector/contract.yaml + src/omnimarket/nodes/node_stub_detector/handlers/handler_stub_detector.py + src/omnimarket/nodes/node_stub_detector/metadata.yaml + src/omnimarket/nodes/node_stub_detector/models/model_stub.py + src/omnimarket/nodes/node_stub_detector/models/model_stub_detection_result.py + src/omnimarket/nodes/node_stub_detector/models/model_stub_detector_request.py + tests/nodes/node_ast_node_analyzer/test_handler_ast_node_analyzer.py + tests/nodes/node_stub_detector/test_handler_stub_detector.py +actual_output: >- + PASS: product PR #1707 adds two new pure-logic COMPUTE node source trees plus their protocol tests and + a two-line onex.nodes entry-point registration in pyproject.toml (no new third-party dependency). No + live deploy, restart, .201 mutation, topic mutation, or migration was performed for this evidence companion. +exit_code: 0 +branch: "jonah/omn-14326-ast-analyzer-stub-detector" +contract_sha256: "sha256:38e77d8c832becc394827ed95260b26d335f6ca0446b0fce2aa8944665961e9c" diff --git a/drift/dod_receipts/OMN-14326/dod-occ-self/command.yaml b/drift/dod_receipts/OMN-14326/dod-occ-self/command.yaml new file mode 100644 index 00000000000..918a876a711 --- /dev/null +++ b/drift/dod_receipts/OMN-14326/dod-occ-self/command.yaml @@ -0,0 +1,23 @@ +--- +schema_version: "1.0.0" +ticket_id: "OMN-14326" +evidence_item_id: "dod-occ-self" +check_type: "command" +check_value: "gh pr view --repo OmniNode-ai/onex_change_control --json number,state,headRefName,headRefOid,baseRefName,title,url" +status: PASS +run_timestamp: "2026-07-10T20:32:00Z" +commit_sha: e87b7c64638a29a40d1c01fb8d59395a78b03035 +runner: "claude-opus-4-8" +verifier: "occ-independent-verify" +probe_command: >- + git rev-parse HEAD +probe_stdout: | + e87b7c64638a29a40d1c01fb8d59395a78b03035 +actual_output: >- + PASS: this onex_change_control PR carries the net-new OMN-14326 central contract and PASS receipts consumed + by omnimarket#1707 via its Evidence-Source line. Self-binds deterministically via the first commit SHA + e87b7c64638a29a40d1c01fb8d59395a78b03035 (a member of this OCC PR's commit set) so occ-preflight eligibility + holds without predicting the OCC PR number. +exit_code: 0 +branch: "jonah/omn-14326-occ-market-1707" +contract_sha256: "sha256:38e77d8c832becc394827ed95260b26d335f6ca0446b0fce2aa8944665961e9c"