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

Appearance settings

refactor(checker): rename SCREAMING_SNAKE_CASE stability constants to MixedCaps#1032

Merged
reuvenharrison merged 1 commit into
mainoasdiff/oasdiff:mainfrom
rename-stability-constantsoasdiff/oasdiff:rename-stability-constantsCopy head branch name to clipboard
Jun 21, 2026
Merged

refactor(checker): rename SCREAMING_SNAKE_CASE stability constants to MixedCaps#1032
reuvenharrison merged 1 commit into
mainoasdiff/oasdiff:mainfrom
rename-stability-constantsoasdiff/oasdiff:rename-stability-constantsCopy head branch name to clipboard

Conversation

@reuvenharrison

Copy link
Copy Markdown
Collaborator

Closes #1031.

STABILITY_DRAFT / STABILITY_ALPHA / STABILITY_BETA / STABILITY_STABLE use a C/Python casing convention, not Go (which uses MixedCaps). staticcheck flags this as ST1003.

Change

  • Renamed the canonical constants to StabilityDraft / StabilityAlpha / StabilityBeta / StabilityStable and migrated all internal usages.
  • The values ("draft", "alpha", "beta", "stable") are unchanged, so there is no CLI or serialized behavior change.
  • The old names are kept as // Deprecated: aliases, since they are exported and a library consumer may reference them. They can be dropped in a future major release.

Scope

A repo-wide scan confirmed these four were the only SCREAMING_SNAKE_CASE Go identifiers. Environment-variable name strings (OASDIFF_CONFIG, GITHUB_OUTPUT, etc.) and os.O_* flags are correctly cased and out of scope.

Build, go vet, gofmt, and the full test suite pass.

… MixedCaps

STABILITY_DRAFT / ALPHA / BETA / STABLE use a C/Python casing convention,
not Go. Rename them to StabilityDraft / StabilityAlpha / StabilityBeta /
StabilityStable and migrate all internal usages. The values ("draft",
"alpha", "beta", "stable") are unchanged, so no CLI or serialized behavior
changes.

The old names are kept as deprecated aliases, since they are exported and
a library consumer may reference them; they can be dropped in a future
major release.

Closes #1031.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@codecov-commenter

codecov-commenter commented Jun 21, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 81.25000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 87.51%. Comparing base (82dd007) to head (6fd51ac).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
checker/check_api_sunset_changed.go 50.00% 2 Missing ⚠️
checker/stability_level.go 80.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1032   +/-   ##
=======================================
  Coverage   87.51%   87.51%           
=======================================
  Files         277      277           
  Lines       14431    14431           
=======================================
  Hits        12629    12629           
  Misses       1289     1289           
  Partials      513      513           
Flag Coverage Δ
unittests 87.51% <81.25%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 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.

@reuvenharrison
reuvenharrison merged commit fc383a0 into main Jun 21, 2026
13 checks passed
@reuvenharrison
reuvenharrison deleted the rename-stability-constants branch June 21, 2026 12:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Rename SCREAMING_SNAKE_CASE constants (STABILITY_*) to idiomatic Go MixedCaps

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.