Repository navigation
Description
Expected Behavior
When the provider has no token and is talking to api.github.com, an operation that can't
succeed anonymously should fail fast with a clear "authentication required" error.
Actual Behavior
With an empty token the provider silently enters anonymous mode and proceeds. On a plan/refresh
over an org with many repositories it can stall for hours before failing.
I believe this is due to the anonymous primary rate limit (60 requests/hour/IP) combined with
RateLimitTransport's sleep-until-reset behavior
terraform-provider-github/github/transport.go
Lines 105 to 111 in add2157
| rlErr := &github.RateLimitError{} | |
| if errors.As(ghErr, &rlErr) { | |
| rlt.nextRequestDelay = 0 | |
| retryAfter := time.Until(rlErr.Rate.Reset.Time) | |
| log.Printf("[WARN] Rate limit %d reached, sleeping for %s (until %s) before retrying", | |
| rlErr.Rate.Limit, retryAfter, time.Now().Add(retryAfter)) | |
| sleep(req.Context(), retryAfter) |
Reported by a user of the downstream Pulumi provider in pulumi/pulumi-github#1242.
Terraform Version
Provider v6.14.0
GitHub Installation Type
- GitHub.com (Free, Pro, or Team)
- GitHub Enterprise Server (on-premises)
- GitHub Enterprise Cloud with Personal Accounts (github.com)
- GitHub Enterprise Cloud with Managed Users/EMU (github.com)
- GitHub Enterprise Cloud with Data Residency (*.ghe.com)
- I don't know
Affected Resource(s)
github_repositorygithub_repository_vulnerability_alerts- Any anonymous read that trips the 60/hour anonymous rate limit
Terraform Configuration Files
provider "github" {} # no token in the environment
resource "github_repository" "example" {
name = "example"
}Steps to Reproduce
- Manage several
github_repositoryresources. - Run
terraform planwith noGITHUB_TOKEN/tokenset. - Observe the run sleep for ~1 hour at a time and take hours to fail, rather than erroring
immediately on the unauthenticated response.
Debug Output
Code of Conduct
- I agree to follow this project's Code of Conduct
Reacted by Guinevere Saenger and Ben Limmer
Metadata
Metadata
Assignees
Labels
Type: BugSomething isn't working as documented
Activity
github-actions commentedon Jul 20, 2026
👋 Hi, and thank you for opening this issue!
This repo is maintained by GitHub and community members on a best-effort basis. We'll get to this as soon as we can.
You can help us prioritize by adding details, reproduction steps, or a 👍 to issues that matter to you, and by joining the discussion on open issues and PRs.
🤖 This is an automated message.
deiga commentedon Jul 20, 2026
@guineveresaenger There is no version 6.14.0 of this provider yet.
Please provide a DEBUG level log output of the problematic command.
deiga commentedon Jul 22, 2026
I think this is either a bug/feature in Pulimi or the Pulumi-wrapper.
If it isn't, this will be resolved by #3310
stevehipwell commentedon Nov 23, 2026
This bug shouldn't be present in the current release if you're using the new provider (
legacy = false). PR #3739 will fix a couple of issues with the new client so please switch over to that after the next release.