Skip to content

Fix regression in #14546#14550

Merged
alex merged 2 commits intopyca:mainfrom
trail-of-forks:dm/simplify-update-dep-fix
Mar 26, 2026
Merged

Fix regression in #14546#14550
alex merged 2 commits intopyca:mainfrom
trail-of-forks:dm/simplify-update-dep-fix

Conversation

@DarkaMaul
Copy link
Copy Markdown
Contributor

In #14546, I extracted _version_key from get_remote_latest_tag and reused it in get_current_version_from_file to pick the minimum version among multiple matches.

However, _version_key parses dotted version strings as integer tuples, which fails on commit SHAs like BoringSSL, which caused the regression here

The new algorithm is simpler:

  • Identify the latest version
  • Identify all versions present in the file
  • If there is at least one which is not the latest, update them all

f.write("HAS_UPDATES=false\n")
return 0

current_version = next(
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

FLAG: This will produce a slightly incorrect commit message if we have multiple versions we need to update, but I think adding trhe logic to find the oldest commit is not worth the extra complexity.

@DarkaMaul DarkaMaul force-pushed the dm/simplify-update-dep-fix branch from bf4a63d to 22f55d0 Compare March 26, 2026 13:32
@alex alex merged commit ce4ac8e into pyca:main Mar 26, 2026
67 checks passed
@DarkaMaul DarkaMaul deleted the dm/simplify-update-dep-fix branch March 26, 2026 16:13
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.

2 participants