Gap
scripts/ci/pingora_edge_policy.py admits binary or non-UTF-8 content only when the path carries a doc/docs/documentation component (DOCUMENTATION_DIRECTORIES, line 52; _is_known_documentation_path, line 168), plus the evidence/figures publication directories added by #2149. Everything else is a content-policy violation.
In a research repository the binary artefacts that most need preserving are not documentation: raw response workbooks, SPSS .sav files, serialized model objects, compressed numeric arrays. ContextualWisdomLab/late-life-anxiety-reanalysis keeps these under local/ and an evidence-preservation path by deliberate, owner-approved design. The scanner rejects them on path shape alone and cannot distinguish a preserved research artefact from an unreviewed binary blob.
A content-policy failure is a failure about the change itself, so it is not eligible for the infrastructure bypass. The only routes left are to relocate research data under a docs/ path, which misrepresents what it is, or to leave the pull request permanently unmergeable. That repository already took the first route once, relocating 66 images under docs/ purely to satisfy the path rule.
Ask
Let a repository declare paths that hold research or data artefacts, and admit binary content there on the same terms as documentation. This is not a general weakening: unreviewed binaries in application code must still fail.
Design constraint that must not be missed
evaluate_pull_request fetches file content only at head_sha (_load_file_content, line 416; the function takes no base ref today). A declaration read from the pull-request head would be self-authorizing: one pull request could add both the declaration and the binary, and the check would admit itself.
The declaration must therefore be resolved from the base branch at merge base, so admission depends only on already-reviewed state, and evaluate_pull_request needs the base ref threaded in for that purpose. A pull request that introduces or widens the declaration gets no benefit from it until that change itself is reviewed and merged.
Suggested shape
- A declaration file in the consumer repository, read from the base ref: an explicit list of path prefixes, no globs that can widen unexpectedly, with a documented cap on entry count and prefix depth.
- Admission under a declared prefix still requires the existing magic-byte and completeness evidence; the declaration only replaces the path-shape test, never the content test.
- Runtime forms (
_runtime_path_rule) stay rejected inside declared prefixes, exactly as they are inside docs/ today.
- Violation text names the declared prefix that admitted a file, so a reviewer can see which reviewed declaration was relied on.
Reporter constraints
The repository is private, and the study owner reviewed the presence of participant-level files and explicitly declined cleanup, so this is not a question about whether the data belongs there. The affected paths are stable, so a declared list would not need frequent changes.
Status of the immediate case
Not blocked. The pull request that surfaced this was closed as superseded (all three files in its diff were already byte-identical on main), so no bypass is needed and none should be performed: the failure was a genuine content-policy failure, not an infrastructure one. This issue is to fix the rule before the next preservation change hits it.
Reported by the session coordinating ContextualWisdomLab/late-life-anxiety-reanalysis. Related: #2116, #2149.
🤖 Generated with Claude Code
Gap
scripts/ci/pingora_edge_policy.pyadmits binary or non-UTF-8 content only when the path carries adoc/docs/documentationcomponent (DOCUMENTATION_DIRECTORIES, line 52;_is_known_documentation_path, line 168), plus theevidence/figurespublication directories added by #2149. Everything else is a content-policy violation.In a research repository the binary artefacts that most need preserving are not documentation: raw response workbooks, SPSS
.savfiles, serialized model objects, compressed numeric arrays.ContextualWisdomLab/late-life-anxiety-reanalysiskeeps these underlocal/and an evidence-preservation path by deliberate, owner-approved design. The scanner rejects them on path shape alone and cannot distinguish a preserved research artefact from an unreviewed binary blob.A content-policy failure is a failure about the change itself, so it is not eligible for the infrastructure bypass. The only routes left are to relocate research data under a
docs/path, which misrepresents what it is, or to leave the pull request permanently unmergeable. That repository already took the first route once, relocating 66 images underdocs/purely to satisfy the path rule.Ask
Let a repository declare paths that hold research or data artefacts, and admit binary content there on the same terms as documentation. This is not a general weakening: unreviewed binaries in application code must still fail.
Design constraint that must not be missed
evaluate_pull_requestfetches file content only athead_sha(_load_file_content, line 416; the function takes no base ref today). A declaration read from the pull-request head would be self-authorizing: one pull request could add both the declaration and the binary, and the check would admit itself.The declaration must therefore be resolved from the base branch at merge base, so admission depends only on already-reviewed state, and
evaluate_pull_requestneeds the base ref threaded in for that purpose. A pull request that introduces or widens the declaration gets no benefit from it until that change itself is reviewed and merged.Suggested shape
_runtime_path_rule) stay rejected inside declared prefixes, exactly as they are insidedocs/today.Reporter constraints
The repository is private, and the study owner reviewed the presence of participant-level files and explicitly declined cleanup, so this is not a question about whether the data belongs there. The affected paths are stable, so a declared list would not need frequent changes.
Status of the immediate case
Not blocked. The pull request that surfaced this was closed as superseded (all three files in its diff were already byte-identical on
main), so no bypass is needed and none should be performed: the failure was a genuine content-policy failure, not an infrastructure one. This issue is to fix the rule before the next preservation change hits it.Reported by the session coordinating
ContextualWisdomLab/late-life-anxiety-reanalysis. Related: #2116, #2149.🤖 Generated with Claude Code