Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve error message when namespace is not specified in the reference of Dockerhub artifacts #1216

Closed
Tracked by #1218
qweeah opened this issue Dec 26, 2023 · 0 comments · Fixed by #1222
Closed
Tracked by #1218
Labels
ux User experience related
Milestone

Comments

@qweeah
Copy link
Contributor

qweeah commented Dec 26, 2023

Users might forget to add the namespace (e.g. library #1151) when pulling or copying Dockerhub images and get unexpected 401. Need to improve the error message and suggest user to add namespace.

Current behavior

$ oras pull docker.io/nginx:latest
Error: failed to resolve latest: GET "https://registry-1.docker.io/v2/nginx/manifests/latest": response status code 401: unauthorized: authentication required: [map[Action:pull Class: Name:nginx Type:repository]]

Suggested error message:

$ oras pull docker.io/nginx:latest
Error response from registry: pull access denied for docker.io/nginx:latest : response status code 401: unauthorized: requested access to the resource is denied
Namespace is missing, do you mean `oras pull docker.io/library/nginx:latest`? 
@qweeah qweeah added the ux User experience related label Dec 26, 2023
@qweeah qweeah changed the title improve error message when no namespace is not specified in the reference of Dockerhub artifacts improve error message when namespace is not specified in the reference of Dockerhub artifacts Dec 26, 2023
@qweeah qweeah mentioned this issue Dec 26, 2023
9 tasks
@qweeah qweeah added this to the v1.2.0 milestone Dec 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ux User experience related
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant