Repository navigation
Conversation
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Version.parse("1.2.3-rc9").next_version("prerelease")returns1.2.3-rc10, which is older under SemVer's lexical prerelease ordering. That contradictsnext_version's ordering guarantee and can make an automated release increment move backwards.Check the candidate in the same-token legacy-counter branch. If it would not be newer, advance the patch while retaining the incremented legacy counter:
1.2.3-rc9becomes1.2.4-rc10. Ordinary increments, dotted numeric counters and already-forward leading-zero transitions retain their existing patch. Build metadata is cleared, subclasses are preserved and the input stays unchanged.Fixes #499. This applies the patch-advance precedent from #498 to the separate legacy return path. It deliberately updates
test_issue_484_rc9_to_rc10, whose old expectation pinned the backwards result, and documents that behavior in the method and news fragment. Open #494/#496 address long-identifier conversion limits and are outside this patch.Validation on Windows:
git diff --checkpasses. The repository-wide lint is not claimed clean.This Windows Git checkout materializes two pre-existing test symlinks as target-name text. Validation ran in a separate source copy with those two files resolved to the exact documented source bytes; neither workaround is included in the PR. Other platforms/interpreters and the native backend have not been exercised locally.
Found by code inspection and prepared with OpenAI Codex assistance. No production incident or independent human review is claimed.