Skip to content

fix(@angular/cli): support registry metadata fetching under bun package manager#33369

Open
clydin wants to merge 1 commit into
angular:mainfrom
clydin:fix/bun-registry-metadata
Open

fix(@angular/cli): support registry metadata fetching under bun package manager#33369
clydin wants to merge 1 commit into
angular:mainfrom
clydin:fix/bun-registry-metadata

Conversation

@clydin

@clydin clydin commented Jun 12, 2026

Copy link
Copy Markdown
Member

Bun's pm view command does not support requesting multiple fields at once (e.g. pm view <pkg> dist-tags versions --json), which is required by the default package manager abstraction to fetch package metadata during version compatibility search.

This change introduces a custom getRegistryMetadata handler in the package manager descriptor, allowing individual package managers to override registry metadata fetching entirely. The bun descriptor now implements this by querying dist-tags and versions separately in parallel, and returning the aggregated metadata object.

@clydin clydin added the target: patch This PR is targeted for the next patch release label Jun 12, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces an optional getRegistryMetadata method to the PackageManagerDescriptor interface, allowing package managers like Bun to customize how registry metadata is fetched. For Bun, this method is implemented to query dist-tags and versions separately. The PackageManager class has been updated to support this custom fetching logic with caching, and corresponding unit tests have been added. Feedback suggests normalizing the returned dist-tags and versions in the Bun implementation to prevent potential runtime errors if the registry returns unexpected formats.

…ge manager

Bun's `pm view` command does not support requesting multiple fields at once (e.g. `pm view <pkg> dist-tags versions --json`), which is required by the default package manager abstraction to fetch package metadata during version compatibility search.

This change introduces a custom `getRegistryMetadata` handler in the package manager descriptor, allowing individual package managers to override registry metadata fetching entirely. The `bun` descriptor now implements this by querying `dist-tags` and `versions` separately in parallel, and returning the aggregated metadata object.
@clydin clydin force-pushed the fix/bun-registry-metadata branch from 19c35c0 to 309a236 Compare June 12, 2026 14:37
@clydin clydin added the action: review The PR is still awaiting reviews from at least one requested reviewer label Jun 12, 2026
@clydin clydin requested a review from alan-agius4 June 12, 2026 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: review The PR is still awaiting reviews from at least one requested reviewer area: @angular/cli target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant