test(reporting): add auditable interoperability orchestration - #1217
Conversation
️✅ There are no secrets present in this pull request anymore.If these secrets were true positive and are still valid, we highly recommend you to revoke them. 🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request. |
|
GitGuardian failure — diagnosed, and the obvious fix would break the test. The failing check traces to the one file on this branch carrying credential-shaped strings: Confirmed new here, not inherited:
These are all intentional negative-test sentinels — the redaction logic is supposed to reject every one of them ( Worth flagging because deleting or mangling the literals to make the scanner green would silently gut the test — the sentinels only prove anything if they look real enough to match a detector. Suggested fix: add secret:
ignored-paths:
- scripts/ci/reporting_interop/security/resource_location_sentinels.jsonPrefer a path-scoped ignore over |
2a7df96 to
9327e0c
Compare
|
Current-head CI has one red job: |
|
Review verdict: CHANGES REQUESTED (posting as a comment — GitHub blocks a formal review state because this PR is authored by the same account I'm authenticated as). Reviewed at head One blocking finding, one nit. Everything else I set out to check holds. P2 —
|
|
Correction to my own P2 fix suggestion — don't copy it verbatim, the escaping differs. I said "apply the same three pieces" from
Copying it as-is gives: In the f-string it has to be a doubled backslash: process.stdout.write('ts-version-abort-helpers-complete\\n');(Also note the f-string needs I ran all three variants against the real suite:
So the corrected form both passes normally and actually detects the false-pass it exists to catch. The full working change is the marker line above placed after completed = subprocess.run(
["node", "-e", script],
check=True,
cwd=ROOT,
capture_output=True,
text=True,
timeout=30,
)
assert completed.stdout.splitlines() == ["ts-version-abort-helpers-complete"]Nothing changed in my verdict or the finding itself — only the escape form in the remedy I gave you. |
|
@bokelley P2 fixed at exact head |
|
Re-review at The fix is the corrected form, not the verbatim copy: Verified by running it, not by reading it:
That second row is the one that matters: the test now detects the false pass it previously accepted. Before this commit the same injection produced The fix is also complete rather than spot-applied — both Still carried forward, unchanged and non-blocking:
Everything I verified in the first pass still holds at this head: the 009 guard genuinely fails when its fix is mutated out, From my side this is an approve at this exact head — I can't set the formal state (GitHub blocks review states on a PR authored by the account I'm authenticated as), so recording it here. CI restarted on this push and is still in flight (40 pending, 0 failures so far); the merge gate remains that going green plus aao-secretariat's exact-head approval. |
3775bfe to
c5b5826
Compare
|
@bokelley Rebased onto current main |
|
Re-review at I diffed the PR's content against its merge base at both heads rather than diffing the heads directly, so main's 73-file contribution doesn't mask a PR-side change. Result: my reviewed content is byte-identical across the rebase — zero diff in One thing worth stating explicitly, since it looks alarming in a raw diff and is the only PR-side delta: The rebase dropped
Both files are now byte-identical to main, so the headroom went up, not down. If the rebase had resolved the other way it would have silently cut main's CI budget — it didn't. Re-ran everything at this head:
Both guards still fire after the rebase, so main's changes didn't erode either one. Nothing else changed from my Approve at this exact head from my side, recorded here since I can't set the formal state. CI is re-running on the rebase (37 pending, 9 pass, 0 failures); the gate is that completing green plus aao-secretariat's approval on |
|
@aao-secretariat #1217 is ready for formal review at exact head |
|
@aao-secretariat Formal review handoff for exact head |
|
CI recovery diagnosis for exact head
Narrow recovery: do not change #1217 product or test code and do not keep rerunning Ladon. |
|
@aao-secretariat Fresh |
|
Ahead of the fix for aao-secretariat's four threads — I verified all four against source at Scope correction on my own earlier review first: I reviewed 1. A fourth unbounded connect — Thread 4113256653 lists with psycopg.connect(database_url, autocommit=True) as connection:
connection.execute(migration)Same missing 2. Three more unbounded subprocess calls in Thread 4113251298 cites L523, L545, L785. All six Being fair about severity: these three are local version probes, nowhere near the risk of a hung 3. Confirming the remedy for thread 4113257015 matches existing convention
I'll re-review and post an exact-head verdict once the fix is pushed, including the |
|
Verified thread 4113269095 against source at Independently reproduced every element:
One correction to the thread's reasoning, which doesn't change the conclusion: The caution: the thread offers "either write return {"name": row[0], "encoding": row[1], "collation": row[2], "version": version[0]}No And SELECT system_identifier FROM pg_control_system()Adding that to I'll verify this end-to-end on the next pushed head: that a cell can now reach |
|
@bokelley please re-review exact head |
|
Coordinator check at 0bdf79c: the new storyboard timeout teardown still guards both |
|
@bokelley follow-up at exact head |
|
Verified 8e691e2 closes my process-group cleanup finding. I reran the real parent-exited/descendant-held-pipe reproduction against this head: it timed out at 1s, reported parent returncode 0, and the dedicated process group was gone after settlement. The previous head left that group alive. Targeted suite is still running; I will post its result separately. |
|
Exact-head focused validation on 8e691e2: 72 passed in tests/test_reporting_storyboard_orchestration.py and tests/test_reporting_interop_corpus.py; git diff --check clean. The actual parent-exited process-group reproduction also settled cleanly as noted above. No further blocker from my review; awaiting current-head CI and independent formal approval. |
There was a problem hiding this comment.
Ladon verdict: Approve
Approve — defensive hardening of new CI interop-harness code under scripts/ci/reporting_interop/ and tests/.
The reviewer verified operational-readiness concerns (bounded subprocess/DB timeouts, owned process-group SIGINT→SIGKILL cleanup, fail-closed drop-all) and confirmed test coverage. The database→database_identity key rename aligns emitters with the execution-credit checker. No public adcp.* surface, wire-shape, type-layering, or credential concerns apply.
Decision-table walkthrough:
- Row 1 (critical/high): no such findings.
- Row 2 (gated_paths + not APPROVED): gated_paths is false; does not fire.
- Row 3 (high_risk deleted): high_risk is false.
- Rows 4–5: no medium findings and high_risk is false.
- Row 6: no prior decision.
- Row 7: no no-auto-approve team match.
- Row 8: zero medium findings.
- Row 9: approve.
No blocking or medium findings reported.
|
Expanded exact-head check on 8e691e2: all three interop suites pass, 89 tests total (corpus, matrix, storyboard orchestration). Process-group live reproduction and diff check also pass. No further blocker from my review. |
There was a problem hiding this comment.
Ladon verdict: Approve
Approve.
Operational-readiness pass on the reporting interop CI harness (scripts/ci/reporting_interop/), no changes to the public adcp.* surface. Bounded psycopg connections with statement/lock timeouts, subprocess timeouts on all external I/O (uv/npm/cosign/gh), process-group SIGINT→SIGKILL cleanup retaining partial output, aggregated fail-closed DB cleanup, and a database→database_identity key unification with nested cluster-identity validation. Logic and matching tests are correct.
No Critical/High/Medium findings. One non-blocking follow-up: the new _create_database SELECT (pg_control_system/current_setting('data_directory')) now requires a superuser-privileged admin DSN — worth documenting, but not a blocker.
Decision path: no critical/high findings (row 1 n/a); gated_paths false (row 2 n/a); high_risk false (rows 3/5 n/a); no medium findings (rows 4/8 n/a); no prior decision (row 6 n/a); no no-auto-approve team match (row 7 n/a). Falls through to row 9 → approve.
|
Re-review at The residual: confirmed on the old head, fixed on this oneI reproduced it against the shipped
The old failure message was also actively misleading: it reported SIGKILL failing when the The new Threads closed
Also re-ran my two earlier controls at this head — the P2 false-pass guard and the 009 listener guard each still fail when mutated out. New Medium — the T5 fix requires superuser, breaking
|
|
@bokelley exact-head follow-up |
|
e1cac81 removes the privileged data_directory read from database creation and credit identity; source diff is narrow and clean. I requested the restricted-role PG16 _create_database rerun from the reviewer, because the hosted PG lane uses superuser. Current-head CI/review are pending. |
There was a problem hiding this comment.
Ladon verdict: Approve
Approve — no blocking or Medium findings.
Subsequent pass on PR #1217. The delta drops data_directory from the reporting-interop harness Postgres cluster identity (it required pg_read_all_settings/superuser), re-indexes the row tuple correctly, removes the field from producer, consumer (_execution_credit_errors), and all fixtures in lockstep, and adds a real-Postgres contract test proving _create_database works for a CREATEDB non-superuser. Changes are confined to scripts/ci/ and tests/ — no public SDK surface, wire shape, or credential concerns.
Gate check: no critical/high/medium findings (row 1 n/a); gated_paths is false (row 2 n/a); high_risk false (rows 3/5 n/a); no data-loss/schema/infra medium (row 4 n/a); prior decision was approve, not escalate (row 6 n/a); no no-auto-approve team match (row 7 n/a); fewer than three medium findings (row 8 n/a). Falls through to row 9 → approve. Prior run also approved on a clean diff; this pass remains clean and is a net improvement (adds a real-Postgres contract test).
|
Correction to my prior note: I initially filtered the diff to three paths and missed the new real-PG regression in tests/conformance/reporting/test_reporting_interop_foundation_database.py. It creates a LOGIN CREATEDB non-superuser, exercises _create_database end-to-end, verifies rolsuper=false and cluster identity, and cleans up. This directly guards the privilege failure. Reviewer retest and current-head CI remain in progress. |
|
Re-review at Retested on real PostgreSQL 16.14Spun up a cluster, created a
Values returned for the unprivileged role: I also closed the loop the mocks can't: fed those real identities into The index shift is correct: One correction to the brief
A real restricted-role test was added — I verified it's a working guard rather than a passing formality:
And it does run in CI, which was the open question — a guard nobody executes is not a guard. Replaying the Status of everything elseAll five aao threads and my three added sites remain closed; the storyboard process-group A/B and the P2/009 mutation controls all still hold from the Trivial leftover, not worth a push on its own: Approve at this exact head from my side; recorded here since I can't set a formal state. Test cluster torn down, worktree clean, all spawned processes reaped. |
|
Addendum — reviewing the new guard itself, having now read it end to end (my verdict above covered running it, not its construction).
It can't pass by accident. It asserts It fails two independent ways. The assertion is exact set equality: assert set(identity["cluster_identity"]) == {"system_identifier", "postmaster_started_at"}so reintroducing Cleanup is correct too: the Nothing to change here. Combined with the earlier confirmation that CI's |
|
Current-head local gate complete on |
Summary
Current review fixes
InputError, retaining partial logged output where applicable.database_identitycontract. Cluster identity uses PostgreSQL's canonicalpg_control_system().system_identifierpluspg_postmaster_start_time();required_cell_creditremains an independent mandatory gate.LOGIN CREATEDBnon-superuser roles withoutpg_read_all_settings. A real-PostgreSQL regression creates that restricted role, exercises database creation/identity end-to-end, and cleans up the database and role.Validation
89 passed:tests/test_reporting_interop_corpus.pytests/test_reporting_storyboard_orchestration.pytests/test_reporting_interop_matrix.pytests/conformance/reporting/test_reporting_interop_foundation_database.py; it skips locally whenADCP_PG_TEST_URL/the PostgreSQL extra is unavailable and executes in the PostgreSQL CI lane.make lintpassed.make typecheck-allpassed, including strict adopter fixtures and the no-type: ignorecontract.make testpassed on exact heade1cac81d7:11,932 passed, 2,256 skipped, 9 deselected, 1 xfailedin35m32s; coverage81.56%(required80%).Deliberate non-acceptance
required_cell_creditremains false for the current supplemental controls; shared seller/database controls cannot earn required-cell credit.Open workspace in Conductor