-
Notifications
You must be signed in to change notification settings - Fork 1.1k
[Tooling] Use ReleasesV2 version as the source of truth during Code Freeze #24963
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
[Tooling] Use ReleasesV2 version as the source of truth during Code Freeze #24963
Conversation
f49417e to
7eb63f5
Compare
…of just showing a warning
7eb63f5 to
99bf62b
Compare
e068039 to
a1febfc
Compare
…hroughout code freeze lane
a1febfc to
aeab5a8
Compare
|
I applied the following patch: and ran Running |
mokagio
left a comment
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.
Looking good. Did not test locally because @twstokes already did that.
In reviewing this PR, I realized that one of the ones I reviewed earlier had kept the UI warning about the version mismatch:
When I run into it, I felt it was useful. However, I can see how it takes up space for something that should occur rarely.
fastlane/Fastfile
Outdated
| version_short ||= PUBLIC_VERSION_FILE.read_release_version | ||
| # Read the current build code from the .xcconfig file and parse it into an AppVersion object |
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.
Similar to https://github.com/woocommerce/woocommerce-ios/pull/16296/files#r2512589279. We could move the comment back where the read happens:
| version_short ||= PUBLIC_VERSION_FILE.read_release_version | |
| # Read the current build code from the .xcconfig file and parse it into an AppVersion object | |
| # Read the current build code from the .xcconfig file and parse it into an AppVersion object, | |
| # unless already given. | |
| version_short ||= PUBLIC_VERSION_FILE.read_release_version |
or just do without:
| version_short ||= PUBLIC_VERSION_FILE.read_release_version | |
| # Read the current build code from the .xcconfig file and parse it into an AppVersion object | |
| version_short ||= PUBLIC_VERSION_FILE.read_release_version |
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.
Thanks for the suggestion, good point on making it more readable (the terminology "build code", "version" was looking a bit confusing). I've tried to improve all the comments for this method, ded4343.
|



See AINFRA-1478
Description
This PR enhances the version handling added in the previous iteration to assume the version received by the code freeze lane as the source of truth, ignoring potential mismatches between the ReleasesV2 version and the project's computed version.
Testing
You can make sure the calculated release branch, current version and the next version are correctly shown in the "Continue" prompt. Just remember to answer
Nwhen asked to continue, to cancel the actual code freeze.To avoid unexpected results, comment out the lines doing
ensure_git_status_cleanandFastlane::Helper::GitHelper.checkout_and_pull(DEFAULT_BRANCH)at the beginning of the lane.You can run the
code_freezelane, with and without the version parameters:bundle exec fastlane code_freezebundle exec fastlane code_freeze version:30.6This will be fully tested in the next release cycle during code freeze.