-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug?]: Fail to install turbo
when using nodeLinker: pnpm
with v4
#5165
Comments
This issue reproduces on master:
|
+1 same issue with |
UPD: looks like codesandbox changed how they work with volumes so no need for const {promises: {writeFile}} = require(`fs`);
// Enable `pnpm` nodeLinker
await writeFile('.yarnrc.yml', 'nodeLinker: pnpm');
await packageJson({
devDependencies: {
[`esbuild`]: `0.17.11`,
}
});
try {
await yarn('install')
} catch (err) {
console.error(err)
}
await expect(yarn('esbuild')).rejects.not.toThrow('EACCES') |
And kinda obvious thing, but still want to mention that we are facing it because of different file permissions: Works: ls -l node_modules/.store/@esbuild-darwin-arm64-npm-0.16.17-96c7a38090/node_modules/@esbuild/darwin-arm64/bin
total 17304
-rwxr-xr-x 1 v7rulnik staff 8858802 23 июн 1984 esbuild* Doesn't work: ls -l node_modules/.store/@esbuild-darwin-arm64-npm-0.16.17-96c7a38090/package/bin/
total 17304
-rw-r--r-- 2 v7rulnik staff 8858802 23 июн 1984 esbuild |
I made a mistake here #5165 (comment). For some reason, the error doesn't happen every time so it's better to try to execute the binary directly. So I checked once again and the real problem is content addressing which was introduced in #4586. So the main problem is that we don't reach chmod setting https://github.com/yarnpkg/berry/blob/master/packages/yarnpkg-fslib/sources/algorithms/copyPromise.ts#L109-L112 when @arcanis looks like we should do something different there |
Also, if I change |
@nutstick @georeith if you want you can install version without content addressing yarn set version from sources --repository [email protected]:7rulnik/berry.git --branch fix-pnpm If you are worried about security you can check content via master...7rulnik:berry:fix-pnpm |
Running into the same error with esbuild installation when using |
Bumped into the same issue with vite (it uses esbuild under the hood by default) Could you please fix this issue in pnpn mode in Yarn 4? |
I'll look at that later this week. |
Commands: ``` yarn init -2 -w yarn set version 3.6.4 yarn config set nodeLinker pnpm yarn plugin import interactive-tools yarn plugin import https://mskelton.dev/yarn-outdated/v3 ``` Currently, Vite don't works with yarn 4 - yarnpkg/berry#5165
👀 |
I've just run into this with esbuild after trying to upgrade to Yarn 4 - version 3.7.0 still functions as expected. @arcanis, did you find anything earlier? |
Note: it's necessary to |
…#6066) **What's the problem this PR addresses?** This is the fix for missing executable perms when installing dependencies like turbo and esbuild with pnpm linker (#5165, #5991) Resolves #5165 <!-- Describe the rationale of your PR. --> <!-- Link all issues that it closes. (Closes/Resolves #xxxx.) --> **How did you fix it?** <!-- A detailed description of your implementation. --> Looks like the code was missing for setting permissions for the file copied by pnpm linker into content-addressable store I added `destinationFs.chmodPromise` to `copyFileViaIndex` in `fslib` if the file is not in store (`if (!indexStat)` branch) **Checklist** <!--- Don't worry if you miss something, chores are automatically tested. --> <!--- This checklist exists to help you remember doing the chores when you submit a PR. --> <!--- Put an `x` in all the boxes that apply. --> - [x] I have read the [Contributing Guide](https://yarnpkg.com/advanced/contributing). <!-- See https://yarnpkg.com/advanced/contributing#preparing-your-pr-to-be-released for more details. --> <!-- Check with `yarn version check` and fix with `yarn version check -i` --> - [x] I have set the packages that need to be released for my changes to be effective. <!-- The "Testing chores" workflow validates that your PR follows our guidelines. --> <!-- If it doesn't pass, click on it to see details as to what your PR might be missing. --> - [x] I will check that all automated PR checks pass before the PR gets reviewed. --------- Co-authored-by: Maël Nison <[email protected]>
to work around yarnpkg/berry#5165 until 4.0.3 is released
to work around yarnpkg/berry#5165 until 4.0.3 is released
to work around yarnpkg/berry#5165 until 4.0.3 is released
Self-service
Describe the bug
After upgrading to yarn v4 (canary), when run
yarn install
will lead to the following error onturbo
.When using yarn v3, can be install successfully.
To reproduce
Environment
System: OS: macOS 12.3.1 CPU: (10) arm64 Apple M1 Max Binaries: Node: 18.12.1 - /private/var/folders/bl/b4w8tgms0qdf3g_dp8_8nspr0000gn/T/xfs-cb43a611/node Yarn: 4.0.0-rc.34 - /private/var/folders/bl/b4w8tgms0qdf3g_dp8_8nspr0000gn/T/xfs-cb43a611/yarn npm: 8.19.2 - ~/.nvm/versions/node/v18.12.1/bin/npm
Additional context
No response
The text was updated successfully, but these errors were encountered: