You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit ee61e32
Browse filesBrowse the repository at this point in the historyBrowse files
fix(@angular/cli): handle bun registry error output and 404 detection
Unlike npm, `bun pm view` does not emit `npm ERR! code E404` or nested JSON error objects with a `code` property when a package, version, or dist-tag is missing from the registry. Instead, missing packages produce plain-text HTTP status lines on `stderr` (such as `404 Not Found: ...`), while missing versions or dist-tags produce flat JSON objects on `stdout` with a string `error` field (such as `{ "error": "No matching version found" }`). Because `parseNpmLikeError` did not recognize either format, querying a non-existent package or version under Bun threw an unhandled `PackageManagerError` instead of returning `null`.
This change introduces a dedicated `parseBunError` parser for the `bun` package manager descriptor that extracts structured error codes from both Bun's JSON error payloads and plain-text HTTP status messages, normalizing not-found responses to `E404`.
(cherry picked from commit 322777d)
0 commit comments