Skip to content

ci(prism-code): sum the package cap from one allowance file per change (Part of #441) - #618

Merged
afflom merged 1 commit into
mainfrom
claude/project-thread-jbxsn0
Nov 12, 2026
Merged

afflom merged 1 commit into
mainfrom
claude/project-thread-jbxsn0

Conversation

@afflom

@afflom afflom commented Nov 12, 2026

Copy link
Copy Markdown
Member

Requested by Alex · project thread

Why

Every change that grows the prism-code package edited the single PACKAGE_LIMIT comment line in scripts/check-package.mjs. Five v0.5 workstreams (#441-#449) are now running in parallel, and all of them would conflict on that one line. Main has about 2.6 KiB of headroom, so each of them needs an allowance.

What

  • PACKAGE_LIMIT is now the sum of sdk/npm/prism-code/scripts/package-allowances/*.json. Each file holds exactly { "kib": n, "reason": "..." }, and malformed files are refused.
  • The 19 allowances from the old line move over unchanged, totalling 1584 KiB, so the cap is still 1622016 bytes.
  • test/package.test.mjs reads the limit instead of repeating 1622016/1584 KiB.

A change that needs room adds its own file, so parallel PRs never touch the same line. #614's +8 KiB becomes one more file when it rebases.

Test

node --test test/package.test.mjs (with npm_execpath set): 4/4 pass. The limit computes to 1622016.


Generated by Claude Code

PACKAGE_LIMIT was one comment line that every change growing the package
edited, so parallel v0.5 PRs would all conflict on it. The cap is now the
sum of scripts/package-allowances/*.json, each holding a kib and a reason.
The 19 allowances on the old line move over unchanged (1584 KiB in total,
the same 1622016 bytes), and the package test reads the limit instead of
repeating the number.

Part of #441

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013Asa3QVSkS6PGopegNeztG
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants