fix(amountinator): enforce package artifact contract - #347
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
All alerts resolved. Learn more about Socket for GitHub. This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored. |
|
Hosted CI found one dependency-order issue in the new unit test: the repository-health job intentionally runs before dependency installation, while the verifier imported Reproduced locally by copying only the verifier and its test into a fresh directory with no |
|
Two quality follow-ups are now pushed:
Clean-room dependency-free tests, all 24 repository controls, the real strict tarball/ESM/CJS check, and the low-severity audit pass locally. Fresh hosted analysis is required to show zero Sonar issues before merge. |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
Maintainer review by |
|
The ready-for-review transition exposed Codecov patch coverage at 55.56% (four partially covered changed conditional lines). Commit |
|
|
Final maintainer review by |



Program scope
Advances #324 Wave 10 and the remaining npm package-artifact portion of Wave 6. This is the first profile-by-profile quality slice after the completed licensing wave.
What changed
@bsv/amountinatorpackaging: the previous manifest exposedout/src/index.jswithout an export map even though its emitted module syntax and implicit CommonJS package mode were incompatible;publint, the strict@arethetypeswrong/coreanalyzer, payload policy checks, and clean ESM/CommonJS consumer installs;format:check, zero-warning lint, coverage, typecheck, andpack:checkscripts;The verifier checks the exact
pnpm packartifact with lifecycle scripts disabled. It rejects tests, uncompiled TypeScript, compiler caches, and lockfiles; validates package identity and required root files; resolves declarations under every strict Node/bundler mode; and imports/requires the installed tarball from a clean consumer.Dependency Review initially identified eight low-Scorecard development transitive packages. Human review traced six to the ATTW presentation CLI, so the implementation now calls the same latest 0.18.5 core analyzer directly and fails on every reported problem. This removes 25 unnecessary packages and leaves only three reviewed build/check-tool transitive warnings (
publint→sade/mri, andtsdown→tree-kill), with zero known vulnerabilities and no runtime dependencies added.Impact
Consumers receive working, typed ESM and CommonJS entry points instead of the previous ambiguous package shape. Future packages can adopt the same
pack:checkcontract incrementally, while CI and release workflows automatically enforce every implemented check.No package version was bumped, tagged, or published. Release versions remain deferred to the coordinated final program release train. No service runtime, CORS, CSP, or public-origin behavior changed.
Validation
pnpm --filter @bsv/amountinator buildpnpm --filter @bsv/amountinator format:checkpnpm --filter @bsv/amountinator lintpnpm --filter @bsv/amountinator typecheckpnpm --filter @bsv/amountinator test:coverage— 11/11 tests, 0 skipped; 77.41% statements, 71.68% branchespnpm --filter @bsv/amountinator pack:check— payload, publint, strict ATTW core, clean ESM/CJS consumerspnpm health:check— 24/24 controls; 131 known findings, 0 control errorspnpm build— all 36 non-root workspace projectspnpm -r --if-present --filter '!@bsv/ts-stack' run pack:checkpnpm conformance— 74 files / 6,650 vectors, 0 parse/structure errorspnpm docs:build— 95 routes / 100 built HTML filespnpm check-versionspnpm license:checkpnpm license:pack-check— all 30 public package tarballspnpm audit --audit-level=low— no known vulnerabilitiesgit diff --checkLocal
pnpm codegen:checkcannot complete on this Mac becauseuvis unavailable after the OpenAPI TypeScript generation step; the hosted reproducible Codegen workflow remains required before merge.