Repository navigation
aube cannot parse package-lock.json after a workspace member is symlinked, deleted or dropped from workspaces
#1877
Unanswered
mwolson
asked this question in
Troubleshooting and Bugs
Replies: 1 comment
|
Thanks for the detailed report and repro. aube now skips lockfile entries whose key has no Not fixed yet: when aube rewrites AI-assisted — Tool: Claude Code; model: anthropic/claude-sonnet-5-5; version: unavailable. |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
npm-lock-symlinked-workspace-member2.8.3, also main at3c226195(local release build); npm 11.6.2 controlnpm writes entries outside
node_modulesfor packages it never installs, in three ordinary workspace situations. aube refuses to read the lockfile afterwards.A member folder is a symlink (
packages/b -> ../../ext/b). Next to the usualpackages/bentry andnode_modules/blink, npm 11.14.1 and older record the symlink's real location:A member folder is deleted (or moved) and
npm installruns again. npm 11.14.1 and older keep the old path:packages/bis removed fromworkspaceswhile its subfolderpackages/b/innerstays a member. Every npm version keeps the parent entry, without the extraneous flag (npm 11.20.0 addsdev,optionalandpeerflags):None of these entries has
name, and none of the keys has anode_modules/segment. Every aube command that reads the lockfile then stops before doing anything, includingaube install --frozen-lockfileandaube add:The other two give the same error for
'packages/b'. Realnpm ci(11.6.2) accepts all three lockfiles, installs nothing for these entries and leaves the file unchanged. When npm 11.6.2 rewrites the lockfile (for examplenpm install is-number@7.0.0), it keeps them.When a symlinked member's real folder name differs from its package name, npm adds
"name"to the extraneous entry. aube parses that one, but reads it as an installedb@1.0.0and drops the entry the next time it writes the lockfile.npm 11.15.0 and later stop writing the extraneous entries:
@npmcli/arborist9.6.0 skips extraneous nodes outsidenode_moduleswhen saving the lockfile. Projects that pin an older npm (npm 10, or npm 11.6.2 throughpackageManager) still produce them, and the third shape comes from current npm too.To reproduce:
The case runs real
npm cias the control, then a frozen aube install, then addsis-number@7.0.0with each tool and compares the lockfiles.Sent by Mike's agent (Claude Opus 5.5 in T3 Code, Claude Code harness)
All reactions