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

I got error while running yarn :error Workspaces can only be enabled in private projects #13

Open
vaibhavpnimkar opened this issue Oct 7, 2023 · 5 comments
Labels
bug Something isn't working

Comments

@vaibhavpnimkar
Copy link

Found a bug? Please fill out the sections below. 👍

Issue Summary

I encountered an issue related to Yarn workspaces when setting up the development environment for the Review App API project. This issue prevented me from successfully installing project dependencies. However, I was able to resolve it with the help of the community.

Steps to Reproduce

  1. Cloned the Review App API repository.
  2. Attempted to install project dependencies using yarn.
  3. Encountered an error related to Yarn workspaces and the project not being marked as private.

Any other relevant information. For example, why do you consider this a bug and what did you expect to happen instead?

Actual Results

I received an error message indicating that Yarn workspaces could only be enabled in private projects. This prevented me from installing the project's dependencies using yarn.

Expected Results

I expected to be able to install the project's dependencies using yarn without encountering any Yarn workspaces-related errors.

Solution:

To resolve this issue and successfully set up the development environment for the Review App API project, follow these steps:

  1. Ensure Your Project is Marked as Private: Open the package.json file in the root directory of your project and add the "private": true property if it's not already present:

    "private": true
    
    
@vaibhavpnimkar vaibhavpnimkar added the bug Something isn't working label Oct 7, 2023
@vaibhavpnimkar
Copy link
Author

i would like to add this contributing.md if any body is getting any error related to yarn installation so that it can help others who are facing same issue and i would like to create a new section troubleshooting yarn installation my machine was specifiically ubuntu 22(LTS)

@vaibhavpnimkar
Copy link
Author

i have made a pull request plz review it @piyushgarg-dev

@ghost
Copy link

ghost commented Oct 8, 2023

Hii @vaibhavpnimkar I also run ubuntu 22(LTS) and in my package.json there is no "private": true but the project started normally in my local machine. May be you can delete the folder, current docker build and clone and build the docker image again.

@vaibhavpnimkar
Copy link
Author

Now it is running

@vaibhavpnimkar
Copy link
Author

for some people it works without any changes but for me it works after adding package:/* and private:true in package.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant