Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: Correct body in EnterpriseService.InitialConfig #3763

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

@alexandear
Copy link
Contributor

@alexandear alexandear commented Oct 7, 2025

This PR fixes the body in the EnterpriseService.InitialConfig endpoint. From the documentation:

image

Before the PR, the request body is:

{"License":"1234-1234","Password":"password"}

After:

{"license":"1234-1234","password":"password"}

The bug was found with the help of musttag linter:

$ ./script/lint.sh
linting .
github/enterprise_manage_ghes_config_test.go:607:52: the given struct should be annotated with the `json` tag (musttag)
 assertNilError(t, json.NewDecoder(r.Body).Decode(v))
 ^
github/timestamp_test.go:132:28: the given struct should be annotated with the `json` tag (musttag)
 out, err := json.Marshal(tc.data)
 ^
github/timestamp_test.go:199:30: the given struct should be annotated with the `json` tag (musttag)
 bytes, err := json.Marshal(tc.data)
 ^
3 issues:
* musttag: 3

So, the PR enables it as well.

Copy link

codecov bot commented Oct 7, 2025
edited
Loading

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.34%. Comparing base (68b82b5) to head (84ee81d).
⚠️ Report is 2 commits behind head on master.

Additional details and impacted files
@@ Coverage Diff @@
## master #3763 +/- ##
=======================================
 Coverage 91.34% 91.34% 
=======================================
 Files 187 187 
 Lines 16702 16702 
=======================================
 Hits 15257 15257 
 Misses 1257 1257 
 Partials 188 188 

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copy link
Collaborator

@gmlewis gmlewis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @alexandear!
LGTM.
Merging.

@gmlewis gmlewis merged commit 52f9fff into google:master Oct 7, 2025
7 checks passed
@alexandear alexandear deleted the fix/enterprise-initial-config branch October 7, 2025 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@gmlewis gmlewis gmlewis approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /