Skip to content

gets avatars URL from mirror too#2385

Merged
Marketen merged 1 commit intofeat/mirror-content-providerfrom
marc/avatarsmirror
Feb 23, 2026
Merged

gets avatars URL from mirror too#2385
Marketen merged 1 commit intofeat/mirror-content-providerfrom
marc/avatarsmirror

Conversation

@Marketen
Copy link
Copy Markdown
Contributor

This pull request standardizes how avatar URLs are constructed and handled throughout the codebase. The main change is to always use the fileToGatewayUrl function for avatar files, removing fallback logic to manifest URLs. Additionally, support for a new "mirror" file source is introduced, enabling avatar files to be fetched from HTTP mirrors with proper URL construction. Type definitions are updated to reflect this new source and its required fields.

Avatar URL handling improvements:

  • All avatar URL assignments now exclusively use fileToGatewayUrl, removing fallback to manifest URLs in functions such as fetchDirectory, fetchDnpRequest, fetchRegistryIpfsData, getOptimismConfig, and getAll in various files. [1] [2] [3] [4] [5] [6] [7] [8]

  • The repository logic is updated so that avatar file entries are always constructed, and mirror sources are handled explicitly, removing previous logic that set manifest.avatarUrl directly when using mirrors.

Distributed file source enhancements:

  • The DistributedFileSource type now includes "mirror", and the DistributedFile interface is updated to require filename and packageHash for mirror sources, with clarifying comments. [1] [2]

  • The fileToGatewayUrl utility function is enhanced to generate proper URLs for mirror sources, using the base mirror URL, package hash, and filename, and returning an empty string if required fields are missing.

@Marketen Marketen requested a review from a team as a code owner February 23, 2026 10:48
@github-actions github-actions bot temporarily deployed to commit February 23, 2026 10:50 Inactive
@github-actions
Copy link
Copy Markdown

@Marketen Marketen merged commit 0bb1951 into feat/mirror-content-provider Feb 23, 2026
6 checks passed
@Marketen Marketen deleted the marc/avatarsmirror branch February 23, 2026 10:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants