nx icon indicating copy to clipboard operation
nx copied to clipboard

ngrx <> angular -> rxjs version incompatibilities

Open pascalbe-dev opened this issue 3 years ago • 1 comments
trafficstars

Current Behavior

Nx migrate latest updates my Angular, rxjs, ngrx dependencies which results in a version incompatibility. I can no longer run npm install without error.

The same version incompatibility appears when I create a fresh new Angular workspace and add ngrx afterwards.

Expected Behavior

Nx takes care of the version compatibilities and no errors are shown when running updates.

Steps to Reproduce

  1. Create a new workspace via npx create-nx-workspace (use the Angular preset)
  2. Use the nrwl/angular:ngrx generator to add ngrx to the workspace.
  3. Run npm install

Failure Logs

npm ERR! code ERESOLVE npm ERR! ERESOLVE could not resolve npm ERR! npm ERR! While resolving: @ngrx/[email protected] npm ERR! Found: [email protected] npm ERR! node_modules/rxjs npm ERR! rxjs@"~7.4.0" from the root project npm ERR! peer rxjs@"^6.5.3 || ^7.4.0" from @angular/[email protected] npm ERR! node_modules/@angular/common npm ERR! @angular/common@"~14.1.1" from the root project npm ERR! peer @angular/common@"14.1.1" from @angular/[email protected] npm ERR! node_modules/@angular/forms npm ERR! @angular/forms@"~14.1.1" from the root project npm ERR! 4 more (@angular/platform-browser, ...) npm ERR! 4 more (@angular/core, @angular/forms, @angular/router, jasmine-marbles) npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer rxjs@"^6.5.3 || ^7.5.0" from @ngrx/[email protected] npm ERR! node_modules/@ngrx/component-store npm ERR! @ngrx/component-store@"~14.0.0" from the root project npm ERR! npm ERR! Conflicting peer dependency: [email protected] npm ERR! node_modules/rxjs npm ERR! peer rxjs@"^6.5.3 || ^7.5.0" from @ngrx/[email protected] npm ERR! node_modules/@ngrx/component-store npm ERR! @ngrx/component-store@"~14.0.0" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force, or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution.

Environment

Nx Report complete - copy this into the issue template Node : 16.16.0 OS : linux x64 npm : 8.11.0 nx : 14.5.4 @nrwl/angular : 14.5.4 @nrwl/cypress : 14.5.4 @nrwl/detox : Not Found @nrwl/devkit : 14.5.4 @nrwl/eslint-plugin-nx : 14.5.4 @nrwl/express : Not Found @nrwl/jest : 14.5.4 @nrwl/js : 14.5.4 @nrwl/linter : 14.5.4 @nrwl/nest : Not Found @nrwl/next : Not Found @nrwl/node : Not Found @nrwl/nx-cloud : Not Found @nrwl/nx-plugin : Not Found @nrwl/react : Not Found @nrwl/react-native : Not Found @nrwl/schematics : Not Found @nrwl/storybook : 14.5.4 @nrwl/web : 14.5.4 @nrwl/workspace : 14.5.4 typescript : 4.7.4 Community plugins: @ngrx/component-store: 14.0.2 @ngrx/effects: 14.0.2 @ngrx/entity: 14.0.2 @ngrx/router-store: 14.0.2 @ngrx/store: 14.0.2 @ngrx/schematics: 14.0.2 @ngrx/store-devtools: 14.0.2

pascalbe-dev avatar Aug 09 '22 09:08 pascalbe-dev

Here is a showcase repo.

pascalbe-dev avatar Aug 09 '22 09:08 pascalbe-dev

This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context.

github-actions[bot] avatar Mar 22 '23 01:03 github-actions[bot]