Skip to content

fix: dev branch must skip past a pre-GA hotfix's reserved micro version (BERTE-609)#277

Closed
charlesprost wants to merge 1 commit into
mainfrom
fix/dev-branch-version-vs-pre-ga-hotfix
Closed

fix: dev branch must skip past a pre-GA hotfix's reserved micro version (BERTE-609)#277
charlesprost wants to merge 1 commit into
mainfrom
fix/dev-branch-version-vs-pre-ga-hotfix

Conversation

@charlesprost

@charlesprost charlesprost commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Summary

  • A pre-GA hotfix branch (e.g. hotfix/10.0.0) permanently reserves its X.Y.Z version the moment it is cut: every version it can ever produce is X.Y.Z.<hfrev> (.0 pre-GA, .1+ post-GA), never a bare X.Y.Z. The parent dev branch (development/10.0) must therefore target X.Y.(Z+1), not X.Y.Z, or a later X.Y.Z tag cut from the dev branch would collide with the hotfix line while describing different code.
  • _update_major_versions() already implements this rule for major-only dev branches (development/10 correctly skips past hotfix/10.0.0 to target 10.1.0), but the equivalent minor-branch path ignored phantom hotfix branches when computing latest_micro. This change folds phantom hotfix micros into that computation too, mirroring the existing major-only handling.
  • Updated test_branch_cascade_2digit_with_pre_ga_hotfix to assert the corrected expectation (development/10.010.0.1, not 10.0.0) both pre- and post-GA, and added assertions on the hotfix's own version (10.0.0.010.0.0.1) to make the pairing explicit.

Ref: BERTE-609

Test plan

  • test_branch_cascade_2digit_with_pre_ga_hotfix updated and passing
  • Full QuickTest cascade/hotfix/phantom test class passing (29 tests)
  • Verified unrelated TestQueueing/TaskQueueTests failures pre-exist on unmodified main (require the full mock-server CLI harness, not bare pytest)

🤖 Generated with Claude Code

…on (BERTE-609)

A pre-GA hotfix branch (e.g. hotfix/10.0.0) permanently reserves its
X.Y.Z version the moment it is cut, since every version it can ever
produce is X.Y.Z.<hfrev>, never a bare X.Y.Z. The parent dev branch
(development/10.0) must therefore target X.Y.(Z+1), not X.Y.Z.

_update_major_versions() already applied this rule for major-only dev
branches (development/10 skipping past hotfix/10.0.0 to 10.1.0), but
not for minor dev branches, which ignored phantom hotfix branches when
computing latest_micro. Fold phantom hotfix micros into that
computation too, mirroring the existing major-only handling.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@charlesprost
charlesprost requested a review from a team as a code owner July 23, 2026 18:15
@claude

claude Bot commented Jul 23, 2026

Copy link
Copy Markdown

LGTM

The fix correctly mirrors the existing major-branch phantom hotfix handling (lines 1151-1157) for the minor-branch path. The micros.extend() ensures latest_micro accounts for hotfix-reserved versions even before GA tags land, and the if micros: guard remains safe. Test updates verify both pre-GA and post-GA scenarios with explicit version assertions.

Review by Claude Code

@codecov

codecov Bot commented Jul 23, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.00%. Comparing base (b35e425) to head (87f5075).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #277   +/-   ##
=======================================
  Coverage   90.00%   90.00%           
=======================================
  Files          81       81           
  Lines       11048    11051    +3     
=======================================
+ Hits         9944     9947    +3     
  Misses       1104     1104           
Flag Coverage Δ
integration 87.76% <100.00%> (+<0.01%) ⬆️
tests 87.72% <100.00%> (+<0.01%) ⬆️
tests-BuildFailedTest 25.81% <0.00%> (-0.01%) ⬇️
tests-QuickTest 33.04% <100.00%> (+0.02%) ⬆️
tests-RepositoryTests 25.49% <0.00%> (-0.01%) ⬇️
tests-TaskQueueTests 49.47% <16.66%> (-0.01%) ⬇️
tests-TestBertE 66.96% <16.66%> (-0.02%) ⬇️
tests-TestQueueing 51.58% <16.66%> (-0.01%) ⬇️
tests-api-mock 14.72% <0.00%> (-0.01%) ⬇️
tests-noqueue 78.39% <100.00%> (+<0.01%) ⬆️
tests-noqueue-BuildFailedTest 25.81% <0.00%> (-0.01%) ⬇️
tests-noqueue-QuickTest 33.04% <100.00%> (+0.02%) ⬆️
tests-noqueue-RepositoryTests 25.49% <0.00%> (-0.01%) ⬇️
tests-noqueue-TaskQueueTests 49.47% <16.66%> (-0.01%) ⬇️
tests-noqueue-TestBertE 63.51% <16.66%> (-0.02%) ⬇️
tests-noqueue-TestQueueing 25.51% <0.00%> (-0.01%) ⬇️
tests-server 27.24% <0.00%> (-0.01%) ⬇️
unittests 42.32% <0.00%> (-0.02%) ⬇️
utests 27.68% <0.00%> (-0.01%) ⬇️

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.

@charlesprost
charlesprost deleted the fix/dev-branch-version-vs-pre-ga-hotfix branch July 23, 2026 20:13
@charlesprost

Copy link
Copy Markdown
Contributor Author

Closed as a side effect of renaming the source branch to follow the bugfix/BERTE-609-... convention. Same commit, continued in #278.

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.

1 participant