circleci-cli
circleci-cli copied to clipboard
"circleci orb init" . --private fails with "json: cannot unmarshal object into Go value of type []cmd.orbProtectTemplateRelease"
Meta:
CircleCI CLI Version:
0.1.15410+ba6fe81 (homebrew)
Operating System:
MacOS
CircleCI CLI Diagnostic:
Debugger mode: false
Config found: /Users/christianwinther/.circleci/cli.yml
API host: https://circleci.com
API endpoint: graphql-unstable
Error: please set a token with 'circleci setup'
You can create a new personal API token here:
https://circleci.com/account/api
Current behavior:
$ circleci orb init . --private
Note: This command is in preview. Please report any bugs! https://github.com/CircleCI-Public/circleci-cli/issues/new/choose
? Would you like to perform an automated setup of this orb? Yes, walk me through the process.
Downloading Orb Project Template into .
Error: Unexpected error: json: cannot unmarshal object into Go value of type []cmd.orbProtectTemplateRelease
Expected behavior:
It working
When did this begin / Was this previously working?:
N/A
Additional Information:
Installed via Homebrew
It also does not work after running circleci setup
Debugging a bit, it seems like it's due to my IP being GitHub rate limited when trying to download https://api.github.com/repos/CircleCI-Public/Orb-Project-Template/tags in the init command (https://github.com/CircleCI-Public/circleci-cli/blob/master/cmd/orb.go#L1065)
Doesn't see a way in the code to make the GitHub request authenticated, so looks like I'm blocked from using it on the work network since someone exceeded the rate limit
// 20210713105938
// https://api.github.com/repos/CircleCI-Public/Orb-Project-Template/tags
{
"message": "API rate limit exceeded for XXX.XXX.XXX.XXX. (But here's the good news: Authenticated requests get a higher rate limit. Check out the documentation for more details.)",
"documentation_url": "https://docs.github.com/rest/overview/resources-in-the-rest-api#rate-limiting"
}