Handle invalid repositories in Docker Registry
What does this MR do?
In some cases, there are no tags in a repository, however, the repository itself exists. I could not create such a state using API but somehow it's possible. I could only remove all the tags manually in storage for a particular repository to reproduce this error. This MR does the same as what we do in ContainerRepository#tags
method so it's also consistent.
Screenshots
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry -
Documentation (if required) -
Code review guidelines -
Merge request performance guidelines -
Style guides -
Database guides -
Separation of EE specific content
Availability and Testing
-
Review and add/update tests for this feature/bug. Consider all test levels. See the Test Planning Process. -
Tested in all supported browsers
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
-
Label as security and @ mention @gitlab-com/gl-security/appsec
-
The MR includes necessary changes to maintain consistency between UI, API, email, or other methods -
Security reports checked/validated by a reviewer from the AppSec team
Related to #196158 (closed)
Edited by Valery Sizov