Skip to content

fix(privacy): omit provider IDs from routine batch logs - #317

Draft
seonghobae wants to merge 2 commits into
mainfrom
fix/low-cardinality-batch-id-logs-b84f0c9
Draft

fix(privacy): omit provider IDs from routine batch logs#317
seonghobae wants to merge 2 commits into
mainfrom
fix/low-cardinality-batch-id-logs-b84f0c9

Conversation

@seonghobae

@seonghobae seonghobae commented Aug 31, 2026

Copy link
Copy Markdown
Contributor

Addresses #301.

Exact source boundary

  • Branch fix/low-cardinality-batch-id-logs-b84f0c9 was created explicitly from protected main@b84f0c94154043a3473939c01bb6471de5a129ae after a full open-PR/non-default-writer inventory proved the intended pg_llm_batch/batch_api_client.py + focused test surface writer-safe.
  • No source/documentation write was made to protected main.
  • Current repair head is exact 273a785642adcc5cb7ab72272a113e1ba6de8eae, two commits ahead / zero behind that protected base, changing only pg_llm_batch/batch_api_client.py and tests/test_batch_api_client_log_privacy.py.

RED -> narrow GREEN

RED commit 7e6fb165aa064d899321b8721f33ce197f279595 added a focused regression preserving caller-visible provider file/batch IDs while requiring ordinary package INFO logs to emit only fixed low-cardinality success messages. Exact-head CI run 33350196599 failed: both Python 3.12 and Python 3.14 unit-test jobs failed at Run unit tests, and the exact-head coverage job failed after successful checkout/source verification, lint and docstring gates.

Production commit 273a785642adcc5cb7ab72272a113e1ba6de8eae makes the smallest behavior change:

  • Uploaded JSONL file: <provider-id> -> Uploaded JSONL file
  • Created batch job: <provider-id> -> Created batch job

Provider API results, resource IDs returned to authorized callers, lifecycle/retry/retention semantics, request payloads and persistence are unchanged.

Exact-head validation and dependency boundary

On exact final head 273a785642adcc5cb7ab72272a113e1ba6de8eae:

  • Python 3.10, 3.12 and 3.14 unit tests are terminal-success; Python 3.14.7 ran 1333 passed, 5 deselected.
  • lint and public-docstring coverage are terminal-success; public docstrings remain exactly 100%.
  • the changed production module pg_llm_batch/batch_api_client.py is exactly 100% statement/branch covered (411 statements, 154 branches, zero misses/partials).
  • Security Scan, SAST Semgrep and Release Acceptance pull-request runs are terminal-success for this exact head.
  • container builds / PostgreSQL runtime smokes are terminal-success.

The repository-wide coverage job is intentionally not represented as GREEN. Exact final-head CI run 33350358960 reports 3633 statements / 1006 branches with zero missed statements but two inherited uncovered protected-main branch arcs: postgres_backup_evidence.py:65->exit and postgres_schema_evidence.py:49->exit, total 99.96%. Those are the exact pre-existing coverage defects owned by open dependency-root PR #233; #233 changes only tests/test_postgres_recovery_evidence_registry.py to cover those arcs.

This PR will not copy, duplicate, or race #233's active test writer merely to manufacture a green aggregate gate. It remains Draft until #233 is normally integrated (or legitimately superseded), after which this unchanged privacy head must be reconciled against the fresh protected base and reacquire exact 100% owned-production statement/branch coverage plus all then-live required review/security/release evidence.

Strix evidence boundary — green status, non-passing semantic evidence

Required Strix workflow run 33350356643 is bound to this exact head, but its attempts must be distinguished:

  • attempt 1 / job 99363187573 failed closed before authoritative analysis when the read-only contextual-orchestrator NVIDIA NIM route returned non-retryable HTTP 400. That provider/control-plane failure remains immutable historical RCA.
  • attempt 2 / job 99453416178 concluded GitHub success and uploaded strix-reports artifact 9754943653, SHA-256 fa872a76e28ceebafa91c23e303111063bfea1f61f065830d3384e6d0ba43e06.

The attempt-2 status is not accepted as authoritative security clearance after inspecting the bound artifact. The run retained one scannable changed source file; run.json records four LLM requests, 172154 input tokens and only 263 output tokens; penetration_test_report.md is generic template/placeholder prose rather than source-specific methodology, technical analysis or remediation; and findings.sarif contains an empty rule/result set. Strix also emitted a model-quality warning for the selected openai/orchestrator/free route.

Therefore the required workflow proves operational completion and artifact upload only. Under pg acquisition/evidence policy, status-only/synthetic/template output is non-passing. An empty SARIF cannot be promoted to a clean vulnerability verdict when the accompanying source-bearing analysis is non-substantive.

The organization-central owner is read-only ContextualWisdomLab/.github#891 (Fail closed when Strix produces no authoritative scan evidence). Do not copy that repair into pg, weaken the required Strix gate, or churn this source head to manufacture a new scan event. A later protected-central repair/re-evaluation must produce genuine exact-source authoritative finding/no-finding evidence before this PR can treat Strix as satisfied. The attempt-1 and attempt-2 artifacts remain historical audit/RCA evidence and are not erased.

Required OpenCode review evidence boundary — current exact-head failure

The required OpenCode workflow is also non-passing on this exact head and must not be hidden by the green coverage-evidence context. Workflow run 33350356630, job 99362699176, is bound to 273a785642adcc5cb7ab72272a113e1ba6de8eae and concludes failure at the explicit step Fail closed without a current-head OpenCode verdict. Fresh formal-review and review-thread inventories are both empty.

This is a fail-closed review-evidence state, not evidence of a new source defect. Because #317 is intentionally Draft behind unresolved aggregate-coverage and authoritative-Strix prerequisites, do not manufacture a verdict, self-review, request premature approval, or churn the source head merely to change this status. Once the substantive dependencies clear and the lane is legitimately review-ready, the then-exact head must acquire a genuine current-head semantic review disposition and every other live review requirement.

Current readiness

This PR is intentionally Draft and blocked on three independently non-passing boundaries:

  1. aggregate exact-100%-coverage restoration through normal test(recovery): cover stale evidence registry cleanup #233 integration or a legitimate superseding protected-main repair;
  2. genuine authoritative Strix evidence under the protected central control plane; and
  3. a genuine current-head OpenCode semantic verdict when the PR becomes legitimately review-ready (the present exact-head required opencode-review check is fail-closed because no such verdict exists).

There are currently no formal reviews or review threads on #317. Do not request/interpret approval as merge readiness while the substantive coverage and Strix gates are non-passing. After dependencies change, refetch protected main, reconcile non-destructively, and reacquire the entire then-live exact-head/current-base check, security, review and release set.

No schema, provider API, retry, lifecycle, persistence, canonical documentation, telemetry exporter, or retention contract is changed here. No privacy-law, SOC 2 or CSAP certification claim follows from this repair.

@coderabbitai

coderabbitai Bot commented Aug 31, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copy link
Copy Markdown
Contributor Author

Fresh exact-head blocker RCA for #317@273a785642adcc5cb7ab72272a113e1ba6de8eae against protected main@b84f0c94154043a3473939c01bb6471de5a129ae:

  • Required Strix Security is terminal failure at run 33350356643, job 99363187573.
  • The trusted required workflow ran from central .github source SHA 046bc2beb2e0bb4be804255764bcbb4c49e973e9, materialized the exact PR head, and reached contextual-orchestrator provider routing.
  • Gateway preflight found one ready route, nvidia_nim_meta_llama_3_2_90b_vision_instruct (meta/llama-3.2-90b-vision-instruct), but the actual Strix request failed before the first model response with provider HTTP 400 / invalid_request_error, retryable: false. Three bounded attempts failed the same way; each produced 0 tokens and no authoritative vulnerability analysis. The wrapper correctly failed closed as STRIX_PROVIDER_UNAVAILABLE.
  • Therefore this failure is not evidence of a pg source/privacy defect and not evidence of zero vulnerabilities. Do not mutate this source lane to chase the provider failure; keep the PR Draft and require a fresh exact-head terminal Strix success after a material central/provider change.
  • The aggregate coverage gate is separately non-passing because protected main still carries the two weakref branch arcs covered by dependency-root test(recovery): cover stale evidence registry cleanup #233. Do not duplicate test(recovery): cover stale evidence registry cleanup #233's active test writer here.

Writer-collision correction: a fresh non-default-branch comparison shows no-PR branch agent/retry-after-parser-hardening@417e84bee6356d560201d36a760425c3d893646d is 4 commits ahead / 187 behind protected main and also modifies pg_llm_batch/batch_api_client.py. That is active-writer evidence on the same production file even though the branch is stale/diverged. Freeze further source mutation on #317 for this invocation; reconcile ownership/non-overlap before any future change to this file. The current #317 diff itself remains exactly two commits ahead / zero behind main and changes only pg_llm_batch/batch_api_client.py plus its focused privacy test.

@seonghobae seonghobae added area: api API, protocol, event, or external contract area: ci-cd CI, GitHub Actions, checks, release, or supply chain area: security Security boundary, hardening, or vulnerability prevention priority: medium Normal-priority or P2 work status: blocked Blocked by conflict, dependency, or required prerequisite type: bug Defect or incorrect behavior labels Aug 31, 2026 — with ChatGPT Codex Connector
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: api API, protocol, event, or external contract area: ci-cd CI, GitHub Actions, checks, release, or supply chain area: security Security boundary, hardening, or vulnerability prevention priority: medium Normal-priority or P2 work status: blocked Blocked by conflict, dependency, or required prerequisite type: bug Defect or incorrect behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant