-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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
CLI: Fix spawning child processes on windows #19019
Conversation
… as executable, so invoke these commands as shell commands
@storybookjs/angular — Mind taking a look at this one? 🙏 |
This looks like the same as what I did to fix this on Windows and Stackblitz in #16728, but I missed #18140 that removed my change. So, this change should fix Windows again, but I am not sure if it will reintroduce another issue. I don't have a macOS to try and reproduce #18140, but I can try to reproduce it on Windows and WSL later. |
@Marklb it looks like you fix only angular compodoc calls, but library has many calls via npx, that can also fail in windows. I think this PR wouldn't create any new issues. |
@Delagen that is correct that this applies the change to more places, I just meant the fix itself being the same. This change seems like a higher priority than #18140, since it seems to be avoided by not putting the project or Compodoc output path in a directory where the path contains a space. If I understand what #18140 was for, I think it is fixing a problem where a file in the workspace itself contains a space. So the fix to just alter the path to be relative in #17334 would not fix it. That issue may not be something necessary for us to fix anyway. It references compodoc/compodoc#1222, so it may be a Compodoc issue. I am not sure if |
@Marklb No issues with latest compodoc on Windows 11. At least in my project does not occur any. Yes. If project path contains spaces error occurs, but I think path must be quoted manually. And i think it a less issue than not work at all. I made argument as const finalCompodocArgs = [
'compodoc',
// Default options
...(hasTsConfigArg(compodocArgs) ? [] : ['-p', tsConfigPath]),
'-d',
JSON.stringify(`${context.workspaceRoot}`),
...compodocArgs,
]; So it works, but I am not sure on another platforms |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue: #19020
node.js modules .bin commands does not appear available as executable, so invoke these commands as shell commands
What I did
Create angular-cli project
Add storybook 7 version
Cause NOENT error when running compodoc via npx
How to test
If your answer is yes to any of these, please make sure to include it in your PR.