chore: set a 3,000-line custom-code budget - #2446
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Castiron custom code✅ No new custom-code files detected. 32 mixed files remain; 0 existing customizations changed. Compared 32 existing customizations unchanged
A changed generated baseline means this report cannot reliably identify which handwritten lines changed. Inspect the custom-code diffDownload the exact patch produced by this run (requires repository access): gh run download 32501926530 --repo openai/openai-node \
--name castiron-custom-code-32501926530-1 --dir /tmp/castiron-custom-code-32501926530-1
git apply --stat /tmp/castiron-custom-code-32501926530-1/custom-code.patch
cat /tmp/castiron-custom-code-32501926530-1/custom-code.patchOr reproduce it from an SDK checkout containing the vendored reporter: git fetch --no-tags origin 283e12be45fbcd3a230b5c3e4651b87073d7116f dec6a84940e67986dc0792fe03789528ca0203c6
python3 scripts/castiron/custom_code_report.py report \
--base 283e12be45fbcd3a230b5c3e4651b87073d7116f \
--head dec6a84940e67986dc0792fe03789528ca0203c6 --fetch --require-head-hash --public \
--out /tmp/castiron-custom-code-dec6a84940e6
cat /tmp/castiron-custom-code-dec6a84940e6/custom-code.patchThis is the current full custom patch for mixed files, not an attribution of only the handwritten lines changed by this PR. |
jbeckwith-oai
left a comment
There was a problem hiding this comment.
Reviewed the customization allowance against actual SDK-owned patch metrics: current usage is 1,770 lines (+1,589/-181), and the proposed 3,000-line ceiling leaves 1,230 lines (69.5%) of reasonable generation headroom while bounding material growth. The schema-version-1 policy seed changes no runtime, API, workflow, security, or ownership behavior; enforcement is intentionally staged separately.
## Summary Catch accidental growth in the SDK's remaining generated-file customization before it becomes a large patch to maintain. This ports the same layout and tooling approved in [Python #3714](openai/openai-python#3714) and [Python #3715](openai/openai-python#3715), including Python's trusted report computation. The existing workflow pair measures additions **plus** deletions against verified generated output, using the checker and budget from main. A PR cannot increase its own allowance; budget changes must be isolated and explicitly justified, and increases require a human approving review. Agents cannot approve or bypass increases. Technical details live in `scripts/castiron/CUSTOM_CODE.md`, with references from AGENTS and CONTRIBUTING. No extra workflow files, SDK API changes, checkpoint edits, exclusion changes, or CODEOWNERS changes. **Ruleset enforcement is intentionally deferred.** The integrated tooling measures **+1,955 / −208 = 2,163 custom lines**, below the **3,000-line** ceiling. This includes the reporter changes themselves. ## Stack The [budget-only foundation](openai#2446) has merged. This tooling commit is now restacked onto `main` at `d1410d190d04`; the tooling patch is unchanged and the PR contains no budget-file change. CI is rerunning against main. The trusted statuses become active after the tooling lands, but will not be required until a separately authorized ruleset rollout.
Summary
Set a 3,000-line ceiling on additions plus deletions in the remaining custom patch against verified generated output. This is the budget-only foundation for the same rollout approved in Python #3714 and Python #3715.
The verified current patch is +1,589 / −181 = 1,770 lines, leaving 1,230 lines of headroom. This is a generous bound on accidental growth, not a target or permission to add custom code.
Only
.castiron-ratchet.jsonchanges here. The stacked tooling PR will use the base-branch allowance, so a PR cannot raise its own budget. Future increases require a separate budget-only PR, explicit justification, and a human approving review; agents cannot approve them.No workflow, CODEOWNERS, or ruleset changes are included. Ruleset enforcement is a separate, later decision.
Tooling companion: #2447