-
Notifications
You must be signed in to change notification settings - Fork 373
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
Fix our continuous pre-releases #1458
Conversation
@@ -0,0 +1,267 @@ | |||
/// We disallow version numbers larger than this in order to keep a few bits for future use. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Most of the following is old code, but I renamed the file, and git failed to figure that one out 😭
@@ -90,8 +90,7 @@ def main() -> None: | |||
cargo_version = get_cargo_version(cargo_toml) | |||
|
|||
if sys.argv[1] == "--patch_prerelease": | |||
git_sha = get_git_sha() | |||
new_version = cargo_version.bump_build(git_sha) | |||
new_version = f"{cargo_version}+{get_git_sha()}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small change here: the old code would suffix with +GITHASH.1
. The new code just adds +GITHASH
.
Closes #1457
Summary
Ignore the
+{$GITHASH}
suffix (that we use for our continuous releases) when parsing rust crate version.Details
We use
-alpha.X
-suffixes when we do intentional pre-releases, published tocrates.io
andPyPI
.We also do continuous releases of wheel on each merge to
main
. These are distinguished by suffixing our version string with+{$GITHASH}
.This caused issues when trying to parse the crate versions (at compile time). With this PR, we now ignore that suffix.
Why not parse it?
The
+build-metadata
suffixes of semver are not part of the actual version. It is metadata.We use the crate version to version our .rrd files, and so we should ignore metadata for that anyway.
We still show the git hash with
rerun --version
, and include it in our analytics.Checklist