angular-google-maps
angular-google-maps copied to clipboard
Trying to upgrade to Angular 11 gives incompatible peer dependency errors
Issue description
Project is on Angular 10. Trying to upgrade to Angular 11, but getting incompatible peer dependency errors from agm. They don't seem to be resolved by upgrading agm to 1.1.0.
Steps to reproduce and a minimal demo of the problem
$ ng update @angular/core @angular/cli [...] Package "@agm/core" has an incompatible peer dependency to "@angular/common" (requires "^6.0.0 || ^7.0.0 || ^8.0.0" (extended), would install "11.2.7"). Package "@agm/core" has an incompatible peer dependency to "@angular/core" (requires "^6.0.0 || ^7.0.0 || ^8.0.0" (extended), would install "11.2.7"). [...]
angular-google-maps, Angular, & any other relevant dependency versions
Angular: 10.2.1 agm: 1.0.0
Possible duplicate of https://github.com/SebastianM/angular-google-maps/issues/1932 but with ng (yarn) instead of npm?
Hi @michelle-arzul
It seems that this project is not maintained any more. That's why it has out-dated Angular version requirements (not greater than 8.0).
But you can always skip all these version checks:
ng update @angular/cli @angular/core --force
the latest version 3.0.0-beta.0 work fine with angular 11
the latest version
3.0.0-beta.0work fine with angular 11
Yes, it works without issues but it contains outdated requirement about Angular version (version <=8) and that aborts migration using ng update
Any solution found.
$ npm install @agm/core npm ERR! code ERESOLVE npm ERR! ERESOLVE unable to resolve dependency tree npm ERR! npm ERR! While resolving: [email protected] npm ERR! Found: @angular/[email protected] npm ERR! node_modules/@angular/common npm ERR! @angular/common@"~11.2.11" from the root project npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer @angular/common@"^9.1.0 || ^10.0.0" from @agm/[email protected] npm ERR! node_modules/@agm/core npm ERR! @agm/core@"*" 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. npm ERR! npm ERR! See /home/aravind/.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in: npm ERR! /home/aravind/.npm/_logs/2021-04-30T11_22_57_346Z-debug.log
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Actually same issue with Angular 12 :
npm install @agm/core
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: @angular/[email protected]
npm ERR! node_modules/@angular/common
npm ERR! @angular/common@"~12.2.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer @angular/common@"^9.1.0 || ^10.0.0" from @agm/[email protected]
npm ERR! node_modules/@agm/core
npm ERR! @agm/core@"*" 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.
npm ERR!
npm ERR! /.npm/eresolve-report.txt for a full report.
npm ERR! A complete log of this run can be found in:
npm ERR! .npm/_logs/2021-10-18T15_19_36_748Z-debug.log
same issue with angular 13
- Install this package with --legacy-peer-deps flag
My advice is to migrate to Angular Material Google Map which offers similar functionality
My advice is to migrate to Angular Material Google Map which offers similar functionality
Thanks for the advice! I'll try it
npm ERR! code ERESOLVE npm ERR! ERESOLVE could not resolve npm ERR! npm ERR! While resolving: @agm/[email protected] npm ERR! Found: @angular/[email protected] npm ERR! node_modules/@angular/common npm ERR! @angular/common@"11.2.14" from the root project npm ERR! peer @angular/common@"^11.0.0 || ^12.0.0-0" from @angular/[email protected] npm ERR! node_modules/@angular/cdk npm ERR! @angular/cdk@"11.0.0" from the root project npm ERR! peer @angular/cdk@"11.0.0" from @angular/[email protected] npm ERR! node_modules/@angular/material npm ERR! @angular/material@"11.0.0" from the root project npm ERR! 1 more (@angular/material-moment-adapter) npm ERR! 15 more (@angular/flex-layout, @angular/forms, ...) npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer @angular/common@"^6.0.0 || ^7.0.0 || ^8.0.0" from @agm/[email protected] npm ERR! node_modules/@agm/core npm ERR! @agm/core@"1.1.0" from the root project npm ERR! npm ERR! Conflicting peer dependency: @angular/[email protected] npm ERR! node_modules/@angular/common npm ERR! peer @angular/common@"^6.0.0 || ^7.0.0 || ^8.0.0" from @agm/[email protected] npm ERR! node_modules/@agm/core npm ERR! @agm/core@"1.1.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. npm ERR! npm ERR! npm ERR! For a full report see: npm ERR! C:\Users\LENOVO\AppData\Local\npm-cache_logs\2023-01-22T13_36_01_233Z-eresolve-report.txt
npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\LENOVO\AppData\Local\npm-cache_logs\2023-01-22T13_36_01_233Z-debug-0.log