Skip to content

Remove initialVersions in pre.json - #2117

Merged
bluwy merged 3 commits into
mainfrom
pre-no-initial-versions-take-2
Jun 24, 2026
Merged

Remove initialVersions in pre.json#2117
bluwy merged 3 commits into
mainfrom
pre-no-initial-versions-take-2

Conversation

@bluwy

@bluwy bluwy commented Jun 24, 2026

Copy link
Copy Markdown
Member

#2110 but standalone to main

I've also ported the auto-migration on readPreState, but if we have concerns of this we can also not do this as leaving the property there as is is harmless. The next time they start prerelease with changesets v3, it won't be there anymore.

@changeset-bot

changeset-bot Bot commented Jun 24, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 105f2d9

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 16 packages
Name Type
@changesets/assemble-release-plan Major
@changesets/cli Major
@changesets/pre Major
@changesets/types Major
@changesets/get-release-plan Patch
@changesets/release-utils Patch
@changesets/apply-release-plan Patch
@changesets/changelog-git Patch
@changesets/changelog-github Patch
@changesets/config Patch
@changesets/get-dependents-graph Patch
@changesets/git Patch
@changesets/parse Patch
@changesets/read Patch
@changesets/should-skip-package Patch
@changesets/write Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@codecov

codecov Bot commented Jun 24, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 57.14286% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.42%. Comparing base (b8222e6) to head (105f2d9).

Files with missing lines Patch % Lines
packages/pre/src/index.ts 57.14% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2117      +/-   ##
==========================================
- Coverage   85.52%   85.42%   -0.11%     
==========================================
  Files          66       66              
  Lines        2535     2538       +3     
  Branches      700      700              
==========================================
  Hits         2168     2168              
- Misses        337      340       +3     
  Partials       30       30              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread packages/pre/src/index.ts
// "initialVersions" is not used for a long time, so can directly delete
delete preState.initialVersions;

await outputFile(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

it would be nice to use the editJson here, but given this is like a one-time migration... we probably don't have to

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yeah it'd be nice to reuse that, but we need to figure out how to share it and also needs an update to handle deletions. Let's see if people are getting formatting issues if we do something like this.

@bluwy
bluwy added this pull request to the merge queue Jun 24, 2026
Merged via the queue into main with commit 813bbf3 Jun 24, 2026
10 of 12 checks passed
@bluwy
bluwy deleted the pre-no-initial-versions-take-2 branch June 24, 2026 17:21
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.

3 participants