Isolate fails due to missing pnpm
DanielBaulig opened this issue · 5 comments
The documentation says pnpm is recommended, but not required. I am using npm.
info Using isolate-package version 1.16.0
/bin/sh: pnpm: command not found
Error: Command failed: pnpm --version
/bin/sh: pnpm: command not found
at genericNodeError (node:internal/errors:983:15)
at wrappedFn (node:internal/errors:537:14)
at checkExecSyncError (node:child_process:889:11)
at execSync (node:child_process:961:15)
at getVersion (file:///Users/dev0/projects/esplink/esplink-mono/node_modules/isolate-package/src/lib/package-manager/helpers/infer-from-files.ts:30:18)
at inferFromFiles (file:///Users/dev0/projects/esplink/esplink-mono/node_modules/isolate-package/src/lib/package-manager/helpers/infer-from-files.ts:12:21)
at detectPackageManager (file:///Users/dev0/projects/esplink/esplink-mono/node_modules/isolate-package/src/lib/package-manager/index.ts:36:46)
at isolate (file:///Users/dev0/projects/esplink/esplink-mono/node_modules/isolate-package/src/isolate.ts:106:26)
at run (file:///Users/dev0/projects/esplink/esplink-mono/node_modules/isolate-package/src/isolate-bin.ts:9:3)
@DanielBaulig pnpm should only be used when it's detected as your package manager. I have tried it by using the npm branch of mono-ts and renaming my pnpm executable, but I can not reproduce the issue.
Please add a isolate-package.config.json
to the root of the package you are isolating, with { logLevel: "debug" }
and post the console output here.
Maybe also check the packageManager
field in your package manifest. IIRC that's the first thing used in detecting the package manager, and after that it looks at the lockfile.
I'm sorry - I noticed it this issue late, when already created this one: #92
I explained the reasons there
@0x80 Haven't gotten around to any of the other steps you recommended, but the exact same line as in #92 throws for me. There's no conditional or anything in that code path. It just iterates over all three package managers and calls them, leading to an exception.
Note that I am using WSL2 on Windows, not native Windows.
Should be solved in 1.17.0