Installation Error: multiple versions of yarn, or using version manager other than NVM

Some people have reported installation problems even though local yarn versions are compatible with the RedwoodJS Node and Yarn engine requirements. (These settings are in the root package.json file.)

For some background, please see this Issue thread:

What may be going on is that different versions of Node and Yarn are being used unexpectedly during the installation bootstrap process. The bootstrap executable is not running inside a specific directory, so you will not be able to configure Node and Yarn versions to use until after the bootstrap is complete. Your system default settings will be used during installation instead. (Some have reported unexpected issues with defaults as well, however.)

First, you should try to uninstall and reinstall yarn. An example with Homebrew:

  • brew update
  • brew uninstall yarn
  • brew install yarn

If you are using a node package manager other than NVM, for example, ā€œNā€, you may need to do something like the following:

  • yarn config set ignore-engines true

Lastly, there are no issues with using npm (or npx) for the installation. The download, extract, config, and package install steps will run correctly. However, you should then run yarn install as the app is dependent on Yarn Workspaces.

Note: if you do bypass engine requirements for installation, you MUST meet the engine requirements and use yarn for Redwood Development. Please set up your directory defaults accordingly.

Helpful background on errors from @fnky via this GitHub Issue:

Just to chime in; the cause of the errors is because there are global modules installed which are incompatible with your current node version. Running yarn create is equivalent to yarn global add , which means that it validates the globally installed packages.

For example; use an old version of node and install a module that targets older node versions and then switch to a newer version and do a global install. This will fail due to incompatible engines, specified by the module.

The issue itself is that yarn create accept arguments like --ignore-engines to have yarn ignore engines as part of the validation.