-
Notifications
You must be signed in to change notification settings - Fork 1k
[Bug?]: Updating from 7.3.0 to 7.4.1 will fail, if there is no npx available #10466
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
@j-tag Thanks for filing this issue. I'll see if I can get to the bottom of it. |
Thank you |
**Problem** Fixes #10466. During `yarn rw upgrade` we check the version of `npx` installed. It's entirely possible that `npx` is not available or installed. We only do this check because we have to handle dedupe differently between yarn v1 and yarn >v1. We specify that redwood projects should be using yarn v4 using `"packageManager": "[email protected]"` in the `package.json`. Therefore when following the recommended setup users should not be using yarn v1 in their redwood projects. **Changes** 1. Avoid `npx` version check. 2. Skip dedupe step if for some reason have yarn v1. When this happens we log a warning message to tell the user to run a command manually to dedupe.
**Problem** Fixes #10466. During `yarn rw upgrade` we check the version of `npx` installed. It's entirely possible that `npx` is not available or installed. We only do this check because we have to handle dedupe differently between yarn v1 and yarn >v1. We specify that redwood projects should be using yarn v4 using `"packageManager": "[email protected]"` in the `package.json`. Therefore when following the recommended setup users should not be using yarn v1 in their redwood projects. **Changes** 1. Avoid `npx` version check. 2. Skip dedupe step if for some reason have yarn v1. When this happens we log a warning message to tell the user to run a command manually to dedupe.
**Problem** Fixes #10466. During `yarn rw upgrade` we check the version of `npx` installed. It's entirely possible that `npx` is not available or installed. We only do this check because we have to handle dedupe differently between yarn v1 and yarn >v1. We specify that redwood projects should be using yarn v4 using `"packageManager": "[email protected]"` in the `package.json`. Therefore when following the recommended setup users should not be using yarn v1 in their redwood projects. **Changes** 1. Avoid `npx` version check. 2. Skip dedupe step if for some reason have yarn v1. When this happens we log a warning message to tell the user to run a command manually to dedupe.
**Problem** Fixes #10466. During `yarn rw upgrade` we check the version of `npx` installed. It's entirely possible that `npx` is not available or installed. We only do this check because we have to handle dedupe differently between yarn v1 and yarn >v1. We specify that redwood projects should be using yarn v4 using `"packageManager": "[email protected]"` in the `package.json`. Therefore when following the recommended setup users should not be using yarn v1 in their redwood projects. **Changes** 1. Avoid `npx` version check. 2. Skip dedupe step if for some reason have yarn v1. When this happens we log a warning message to tell the user to run a command manually to dedupe.
So v7.4.2 should have this fix included within it. Of course, this is slightly more difficult because it's the upgrade command itself that has a bug for you. If you do manually upgrade to this new version you should find the upgrade command works fine now - for future upgrades or if you want to "upgrade" to a previous version that too should now work. |
Thank you @Josh-Walker-GM . As you suggested the problem was in the |
Uh oh!
There was an error while loading. Please reload this page.
What's not working?
If I use
yarn rw upgrade
to upgrade from 7.3.0 to 7.4.1 and nonpx
will be available in my$PATH
. I'll get this error:This is because I'm using corepack thus I don't need to install npm/npx separately. But Redwood seems to expect
npx
to be available on my system.I tried on another pc which had npm/npx available globally without corepack and upgrade works without any issues.
How do we reproduce the bug?
You should not have npm/npx through global installation. If you use corepack only, this issue will happen.
What's your environment? (If it applies)
Are you interested in working on this?
The text was updated successfully, but these errors were encountered: