WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Suboptimal error message on token delete with invalid credentials #392

@scop

Description

@scop

Environment (required):

  • OS: [e.g. macOS (Darwin or M1), Linux, Windows] Linux
  • Version [e.g. 1.2.0, "upctl version" gives you this] 3.16.1

Describe the bug
upctl account token delete THING error message is not as pretty as it c/should when accessed using invalid credentials.

To Reproduce
Steps to reproduce the behavior:

  1. Configure invalid credentials
  2. upctl account token delete FOO

Expected behavior

$ upctl account token delete FOO
✗ Command execution failed                                                                                                                                                     
  Error: error: message="Authentication failed using the given username and password.", type="AUTHENTICATION_FAILED"

Observed behavior

$ upctl account token delete FOO
Error: cannot resolve command line arguments: cannot get resolver: error: message="Unauthorized.", type="https://developers.upcloud.com/1.3/errors#ERROR_UNAUTHORIZED", correlation_id=...

Screenshots
N/A

Additional context
N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions