Skip to content

fix: restore audit pins and bun 1.4 test preload - #288

Merged
FrkAk merged 2 commits into
mainfrom
fix/audit-lockfile-bump
Aug 25, 2026
Merged

FrkAk merged 2 commits into
mainfrom
fix/audit-lockfile-bump

Conversation

@FrkAk

@FrkAk FrkAk commented Aug 25, 2026 •

Copy link
Copy Markdown
Owner

Summary

Task Reference: None

CI's check job is red on every branch for two independent, mutually masking reasons; this PR fixes both (neither can go green in a separate PR, since each failure hides or blocks the other in the same job):

  • bun audit --audit-level=high newly fails: two high advisories landed in transitive dependencies — js-yaml 4.3.0 via @eslint/eslintrc (GHSA-5p4m-2wfm-xmqj) and nanoid 3.3.16 via postcss (GHSA-2v37-7h3g-55p8). Both are added to the existing documented security-pin overrides block; both parents declare ranges that already allow the fixed versions, so the pins only raise the floor.
  • Bun 1.4 (CI floats to latest via setup-bun@v2) rejects Object.defineProperty(process.env, …) unless the descriptor is configurable, enumerable, AND writable. The NODE_ENV pins in tests/setup/preload.ts and the per-test helpers passed only configurable, so every test file dies in preload on CI. This was masked by the audit step failing first.

Type of change

  • Bug fix
  • New feature
  • Refactor / cleanup
  • Documentation

Testing

  • Linting passes (bun run lint)
  • Typecheck passes (bun run typecheck)
  • bun audit --audit-level=high --ignore=GHSA-f88m-g3jw-g9cj exits 0 with the pins in place
  • bun test: 2,264 of 2,265 pass — the single failure (tests/graph/tools-write.test.ts "edit set tags fires variant and taxonomy hints") reproduces identically on clean main in full-suite order and passes in isolation, so it is a pre-existing order dependency, not introduced here; flagged for a follow-up.

Notes for reviewer

  • Lockfile motion is exactly the two bumped entries: js-yaml 4.3.0 → 4.3.1, nanoid 3.3.16 → 3.3.18. The //overrides removal note is extended in the block's existing style.
  • The descriptor fix touches all four NODE_ENV defineProperty sites (preload, tests/api/error.test.ts, tests/db/request-scope.workers.test.ts) and documents the bun ≥ 1.4 constraint where the pattern is defined.

Docs impact

None.

Compliance impact

None.

@FrkAk FrkAk self-assigned this Aug 25, 2026
@FrkAk FrkAk mentioned this pull request Aug 25, 2026
15 of 16 tasks
@FrkAk FrkAk changed the title fix: pin js-yaml and nanoid past new high advisories fix: restore CI — audit pins and bun 1.4 test preload Aug 25, 2026
@FrkAk
FrkAk marked this pull request as ready for review August 25, 2026 19:11
@FrkAk FrkAk changed the title fix: restore CI — audit pins and bun 1.4 test preload fix: restore audit pins and bun 1.4 test preload Aug 25, 2026
FrkAk added 2 commits August 25, 2026 21:25
bun audit newly fails on two high advisories in transitive
dependencies: js-yaml 4.3.0 via @eslint/eslintrc (GHSA-5p4m-2wfm-xmqj)
and nanoid 3.3.16 via postcss (GHSA-2v37-7h3g-55p8). Both parents
declare ranges that already allow the fixed versions, so these
overrides only raise the floor, following the existing documented
security-pin pattern. Remove each once its parent ships the fix.
Bun 1.4 rejects Object.defineProperty on process.env unless the
descriptor is configurable, enumerable, and writable; the NODE_ENV
pins in the test preload and per-test helpers passed only
configurable, so on CI (setup-bun@v2 floats to latest) every test
file dies in preload. This was masked until now by the audit step
failing first.
@FrkAk
FrkAk force-pushed the fix/audit-lockfile-bump branch from 0a4a1e0 to 9f29d37 Compare August 25, 2026 19:26
@FrkAk
FrkAk merged commit 34bb8f4 into main Aug 25, 2026
7 checks passed
@FrkAk
FrkAk deleted the fix/audit-lockfile-bump branch August 25, 2026 20:02
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.

1 participant