Skip to content

Improve output if invalid number of command line arguments are provided #458

Closed

Description

@qweeah

For all ORAS commands (login, logout, pull, push, attach, discover, copy), if the number of input argument doesn't match expected, user will get errors like:

Error: accepts X arg(s), received Y

It could confuse users who are not familiar with cobra concepts. E.g. they might think number of flags doesn't meet what is expected.

We need to provide more clear details for the error, including:

  1. what is expected
  2. what is got from input

Activity

  1. added this to the v0.14.0 milestone on Jul 26, 2022
  2. shizhMSFT commented on Jul 26, 2022

    @shizhMSFT
    Contributor

    It could confuse users who are not familiar with cobra concepts. E.g. they might think number of flags doesn't meet what is expected.

    In that case, users should run the help command for usages.

  3. modified the milestones: v0.14.0, v1.2.0 on Dec 7, 2023
  4. reopened this on Dec 7, 2023
  5. added
    ux
    on Dec 7, 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