Skip to content

Upgrade go-github v32 → v89 and shurcooL/githubv4 - #2121

Merged
Seanstoppable merged 1 commit into
wtfutil:trunkfrom
Seanstoppable:seanstoppable-upgrade-go-github-v89
Jul 23, 2026
Merged

Seanstoppable merged 1 commit into
wtfutil:trunkfrom
Seanstoppable:seanstoppable-upgrade-go-github-v89

Conversation

@Seanstoppable

Copy link
Copy Markdown
Collaborator

Summary

Upgrades the GitHub API client libraries:

  • github.com/google/go-github: v32.1.0 → v89.0.0
  • github.com/shurcooL/githubv4: Aug 2020 → Feb 2026 pseudo-version

Changes

Auth migration (go-github)

The old oauth2 transport pattern (oauth2.NewClient → github.NewClient(httpClient)) has been replaced with the functional options API introduced in newer versions:

// Before
oauthClient := oauth2.NewClient(ctx, tokenSource)
client := github.NewClient(oauthClient)

// After
client, err := github.NewClient(github.WithAuthToken(token))

For GitHub Enterprise, NewEnterpriseClient(base, upload, http) is replaced by:

github.NewClient(github.WithAuthToken(token), github.WithEnterpriseURLs(base, upload))

Files modified

  • modules/github/github_repo.go — import path + auth rewrite
  • modules/github/display.go — import path only
  • support/github.go — import path + auth rewrite
  • go.mod / go.sum — dependency updates

Testing

  • go build ./... ✅
  • go vet ./... ✅
  • Manual verification with live GitHub token ✅

@Seanstoppable
Seanstoppable force-pushed the seanstoppable-upgrade-go-github-v89 branch from 95d7d22 to 469e643 Compare July 23, 2026 02:17
- Update go-github from v32.1.0 to v89.0.0
- Migrate auth from oauth2 transport to NewClient option functions
  (WithAuthToken, WithEnterpriseURLs)
- Update shurcooL/githubv4 from Aug 2020 to Feb 2026 pseudo-version
- Remove unused oauth2 import from modules/github/github_repo.go
@Seanstoppable
Seanstoppable force-pushed the seanstoppable-upgrade-go-github-v89 branch from 469e643 to 1cd6f02 Compare July 23, 2026 02:53
@Seanstoppable
Seanstoppable enabled auto-merge (squash) July 23, 2026 02:54
@Seanstoppable
Seanstoppable merged commit f1fa41c into wtfutil:trunk Jul 23, 2026
4 checks passed
@Seanstoppable
Seanstoppable deleted the seanstoppable-upgrade-go-github-v89 branch July 23, 2026 03:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

⌂ 换网址