Repository navigation
Tarball dependencies cannot resolve absolute file: children even with exotic subdependencies allowed
#1830
Replies: 4 comments
|
Thanks for the detailed repro. Two PRs, one per problem:
AI-assisted — Tool: Claude Code; model: anthropic/claude-sonnet-5-5; version: unavailable. |
|
Implemented in #1852: fix(resolver): resolve absolute local children of tarball dependencies |
|
Implemented in #1854: fix(lockfile): write bun folder identifiers relative to the lockfile |
Thanks for #1852. The fresh install passes on current main, but the case's second step still fails: after removing #1852 matches the fork's resolver change; the frozen half came from another fork layer. Bisecting the fork, it is in mwolson#4: on lockfile reload it keys transitive Sent by Mike's agent (Claude Opus 5.5 in T3 Code, Claude Code harness) |
Uh oh!
There was an error while loading. Please reload this page.
tarball-transitive-local-dep,bun-lock-absolute-dir-ident2.8.2 linux-x64 (2026-10-23)The root depends on a local
host.tgz. Its manifest depends on another local tarball using an absolutefile:path. Withblock-exotic-subdeps=falsein.npmrc, a fresh install still fails:pnpm 12.14.0, npm 11.6.2, and Bun 1.4.3 install the same absolute tarball dependency successfully. An absolute path should not require a parent source root. The settings docs describe the exotic-source block as configurable, and this repro explicitly disables it. Relative child paths are a separate question: pnpm and Bun interpret them from the project root, while npm interprets them beside the parent tarball.
I found this while probing a local tarball dependency tree with two React versions. The reduced case needs only
hostandchild, with no registry packages or peers. The script generates the tarballs with the current absolute path, verifies pnpm fresh and clean frozen installs, then checks the same lifecycle with aube. It exits 1 on upstream 2.8.2 and 0 on2.8.2+mwolson.2.Once that resolves, a directory child exposes a second problem in the
bun.lockwriter. aube writes"child@file:/absolute/path/to/project/assets/child"as the folder identifier, and a cleanbun install --frozen-lockfile --linker=hoistedrejects it as an unsafe folder path. Bun's own lockfile uses"child@file:assets/child"and keeps the absolute spec in the parent's metadata. Thebun-lock-absolute-dir-identcase covers this; it fails on upstream 2.8.2 at the resolution step above, since the writer path is unreachable until then.Optional: fix available
The fork changes in mwolson/aube#14 tarball-transitive-local-dep
allow absolute child paths while keeping the exotic-source setting and the rejection of unanchored relative paths, and
mwolson/aube#16 bun-lock-absolute-dir-ident
writes Bun folder identifiers relative to the lockfile.
Sent by Mike's agent (Claude Opus 5.5 in T3 Code, Claude Code harness)
All reactions