-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Failed to resolve plugin when using pnpm custom virtual-store-dir #61584
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
Comments
We don't have support for |
@RyanCavanaugh Any workarounds to suggest? |
IIRC a plugin path can be a relative filename, so you could specify it that way (e.g. |
Tried it, but it seems not the right solution ![]() |
Nope, see TypeScript/src/server/editorServices.ts Lines 5435 to 5442 in 0a1aa6d
|
To advise further I'd probably need to know why you're using a custom module location in the first place; this isn't a very common scenario so there might be other constraints at play. |
🔎 Search Terms
pnpm virtual-store-dir plugin resolve
🕗 Version & Regression Information
⏯ Playground Link
No response
💻 Code
https://codesandbox.io/p/devbox/5t3rgv
🙁 Actual behavior
see
.vscode/settings.json
:and
.npmrc
:and tsconfig.json:
Using workspace version of typescript with custom pnpm virtual-store-dir fails to load plugins
open tsserver log
and select commandThe problem is that path to tsserver is resolved to the custom pnpm virtual-store-dir and it is impossible to resolve path to plugin from it.
The path comes from here https://github.com/microsoft/TypeScript/blob/main/src/server/project.ts#L2109
Why it does not return
node_modules/typescript/lib
and instead return/root/.cache/pnpm-virtual-store/[email protected]/node_modules/typescript/lib/typescript.js/../../..
?🙂 Expected behavior
Plugin starts correctly using pnpm custom virtual-store-dir
Additional information about the issue
No response
The text was updated successfully, but these errors were encountered: