question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItΒ collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Linting --with-deps does not work on Nx 12.8

See original GitHub issue

Current Behavior

Linting a project and all its dependencies does not work.

Expected Behavior

Linting a project and all its dependencies should work. I believe this is a regression. Even if --with-deps is deprecated, it should still work until Nx 14.

Steps to Reproduce

  1. Clone nx-examples repo
  2. Run yarn
  3. yarn nx lint cart --with-deps

This issue may not be prioritized if details are not provided to help us reproduce the issue.

Failure Logs

$ nx lint cart --with-deps

DEPRECATION WARNING: --with-deps is deprecated and it will be removed in v14.
Configure target dependencies instead: https://nx.dev/latest/angular/core-concepts/configuration#target-dependencies.


>  NX  Running target lint for project cart and 8 task(s) that it depends on.


β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”β€”

> nx run shared-jsxify:lint

Linting "shared-jsxify"...

All files pass linting.


> nx run shared-product-types:lint

Linting "shared-product-types"...

All files pass linting.

Unexpected error:
TypeError: Cannot read property 'tags' of undefined
    at C:\Users\agokhale\source\nx-examples\node_modules\@nrwl\linter\src\executors\eslint\hasher.js:16:75
    at Array.map (<anonymous>)
    at C:\Users\agokhale\source\nx-examples\node_modules\@nrwl\linter\src\executors\eslint\hasher.js:16:44
    at Generator.next (<anonymous>)
    at fulfilled (C:\Users\agokhale\source\nx-examples\node_modules\tslib\tslib.js:114:62)
    at processTicksAndRejections (internal/process/task_queues.js:93:5)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Environment

  Node : 14.16.1
  OS   : win32 x64
  yarn : 1.22.5

  nx : Not Found
  @nrwl/angular : 12.8.0
  @nrwl/cli : 12.8.0
  @nrwl/cypress : 12.8.0
  @nrwl/devkit : 12.8.0
  @nrwl/eslint-plugin-nx : 12.8.0
  @nrwl/express : Not Found
  @nrwl/jest : 12.8.0
  @nrwl/linter : 12.8.0
  @nrwl/nest : Not Found
  @nrwl/next : Not Found
  @nrwl/node : Not Found
  @nrwl/nx-cloud : 12.3.10
  @nrwl/react : 12.8.0
  @nrwl/schematics : Not Found
  @nrwl/tao : 12.8.0
  @nrwl/web : 12.8.0
  @nrwl/workspace : 12.8.0
  @nrwl/storybook : 12.8.0
  @nrwl/gatsby : Not Found
  typescript : 4.3.5

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
nelsond6commented, Oct 19, 2021

@maxisam - yeah it did the same for me. Both --with-deps or using targetDependencies ends up in the same error. The good news is this is fixed in NX 13!

1reaction
nelsond6commented, Oct 13, 2021

@maxisam Its being deprecated because now you can define targetDependencies. You can read more about it at https://nx.dev/l/r/core-concepts/configuration and under the Target Dependencies section.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Linting with nx workspace not working Β· Issue #1094 - GitHub
We have just migrated over to using the Angular CLI with an nx workspace, and we are having trouble getting any sort of...
Read more >
@nrwl/linter - NPM Package Overview - Socket
The Linter plugin for Nx contains executors, generators and utilities used for linting JavaScript/TypeScript projects within an Nx workspace.
Read more >
Core Performance Improvements, Webpack 5, React Native ...
The Nx team is always focused on performance from the core of the build ... workspaces and to report any issues through the...
Read more >
@nrwl/linter - npm
The Linter plugin for Nx contains executors, generators and utilities used for linting JavaScript/TypeScript projects within an Nx workspace.
Read more >
@nrwl/linter | Nx
The Linter plugin contains executors, generator, plugin and utilities used for linting JavaScript/TypeScript projects within an Nx workspace.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found