registry: deprecate RepositoryInfo.Official field#49567
Merged
thaJeztah merged 1 commit intomoby:masterfrom Mar 3, 2025
Merged
registry: deprecate RepositoryInfo.Official field#49567thaJeztah merged 1 commit intomoby:masterfrom
thaJeztah merged 1 commit intomoby:masterfrom
Conversation
This field indicates whether a repository is an official image (Docker Library / Docker Official Images). This information is deducted from the image reference, and not used anywhere, other than in tests. The `RepositoryInfo` and `IndexInfo` types were originally introduced in 568f86e, with their fields documented in 4fcb9ac. At the time, the `Official` field was only used for `docker push` to produce a custom error message if someone would attempt to push an official image to docker hub (assuming nobody would be able to do so); https://github.com/moby/moby/blob/6870bde5847d4484d87f91baf58edc52f575ea5d/api/client/commands.go#L1184-L1194 Before that commit, the condition for this error message was based on the given image reference directly; b370acd https://github.com/moby/moby/blob/b370acd679622239849b1dfbe05d61804aeb7162/commands.go#L421-L428 This patch deprecates the field, because it's not used, and removes tests related to it. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
vvoland
approved these changes
Mar 3, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This field indicates whether a repository is an official image (Docker Library / Docker Official Images). This information is deducted from the image reference, and not used anywhere, other than in tests.
The
RepositoryInfoandIndexInfotypes were originally introduced in 568f86e, with their fields documented in 4fcb9ac.At the time, the
Officialfield was only used fordocker pushto produce a custom error message if someone would attempt to push an official image to docker hub (assuming nobody would be able to do so);moby/api/client/commands.go
Lines 1184 to 1194 in 6870bde
Before that commit, the condition for this error message was based on the given image reference directly; b370acd
moby/commands.go
Lines 421 to 428 in b370acd
This patch deprecates the field, because it's not used, and removes tests related to it.
- Human readable description for the release notes
- A picture of a cute animal (not mandatory but encouraged)