Repository navigation
fix: ship complete type declarations from version, notes, publish and release - #712
Merged
Merged
Conversation
… release The `external: [/^[^.]/]` pattern in version's, notes' and publish's tsup configs also matched the resolved absolute paths the declaration build checks, so their own modules were left as imports of `.ts` files missing from dist, and every export typed as `any` for other packages. The pattern now skips absolute paths and @releasekit/*. Release declares types but built none, so it now builds them. With real types, release's typecheck caught two bugs, fixed here: - `backfill --config` ignored the path when loading the publish config. - The failure report left out pub.dev results. An integration test now checks every published package's declarations: the declared types file exists, and each import is a file in dist or a declared dependency. Closes #711 Closes #710 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
Standing release PR: #614 · v0.42.0 queued (4 packages) · open 82d 21h 31m · ✅ ready to merge Release Preview — v0.41.2 → v0.41.3
These changes will be added to the release PR (#614) when merged: Changelogmonorepo 0.41.2 → 0.41.3
After merge — predicted release
Updated automatically by ReleaseKit |
…result A hybrid package's crate or Dart package can have its own name (`my_package` next to npm's `my-package`), and publish results carried only that registry name, so the failure report couldn't match a cargo or pub.dev result to its update and showed a failure as published or not attempted. Each target and result now carries `updatePackageName`, and the ledger matches on it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ttern Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…geName Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Merged
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.
Description
@releasekit/version,notesandpublishshipped type declarations that re-exported from.tsfiles missing fromdist/, so every export typed asanyfor other packages and for npm users.@releasekit/releasedeclaredtypesbut built none.Cause: their tsup configs set
external: [/^[^.]/]to externalize bare package names. The declaration build also checks resolved import paths againstexternal, and a resolved path is absolute (/…/src/config.ts), which that pattern matches, so the packages' own modules were left as imports.Fix:
@releasekit/*:/^(?![./]|[A-Za-z]:[\\/]|@releasekit\/)/. The JS output is byte-identical; only the declarations change.releasebuilds declarations for itsindexentry, inlining the private packages. Its JS output is unchanged by this.commander,zod, …;releaseimports@releasekit/publish, a dependency).Bugs the real types caught in
release, fixed here:backfill --config <path>ignored the path when loading the publish config: it passed(cwd, path)to a function that takes{ cwd, configPath }(backfill --config ignores the path when loading the publish config #710).my_packagenext tomy-package) was never matched to its update. Each publish target and result now carriesupdatePackageName, the version step's name, and the ledger matches on it.backfillread.file/.llmoffreleaseNoteswithout narrowing outfalse(harmless at runtime).Related Issue(s)
Closes #711. Closes #710.
Type of Change
feat— New featurefix— Bug fixdocs— Documentation changerefactor— Code refactoringtest— Adding or updating testschore— Maintenance, dependencies, toolingScope
@releasekit/version@releasekit/notes@releasekit/publish@releasekit/release@releasekit/config@releasekit/coreChecklist
pnpm lint)pnpm test)pnpm typecheck)Testing Notes
test/integration/type-declarations.spec.ts: for every published package that declarestypes, the file exists, and every import in its.d.tsfiles is a file indist/or a declared dependency. Against the old configs it fails for all four packages.backfill --configpasses{ cwd, configPath }to publish'sloadConfig(fails with the old call); a hybrid package's pub.dev result carries its update's name, andbuildLedgermatches it.🤖 Generated with Claude Code


Confidence Score: 5/5
The PR appears safe to merge; the previous failure-report issue is fixed.Summary
The PR fixes shipped type declarations and corrects config loading and publish failure reports.
The previous name-mismatch finding is fixed. No new actionable issues were found in the changes since the last review.
Diagram
%%{init: {'theme': 'neutral'}}%% flowchart LR A["Version update: packageName"] --> B["Registry target: updatePackageName"] B --> C["Publish result: updatePackageName"] C --> D["buildLedger matches the version update"]Reviews (2) · Last reviewed commit: "fix(publish): record the version step's ..." · Reviewed by Greptile