I'm using the GitLab registry and I noticed that the name of the current repository from a given registry is missing.
And this behavior can be observed only for GitLab, DockerHub works like a charm.
I'll provide some images so that it's more clear.
Observation:
Current state in GitLab:
The same thing, but in DockerHub:
Definitely looks like a bug, we'll look into it. Thanks for reporting it @danielgospodinow!
@BigMorty I think we should take this for 0.11.0 as it essentially makes GitLab unusable in our Registries view.
Only one of these blank repositories can exist in a given namespace--its name _is_ the same as the namespace--so that mitigates the problem somewhat. You won't see a field of blank repositories with no context or hint as to what is what.
I'm able to reproduce:
By tagging and pushing to registry.gitlab.com/username/project/repo:latest
, it will show up as repository something
with tag latest
, like this:
docker push registry.gitlab.com/bwateratmsft/vscode-extension-testing/webworkspace:latest
But if you tag and push with registry.gitlab.com/username/project:latest
, it shows up as repository blank:
docker push registry.gitlab.com/bwateratmsft/vscode-extension-testing:latest
I'll check to see what Docker Hub is doing differently...
So Docker Hub does not allow pushes to the namespace itself. i.e. I can push bwateratmsft/webworkspace:latest
but not bwateratmsft:latest
.
It's good that you managed to reproduce the issue and I'm happy that you even figured out what's going on exactly! :smile: Good luck, guys!
Thank you! We were trying to decide exactly what text should go in that spot. Technically, it's another repository altogether. Some of our ideas include:
bwateratmsft/vscode-extension-testing
. This would be the exact same text as the parent node.<root>
<default>
Do you have any preference or is there different text that makes sense to show there?
I think option 1 seems quite reasonable. In fact, that's the behavior that I expect as a user. :smile:
I got familiar with the source code and I'll also do my best to help resolving this issue. I would love to contribute to this project. :smile:
I looked further into the code, and it seems like this is a quirk of GitLab itself. Their API returns a name
value that is blank. Still, I think the fix is essentially the same--when constructing the repository node, we can just give a default name like the project name if there's nothing from the request.
Yes, I absolutely agree! :smile: This fix should do the trick.
I managed to apply the fix locally.
Can I try and make a pull request for this, even though it's just a single line of code? :smile:
Yes, please do! We welcome user contributions. :smile:
I've made a pull request. :smile: I'll try to continue contributing as much as I can! :v: And thank you for the wonderful discussion, It was a wonderful opportunity for me!