Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ng update breaks on "private" packages #28834

Open
SanderElias opened this issue Nov 11, 2024 · 1 comment
Open

ng update breaks on "private" packages #28834

SanderElias opened this issue Nov 11, 2024 · 1 comment
Labels
area: @angular/cli freq1: low Only reported by a handful of users who observe it rarely ng update DX severity3: broken type: bug/fix

Comments

@SanderElias
Copy link

SanderElias commented Nov 11, 2024

Command

update

Description

I'm unsure if this is a regression. But when there is a "private" package in an angular project, ng update fails to run.

Minimal Reproduction

To reproduce:

# use an "old" version to get started
npx @angular/[email protected] new DemoPackageIssue
cd DemoPackageIssue
# add a package from the deno std library (not really private..)
npx jsr add @std/toml
# try to upgrade:
npx ng update

Or manually add the package to the package.json like this:

  "dependencies": {
    "@angular/animations": "^18.1.0",
    ...
    "@std/toml": "npm:@jsr/std__toml@^1.0.1",
  },

Exception or Error

Using package manager: npm
Collecting installed dependencies...
Found 28 dependencies.
✖ Migration failed: 404 Not Found - GET https://registry.npmjs.org/@std%2ftoml - Not found
  See "/tmp/ng-f4tUqx/angular-errors.log" for further details.

Image

Your Environment

I didn't test it with anything older as 18.0, but I suspect _all_ versions have this issue. 
At least 19-rc.1 still has the problem

Anything else relevant?

This is an unneeded restriction. When there are packages in the package.json that Angular can't 'trace' it should be safe to ignore them. Erroring out is highly inconvenient.

@antonioconselheiro
Copy link

This issue can be reproduced in this repository: https://github.com/antonioconselheiro/bug-ng-update-with-jsr-dependencies
Not only private packages, but any package from jsr throw error.

@alan-agius4 alan-agius4 added freq1: low Only reported by a handful of users who observe it rarely severity3: broken ng update DX labels Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: @angular/cli freq1: low Only reported by a handful of users who observe it rarely ng update DX severity3: broken type: bug/fix
Projects
None yet
Development

No branches or pull requests

4 participants