Skip to content
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

pnpm dlx <package command> with no further arguments errors with exit code 1 #6698

Closed
ferntheplant opened this issue Jun 21, 2023 · 2 comments · Fixed by #6883
Closed

pnpm dlx <package command> with no further arguments errors with exit code 1 #6698

ferntheplant opened this issue Jun 21, 2023 · 2 comments · Fixed by #6883
Assignees

Comments

@ferntheplant
Copy link

ferntheplant commented Jun 21, 2023

pnpm version:

8.6.3

Code to reproduce the issue:

pnpm dlx create-react-app or pnpm dlx shadcn-svelte

Expected behavior:

pnpm should output the command's default output (usually a help dialog) and exit with code 0 as it does with npx

Actual behavior:

pnpm exits with code 1 and a useless stack trace

Additional information:

Originally discovered with shadcn-svelte

  • node -v prints: v18.16.0
  • Windows, macOS, or Linux?: macOS
@await-ovo
Copy link
Member

I think this is as expected, the exit code of npx create-react-app is also 1:

$ npx create-react-app
Please specify the project directory:
  create-react-app <project-directory>

For example:
  create-react-app my-react-app

Run create-react-app --help to see all options.

$ echo $?
1

@zkochan
Copy link
Member

zkochan commented Jul 30, 2023

We can remove the error stack but the error code is correct. create-react-app exited with 1, so pnpm exits with 1 too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants