Skip to content

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

Closed

Description

@qweeah

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`? 

Activity

  1. added
    ux
    on Dec 26, 2023
  2. 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[/+] on Dec 26, 2023
  3. added this to the v1.2.0 milestone on Dec 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ux

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions