chore: modernize package tooling and CI#175
Merged
tonyketcham merged 5 commits intomainfrom May 8, 2026
Merged
Conversation
94ff552 to
53d71fd
Compare
b91daec to
3eafa04
Compare
Base automatically changed from
stack/tonyketcham/feat/proof-package/add-pkg-readme--1b0148ae
to
main
May 8, 2026 01:16
Objective: modernize the lowest-risk dependency/toolchain slice by aligning the packages that already use Vitest with current Vitest, Vite, TypeScript, Node typings, and tsup, while adding root scripts for typecheck, split test runners, and full local verification. Rationale: the proof audit found that @flatbread/codegen and @flatbread/utils had Vitest suites that were not reachable from the root test script, and their test stack was pinned to older TypeScript/tsup/Vitest versions. Root package metadata now pins the package manager and Node floor used by the modern Vite/Vitest toolchain. Migration notes: root test now runs AVA first and then the existing Vitest-backed package suites. Root typecheck is intentionally scoped to @flatbread/proof because it is the only package with a dedicated typecheck script today. prepublish:ci no longer mutates dependency ranges via recursive update and instead verifies frozen install plus generated declarations. Rollback: restore package.json, packages/codegen/package.json, packages/utils/package.json, and pnpm-lock.yaml from the previous commit. This reverts the package manager metadata, root scripts, and the scoped Vitest/Vite/TypeScript/tsup updates without touching source behavior. Change-Id: I779b9a2d46804836b932f76757a675ab023b0149
Objective: make the existing GitHub Actions pipeline deterministic and more complete without restructuring every job in one review. Rationale: the proof audit found mutable pnpm installs, no explicit typecheck, Vitest suites omitted from root CI, and a SvelteKit integration job that actually built the Next.js example. The workflow now pins pnpm, uses frozen installs, sets read-only permissions and cancellation concurrency, runs the root proof typecheck, runs the root test script that includes AVA plus Vitest, and points SvelteKit integration at the SvelteKit example. Runtime impact: exact CI minutes require GitHub measurements, but frozen installs improve determinism and concurrency cancels superseded PR runs. The prior SvelteKit job duplicated Next.js coverage; the updated job trades that duplicate work for real SvelteKit build coverage. Native build approvals make pnpm 10 installs reliable for esbuild, sharp, sqlite3, and related maintained native packages. Rollback: revert .github/workflows/pipeline.yml and pnpm-workspace.yaml. The script and dependency changes from the previous stack entry remain usable locally if this workflow tightening needs to be backed out. Change-Id: I003869a3e87761629ccf23947380ed1ec8709ce5
Objective: capture the rationale, migration notes, rollback considerations, runtime impact, Biome/Oxc evaluation, and deferred follow-ups for the modernization stack. Rationale: the proof audit recommended not adopting Biome or Oxc in this pass because formatter/linter boundaries span Markdown, YAML, Next.js, SvelteKit, dormant root ESLint, and framework-specific rules. A decision record keeps that tradeoff visible without coupling it to executable workflow changes. Runtime notes: local proof completed 5/5 tasks in about 1m09s; focused codegen/utils builds completed in about 4s after package-local TS configs; proof typecheck completed in about 2.5s. Exact CI runtime impact should be measured on GitHub Actions after this stack runs. Rollback: revert docs/tooling-modernization.md. No runtime behavior changes are included in this commit. Change-Id: Ic160f37689a8d054c298b09226401abe95b9d092
Objective: remediate low-risk configuration smells found by the adversarial proof audit. Rationale: package-local pnpm.peerDependencyRules blocks were ignored by pnpm and produced install warnings even though the root already owns the GraphQL peer policy. Root TypeScript paths omitted existing workspace packages, and the Next.js example invoked the flatbread CLI without declaring the workspace dependency it relies on. The SvelteKit example repository metadata still pointed at the old playground path. Migration notes: pnpm peer policy remains at the root package.json. The Next.js example now declares flatbread as a workspace dev dependency. Added root path aliases are IDE/type-resolution hygiene only and do not change runtime exports. Rollback: revert this commit to restore the previous package metadata, path aliases, and lockfile entries. The previous stack entries remain independently valid. Change-Id: I54fc3c5302d102a8d677f063fcc1d174f9ffc3f8
Objective: remediate documentation and DX smells from the adversarial proof audit. Rationale: CONTRIBUTING still told developers to use Node 16+, omitted the pinned pnpm/Corepack path, described Vitest as the dominant runner, and did not mention the new pnpm verify command. The Flatbread package README linked to the old playground path and contained a broken fieldNameTransform example. Migration notes: contributor guidance now reflects Node 20.19+, pnpm 10.33.x, root AVA plus package-local Vitest behavior, Prettier as the enforced lint gate, and pnpm verify for local CI parity. Rollback: revert this commit to restore the prior docs only. No runtime code or package metadata changes are included. Change-Id: I37b2abadd3433fb0d2145c2db64b4a0b9730f917
e706434 to
8895c4a
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary of changes
This branch contains five reviewable stack entries shaped by proof plus an adversarial proof follow-up:
chore: modernize package test toolchain@flatbread/codegen,@flatbread/utils) to current Vitest/Vite/TypeScript/tsup/Node typings.typecheck, splittest:ava/test:vitest, fulltest, andverifyscripts.packageManagerand the Node floor for the modern Vite/Vitest toolchain.ci: harden pipeline verification10.33.0, usespnpm install --frozen-lockfile, and approves required native build dependencies for pnpm 10.docs: record tooling modernization decisionschore: clean modernization config smellspnpm.peerDependencyRulesblocks that pnpm ignores; the root remains the single policy owner.@flatbread/codegenand@flatbread/resolver-svimg.flatbreadworkspace CLI dependency explicitly.docs: align modernization developer guidancepnpm verify, the real AVA/Vitest split, and Prettier as the enforced lint gate.fieldNameTransformREADME snippet.Adversarial audit notes:
svelte-checkafter route data typing is fixed, deprecated runtime dependency cleanup, and optional GitHub Action SHA pinning.Migration notes:
typecheckis intentionally scoped to@flatbread/proofuntil more packages expose typecheck scripts or project references.svelte-checkremains deferred because the existing SvelteKit route data types report a pre-existingdata.allPostCategorieserror aftersvelte-kit sync; CI now validates the SvelteKit production build.Rollback considerations:
Before/after runtime impact:
pnpm install --frozen-lockfile && pnpm lint && pnpm typecheck && pnpm build && pnpm test) completed in ~40s after the adversarial fixes.Follow-ups deferred:
svelte-checkto CI.@nrwl/workspace,tsconfig-paths, and other deprecated/possibly dead dependencies separately.Closes #
Please don't delete this checklist! Before submitting the PR, please make sure you do the following:
Does this introduce any non-backwards compatible changes?
Does this include any user config changes?