Skip to content

Conversation

meeroslav
Copy link
Contributor

Current Behavior

Workspace projects defined as dependencies in the package.json are not discovered by getTouchedNpmPackages since they don't exist on the externalNodes, causing affected command to fail.

Expected Behavior

Workspace projects defined as dependencies in the package.json should be discovered by getTouchedNpmPackages by looking at nodes and returned within touchedProjectLocators

Related Issue(s)

Fixes #13668

@meeroslav meeroslav added the scope: core core nx functionality label Dec 9, 2022
@meeroslav meeroslav self-assigned this Dec 9, 2022
@vercel
Copy link

vercel bot commented Dec 9, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
nx-dev ✅ Ready (Inspect) Visit Preview Dec 12, 2022 at 3:58PM (UTC)

@timfishercs
Copy link

timfishercs commented Dec 12, 2022

I think potentially this code needs updating as well Error: Invalid project name is detected: "npmPackage"

/node_modules/nx/src/project-graph/affected/affected-project-graph.js:63:15

@meeroslav
Copy link
Contributor Author

@timfishercs, can you show me your npm-packages.js? The npmPackage is only used as a parameter name. I don't see how it could end up in touchedProjects in affected-project-graph.js.

@meeroslav meeroslav merged commit 65ecd9c into nrwl:master Dec 13, 2022
FrozenPandaz pushed a commit that referenced this pull request Dec 19, 2022
@meeroslav meeroslav deleted the fix-13668 branch March 14, 2023 22:17
@github-actions
Copy link
Contributor

This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 19, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

scope: core core nx functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TypeError: Cannot read properties of undefined (reading 'name') when running nx affected

4 participants