Skip to content

chore(ci): drop the never-packed exclusion now that src holds code only - #401

Closed
Vivswan wants to merge 1 commit into
mainfrom
wt/next-unpacked-drop
Closed

Vivswan wants to merge 1 commit into
mainfrom
wt/next-unpacked-drop

Conversation

@Vivswan

@Vivswan Vivswan commented Sep 22, 2026 •

Copy link
Copy Markdown
Owner

Before / After

Skip notice, before:

... touches package.json, lib/pkg/, src/, ..., or a root README, COPYING, or LICENSE (under src/, *.test.ts, scenarios/, *.docs.yml, mock.ts, generators.ts are never packed and do not count)

Skip notice, after:

... touches package.json, lib/pkg/, src/, ..., or a root README, COPYING, or LICENSE
Path a merge touches ships() before ships() after
src/sections/x/x.test.ts false (matched *.test.ts) true, but no such path exists: git ls-files src lists code only
test/src/sections/x/x.test.ts, docs/sections/x.docs.yml false (outside every input) false (unchanged)
src/sections/x/index.ts true true (unchanged)

How

  • .github/scripts/release-pipeline.ts: remove NEXT_BUILD_UNPACKED, unpacked(), UNPACKED_TEXT, and the guard in ships(); the skip reason ends at the always-packed clause; ALWAYS_PACKED stays.
  • test/scripts/release-pipeline.test.ts: drop the import; restore the SHIPPED constant; the case is now a plain surface case: a merge touching only test/src/sections/x/x.test.ts, test/src/sections/x/scenarios/a.yml, test/src/sections/x/mock.ts, and docs/sections/x.docs.yml publishes nothing (outside every NEXT_BUILD_INPUTS entry), and one touching src/sections/x/index.ts publishes.
  • The scenarios.ts module-name case is dropped: it pinned that a module named like an excluded directory was not excluded, and there is no directory rule left to confuse it with.
  • docs/reference/library.md: delete the "Under src/, what the build never packs does not count" bullet.

Proof

  • Red first: with the test reworked and the guard still in place, 3 cases failed, all on the skip-reason string still carrying the "(under src/, ...)" clause; the reworked case's skip and publish verdicts already matched.
  • env -u NODE_OPTIONS bun run typecheck: clean.
  • bun run knip: clean.
  • bun run lint: 493 files, clean.
  • bun test test/scripts/release-pipeline.test.ts --timeout 120000: 102 pass, 0 fail.
  • bun run build:check: 13 generated files match their generators; nothing regenerated (the library reference is hand-written).

Line accounting by kind

File Kind + -
.github/scripts/release-pipeline.ts pipeline code 2 32
test/scripts/release-pipeline.test.ts test 18 31
docs/reference/library.md docs 0 1
Total 20 64

Reviewer note

  • The reworked case stays beside the docs/changelog/workflow case at the top of the block: that one pins root paths outside the surface, this one pins that the section mirror (test/src/sections/<key>/) and docs/sections/ are outside it, the cross-file fact between the layout and NEXT_BUILD_INPUTS that the exclusion was built for.
  • Removal, not a guard kept "just in case": test/scripts/changed-sections.test.ts has a census case (src/ holds code only) that fails CI if a test, mock, generator, scenario, or docs prose file returns under src/sections/; the sibling case "every top-level src entry is either sections/ or all-selecting" rejects a stray top-level module. The layout is pinned where it is decided, so the publish verdict needs no second copy of the rule and no compat path.
  • test/src/sections/<key>/ is the mirror at this commit; a following change moves it to test/sections/<key>/, and the verdict does not depend on which.

BEGIN_COMMIT_OVERRIDE
chore(ci): drop the never-packed exclusion now that src holds code only

The next publish verdict carried an exclusion list, NEXT_BUILD_UNPACKED, so a merge touching only tests, scenarios, mocks, generators, or docs prose under src/ published no pre-release.
The merge just before it had already moved every such file out of src/ (tests, mocks, generators, and scenarios to the per-section test mirror, docs prose to docs/sections/), so the list matched nothing from the moment it landed and was dead config.
Remove NEXT_BUILD_UNPACKED, unpacked(), UNPACKED_TEXT, and the guard in ships(); the skip reason ends at the always-packed clause again.
Rework the pipeline test into a plain surface case: a merge touching only a section's test, scenario, mock, and docs prose publishes nothing because they lie outside every NEXT_BUILD_INPUTS entry, and one touching src/sections/x/index.ts publishes.
Drop the scenarios.ts module-name case: without a directory rule there is nothing for a module named like one to be confused with.
Delete the library reference bullet that described the exclusion.
The changed-sections census test fails CI if a test-like file returns under src/, so the layout is pinned where it is decided and no guard is kept.
END_COMMIT_OVERRIDE

Copilot AI balanced review requested due to automatic review settings September 22, 2026 03:04
@github-actions

Copy link
Copy Markdown
Contributor

File size check

0 over a hard cap (fails), 31 warning(s).

File Size Tier Cap
.github/scripts/release-pipeline.ts:6 156 chars warn 150
.github/scripts/release-pipeline.ts:468 151 chars warn 150
.github/scripts/release-pipeline.ts:1417 153 chars warn 150
.github/scripts/release-pipeline.ts:1 30 comment lines (header) warn 25
.github/scripts/release-pipeline.ts:464 14 comment lines warn 10
.github/workflows/post-green.yml:27 153 chars warn 150
.github/workflows/post-green.yml:140 16 comment lines warn 10
docs/upgrading/v2-to-v3.md 1257 lines warn 1040
src/engine/layers.ts:217 157 chars warn 150
src/flows/settings-write.ts:142 159 chars warn 150
src/flows/settings-write.ts:30 11 comment lines warn 10
src/flows/snapshot.ts:189 13 comment lines warn 10
src/github/secret-scan.ts:42 11 comment lines warn 10
src/schema.ts:186 153 chars warn 150
src/schema.ts:197 176 chars warn 150
src/sections/contract/errors.ts:14 14 comment lines warn 10
src/sections/contract/module.ts:963 185 chars warn 150
src/sections/contract/module.ts:627 12 comment lines warn 10
src/sections/contract/module.ts:897 12 comment lines warn 10
src/sections/secret_scanning_custom_patterns/compilable-form.ts:382 161 chars warn 150
src/sections/shared/roles.ts:43 13 comment lines warn 10
src/types.ts:16 156 chars warn 150
test/docs/guides.test.ts:451 155 chars warn 150
test/e2e/generators.ts 2633 lines warn 2560
test/e2e/generators.ts:1703 166 chars warn 150
test/e2e/generators.ts:1857 161 chars warn 150
test/e2e/generators.ts:1666 12 comment lines warn 10
test/engine/execute.test.ts:617 152 chars warn 150
test/flows/merge-parity.test.ts:63 164 chars warn 150
test/scripts/auto-fix-allowlist.test.ts:8 12 comment lines warn 10
test/scripts/changed-sections.test.ts:416 154 chars warn 150

Split the file, wrap the line, shorten or exempt the comment, or list the path in .file-size-allow.local with a # reason.

5 managed file(s) skipped; repo-platform owns them.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟡 Changes recommended

The revised regression test uses test/sections/ instead of the actual test/src/sections/ mirror.

Get a fresh assessment by requesting another Copilot review.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
What changed in this PR

Removes obsolete prerelease exclusions now that src/ contains code only.

Changes:

  • Simplifies shipped-path detection and skip messages.
  • Updates release tests and library documentation.
  • One test uses the wrong section-mirror path.
File Description
.github/​scripts/​release-pipeline.ts Removes unpacked-path exclusions.
test/​scripts/​release-pipeline.test.ts Updates shipped-surface tests.
docs/​reference/​library.md Removes obsolete exclusion documentation.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread test/scripts/release-pipeline.test.ts Outdated
The next publish verdict carried an exclusion list, NEXT_BUILD_UNPACKED, so a merge touching only tests, scenarios, mocks, generators, or docs prose under src/ published no pre-release.
The merge just before it had already moved every such file out of src/ (tests, mocks, generators, and scenarios to the per-section test mirror, docs prose to docs/sections/), so the list matched nothing from the moment it landed and was dead config.
Remove NEXT_BUILD_UNPACKED, unpacked(), UNPACKED_TEXT, and the guard in ships(); the skip reason ends at the always-packed clause again.
Rework the pipeline test into a plain surface case: a merge touching only a section's test, scenario, mock, and docs prose publishes nothing because they lie outside every NEXT_BUILD_INPUTS entry, and one touching src/sections/x/index.ts publishes.
Drop the scenarios.ts module-name case: without a directory rule there is nothing for a module named like one to be confused with.
Delete the library reference bullet that described the exclusion.
The changed-sections census test fails CI if a test-like file returns under src/, so the layout is pinned where it is decided and no guard is kept.
Copilot AI review requested due to automatic review settings September 22, 2026 03:13
@Vivswan
Vivswan force-pushed the wt/next-unpacked-drop branch from 96150b8 to 0b2a3af Compare September 22, 2026 03:13

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The implementation, tests, and documentation consistently reflect the code-only src/ layout.

Review effort: Balanced
Findings: None

Resolved since last review (1)

@Vivswan
Vivswan marked this pull request as ready for review September 22, 2026 03:34
@Vivswan

Vivswan commented Sep 22, 2026

Copy link
Copy Markdown
Owner Author

Folded into the release-PR hook change: the same PR moves the next publish into update-release-pr.yml and deletes the whole post-green verdict, this exclusion list included.

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