Fix lockfile drift and missing dep from content-types consolidation#78109
Merged
Conversation
Removes four extraneous workspace entries left in package-lock.json by #78059 (packages/user-post-types, packages/user-taxonomies, routes/post-types, routes/taxonomies) and adds the missing @wordpress/base-styles dependency to the new @wordpress/content-types package. npm does not prune extraneous workspace entries on its own (npm/cli#5463), so these had to be removed by hand.
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
|
Size Change: 0 B Total Size: 7.92 MB ℹ️ View Unchanged
|
Mamaduka
approved these changes
May 9, 2026
Member
|
Thank you for the fix @manzoorwanijk and @Mamaduka 🙌 |
Member
Author
|
The fix to npm CLI has been merged - npm/cli#9330, so we should not have such issues in future once we have the required npm version. |
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.
What?
Follow up to #78059.
Cleans up two issues left behind by the content-types consolidation:
package-lock.jsonthat were marked"extraneous": trueafter the rename/removal of workspaces in Experiment: Content types single route and package #78059.@wordpress/base-stylesdependency to the new@wordpress/content-typespackage.Why?
#78059 deleted two workspaces (
packages/user-post-types,packages/user-taxonomies) and renamed two more (routes/post-types→routes/post-types-list,routes/taxonomies→routes/taxonomies-list), but the corresponding entries inpackage-lock.jsonwere never pruned — they remained in the lockfile flagged"extraneous": true.This is a known limitation in npm itself: when a workspace is removed or renamed, npm marks the lockfile entry as extraneous instead of pruning it, and no
npmCLI command (install,install --package-lock-only,prune,dedupe,uninstall -w) actually removes it. See npm/cli#5463 and related npm/cli#2056, npm/cli#3141. The only reliable fixes are regenerating the lockfile from scratch or editing it directly.Separately, while reviewing the new
@wordpress/content-typespackage I noticed it was missing a@wordpress/base-stylesdependency that it relies on. Adding it here so it doesn't drift further.How?
package-lock.json(packages/user-post-types,packages/user-taxonomies,routes/post-types,routes/taxonomies). The newly-named workspaces (packages/content-types,routes/post-types-list,routes/taxonomies-list) are already present in the lockfile and are unchanged."@wordpress/base-styles": "file:../base-styles"topackages/content-types/package.json.Testing Instructions
npm install— it should complete without rewriting the lockfile or warning about extraneous workspaces.npm run buildand verify the build still passes.Testing Instructions for Keyboard
N/A — no UI changes.
Screenshots or screencast
N/A — lockfile and dependency manifest changes only.
Use of AI Tools
Claude Code (Opus 4.7) was used to draft this PR description.