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

[Feature] Option to Disable self-references #3256

Closed
dan-cooke opened this issue Aug 9, 2021 · 2 comments · Fixed by #3332
Closed

[Feature] Option to Disable self-references #3256

dan-cooke opened this issue Aug 9, 2021 · 2 comments · Fixed by #3332
Assignees
Labels
enhancement New feature or request

Comments

@dan-cooke
Copy link

Following on from the suggestion made here #3206 (comment) by @larixer

Problem

When using the node-linker and running yarn workspaces focus - a "self-reference" symlink is placed in the node_modules of each workspace.

packages/
    - A
       - node_modules 
            - A -> symlink back to packages/A

This is problematic in some cases where symlinks are traversed endlessly.

For example serverless will encounter an out of memory exception with this self-reference link.

Proposal

Add an option to .yarnrc.yml

disableSelfLink: true
@elliotdickison
Copy link

elliotdickison commented Sep 3, 2021

FWIW I ran into this trying to do a production build of a react-native Android app in a yarn monorepo. The PR will solve the problem for me nicely.

@missing1984
Copy link
Contributor

ran into issue in my setup as well. I would even argue the default behavior should be no self-reference links. people can enable it when necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
4 participants