A zonejs dependency error in package.json

Discussão em 'Angular' iniciado por oc-2, Novembro 14, 2024.

  1. oc-2

    oc-2 Guest

    I experienced this bug while running npm install I found out the error was caused in a few PR's that my dependency upgrade tool Snyk had created.


    This is what I see when running npm install:

    npm error code ERESOLVE

    npm error ERESOLVE could not resolve
    npm error
    npm error While resolving: @angular-devkit/build-angular@18.2.11
    npm error Found: @angular/compiler-cli@13.3.12
    npm error node_modules/@angular/compiler-cli
    npm error dev @angular/compiler-cli@"~13.3.0" from the root project
    npm error
    npm error Could not resolve dependency:
    npm error peer @angular/compiler-cli@"^18.0.0" from @angular-devkit/build-angular@18.2.11
    npm error node_modules/@angular-devkit/build-angular
    npm error dev @angular-devkit/build-angular@"^18.2.11" from the root project
    npm error
    npm error Conflicting peer dependency: @angular/compiler-cli@18.2.11
    npm error node_modules/@angular/compiler-cli
    npm error peer @angular/compiler-cli@"^18.0.0" from @angular-devkit/build-angular@18.2.11
    npm error node_modules/@angular-devkit/build-angular
    npm error dev @angular-devkit/build-angular@"^18.2.11" from the root project
    npm error
    npm error Fix the upstream dependency conflict, or retry
    npm error this command with --force or --legacy-peer-deps
    npm error to accept an incorrect (and potentially broken) dependency resolution.
    npm error
    npm error
    npm error For a full report see:
    npm error /home/runner/.npm/_logs/2024-11-12T23_36_23_968Z-eresolve-report.txt
    npm notice
    npm notice New minor version of npm available! 10.8.1 -> 10.9.0
    npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.9.0
    npm notice To update run: npm install -g npm@10.9.0
    npm notice
    npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2024-11-12T23_36_23_968Z-debug-0.log


    I am expecting not to see npm errors when running npm commands. This is what I see when running npm install:

    npm error code ERESOLVE

    npm error ERESOLVE could not resolve
    npm error
    npm error While resolving: @angular-devkit/build-angular@18.2.11
    npm error Found: @angular/compiler-cli@13.3.12
    npm error node_modules/@angular/compiler-cli
    npm error dev @angular/compiler-cli@"~13.3.0" from the root project
    npm error
    npm error Could not resolve dependency:
    npm error peer @angular/compiler-cli@"^18.0.0" from @angular-devkit/build-angular@18.2.11
    npm error node_modules/@angular-devkit/build-angular
    npm error dev @angular-devkit/build-angular@"^18.2.11" from the root project
    npm error
    npm error Conflicting peer dependency: @angular/compiler-cli@18.2.11
    npm error node_modules/@angular/compiler-cli
    npm error peer @angular/compiler-cli@"^18.0.0" from @angular-devkit/build-angular@18.2.11
    npm error node_modules/@angular-devkit/build-angular
    npm error dev @angular-devkit/build-angular@"^18.2.11" from the root project
    npm error
    npm error Fix the upstream dependency conflict, or retry
    npm error this command with --force or --legacy-peer-deps
    npm error to accept an incorrect (and potentially broken) dependency resolution.
    npm error
    npm error
    npm error For a full report see:
    npm error /home/runner/.npm/_logs/2024-11-12T23_36_23_968Z-eresolve-report.txt
    npm notice
    npm notice New minor version of npm available! 10.8.1 -> 10.9.0
    npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.9.0
    npm notice To update run: npm install -g npm@10.9.0
    npm notice
    npm error A complete log of this run can be found in: /home/runner/.npm/_logs/2024-11-12T23_36_23_968Z-debug-0.log

    Continue reading...

Compartilhe esta Página