8.0 KiB
P00 Astra implementation checkpoint review
Date: 2026-11-15 (America/Indiana/Indianapolis)
Scope: commit 5822e37c8ae05863c325afe2d77e5aa9b668115a plus the frozen M1 corrective runner/test diff reviewed on disk before commit, P00 only. The review covers the phase runner, environment isolation, discovery and TRX validation, evidence identity, manifest, AdminUI SQL guard, and their tests against the implementation plan, design, prior Astra findings, and repository CI test policy.
Disposition: P00 approved after correction; M1 is resolved. The observed SQL-isolation gate is valid, and the runner now requires every selected new and existing class in discovery and execution. No high-severity SQL discovery or reaper regression was found. This is an execution-controls checkpoint, not approval of P01 contracts or completion of the gRPC data feature.
M1 — Require existing regression classes in discovery and execution
Severity: Medium. Status: resolved after follow-up review. The original finding is retained below for traceability; line references describe the initial commit.
run-unit-phase.py uses existing_classes only to validate a --case name (lines 138–143). The discovery map at line 201 and the expected-class argument to validate_trx at line 214 contain only new_classes. Consequently, an OR selector for a renamed, removed, or misspelled required existing class can match zero tests while the new feature class makes the phase pass. This loses the regression coverage explicitly required by the plan's “each selector” zero-match policy. For example, P01 could report success without DataChangeBatchContractTests while GrpcDataContractsTests passes.
The fake runner fixture also demonstrates the gap directly in source: its discovery output lists both NewTests and OldTests, while its successful TRX contains only NewTests. The success test accepts that report. No speculative adapter behavior is needed to reach the finding. When --case names an existing class, the expected TRX class set is empty, so a different class's successful result would also be accepted after valid discovery.
Required correction: Validate the union of the selected new_classes and existing_classes at both discovery and TRX execution, retaining separate fields if useful for evidence. With --case, narrow both lists to the chosen class. Add fake-subprocess cases for an absent existing class during discovery, an existing class discovered but absent from execution, and a narrowed existing-class run whose TRX contains a different class. Keep the existing missing-new-class and skipped-result checks.
This finding does not invalidate the recorded P00 result because P00 has no required existing regression classes. It should be corrected before accepting P01 or another phase with required existing classes.
Resolution: The reviewed correction constructs required_classes from both manifest lists and uses it for the discovery map and validate_trx. Both lists are narrowed under --case; execution evidence now retains existing_classes alongside new_classes. The fake success fixture supplies both required classes instead of silently omitting the existing one. Added cases reject absent existing-class discovery and execution, verify the existing-class execution identity, and verify that either kind of narrowed run excludes the other required list. The existing wrong-class execution and skip checks remain. These paths close the false-pass condition without weakening any prior gate.
The saved artifacts/grpc-data/p00-runner-regressions/red.log shows 22 tests with four failures attributable to the original missing checks. green.log shows the same 22-test suite passing after the correction. The reviewer inspected both logs and the diff; no reviewer test execution occurred. The SQL guard and its two C# tests were unchanged by this correction.
Evidence inspected
- The initial run
20261116T020652.895154Z-0d06c2c1ac5fwas followed by a complete repeat at20261116T020813.843515Z-2ebe0fbcb7d2. The repeat'srun.jsonrecords the exact reviewed commit, an empty dirty status, the empty-diff SHA-256, and no untracked files. - The repeat's discovery manifest contains exactly the two methods in
GrpcDataUnitDiscoveryIsolationTests. Its TRX reports total/executed/passed = 2, zero failures and skips, and the required class inexecuted_classes. The execution log agrees. Both commands build the exact AdminUI unit project and its dependencies normally with the required Release, scheduling, and runsettings options. - The initial Python runner had 18 test methods, with successful execution reported by the coordinator. The corrective suite contains 22 methods, and its saved red/green logs were inspected directly as described above. Integrate the final count and the clean C# repeat run identifier into the execution ledger; the earlier 16-test entry predates the reviewed correction.
- The reviewer inspected source and existing evidence only. No build, test, fixture, Docker, or migration command was run, and no production or worker file was edited.
Checks without a blocking finding
- SQL discovery and fixture lifecycle:
AdminUiSqlServerProbe.SkipReasonchecksOTOPCUA_UNIT_ONLY_DISCOVERYbefore evaluating the lazy connection probe. The fixture returns on that reason before reaping, creating a database, migrating, or setting teardown connection state. The reaper entry point independently checks the same switch. The parameterless production attribute and fixture both delegate to this guarded probe. Normal-mode lazy caching is preserved. - Behavioral guard coverage: The two C# tests construct the actual attribute and fixture through an injected counting probe/reaper seam. Unit mode asserts zero calls, including a direct attempt to call the guarded reaper. Normal mode demonstrates that the callback path remains enabled and cached once. The environment-changing collection disables parallel execution and restores the prior switch in
finally. - Discovery-side audit: The selected phase assemblies contain one custom
FactAttributeimplementation, the guarded AdminUI SQL attribute. The Configuration SQL fixture is collection-construction driven and is not selected by its phase's unit filters; the environment also replaces its shared endpoint with a loopback unavailable sentinel. OPC UA bounds fixtures belong to their own unselected test classes. This source audit is not a claim of network tracing or of future new classes being automatically safe; later additions still require review. - Child environment and command scope: Both discovery and execution receive the same explicit allowlist, dedicated unit switch, and unavailable SQL/OPC UA sentinels. Ambient fixture credentials, application connection variables, and Docker endpoint variables are omitted. The runner uses argv with
shell=False, rejects non-unit project paths, does not use stale--no-buildoutputs, performs no automatic retry, and gives each run/project a unique artifact directory. - TRX and skipped-class handling: The runner rejects missing/stale/malformed TRX, zero executed tests, failures, inconsistent result counts, and any non-Passed individual result. Executed class identity is checked against TRX definitions for every required new and existing class after the M1 correction; neither category can mask a missing class in the other.
- Identity and scope: SHA, dirty status, tracked diff digest, untracked file digests, exact argv/filter, and durations are retained without writing raw source diffs or inherited environment values into the report. This identity is captured at run start; it is not a guarantee against edits during a run. The clean repeat above is the evidence for this checkpoint. No SQL-backed integration coverage is inferred from the two unit tests; final local fixture coverage and removal of the unit switch remain P12 obligations.
Only this checkpoint review document was edited by the reviewer. No commit was created.