Better error message for expired/invalid PAT
Open
enhancement
- Dominant language
- Shell
- Stars
- 43
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
```
$ gh codeql list-versions
expected an object but got: string ("https://docs.github.com/rest")
```
I haven't investigated, but perhaps this is making an invalid API request.
---
EDIT: The reason for the error was an expired PAT. Leaving this issue open so we can provide a better error message in this case.
Contributor guide
Research direction
Start with the `gh codeql list-versions` entry point and reproduce the command using an expired or invalid PAT. Trace how the failed response is handled and define done as showing a clear authentication error instead of the reported object-versus-string message; the issue does not name a test or source file.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github, shell
- Domain
- api, authentication, cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100