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

NX should not use package.json for in-repo dependencies #29626

Open
3 of 4 tasks
RobertDiebels opened this issue Jan 15, 2025 · 0 comments
Open
3 of 4 tasks

NX should not use package.json for in-repo dependencies #29626

RobertDiebels opened this issue Jan 15, 2025 · 0 comments

Comments

@RobertDiebels
Copy link

RobertDiebels commented Jan 15, 2025

Current Behavior

Most tools correctly assume that the dependencies listed in a package.json are located on a artifact registry which need to be retrieved.
As a result they will attempt to retrieve those dependencies from the specified artifact registry. Some of these tools will fail gracefully, and others not so much. For instance, any tool using pnpm update --recursive on a NX mono-repo will crash (not so gracefully).

In either case, these tools correctly assume that the listed dependencies should be in a artifact registry. This means that NX is misusing the package.json to declare in-repo dependencies between projects.

Expected Behavior

I would expect that NX:

  • Does not use the package.json file to list in-repo dependencies, unless the in-repo projects are published and retrieved (which would be odd.. but possible).
  • Provides some other means of tracking in-repo dependencies (for instance through the project.json).

GitHub Repo

No response

Steps to Reproduce

  1. Run pnpm update --recursive on a mono-repo with in-repo dependencies.

Nx Report

N/A

Failure Logs

N/A

Package Manager Version

pnpm@9.3.0

Operating System

  • macOS
  • Linux
  • Windows
  • Other (Please specify)

Additional Information

No response

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

No branches or pull requests

1 participant