Fix version format for weekly release tags#748
Merged
Arlodotexe merged 1 commit intomainfrom Oct 8, 2025
Merged
Conversation
Weekly release tags (refs/tags/release/weekly/*) were falling through to pull request version format, producing malformed package versions like '0.1.250929-pull-.2302' instead of '0.1.250929-build.2302'. Added startsWith(github.ref, 'refs/tags/release/') to VERSION_PROPERTY condition so release tags use build.RUNNUMBER format like main branch. Fixes version suffix for both build and package jobs. Evidence: Run 18109399189 artifacts showed all packages with 'pull-.' instead of 'build.' format.
michael-hawker
approved these changes
Oct 8, 2025
Member
|
One thing we could consider is to detect the event number variable if that's only used on PRs to use the PR tag and use build for anything else maybe. |
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.
Problem
Weekly release packages have malformed version suffixes due to incorrect
VERSION_PROPERTYlogic in the build workflow.Example from run 18109399189 (Sept 29, 2025):
CommunityToolkit.Labs.WinUI.Controls.Shimmer.0.1.250929-pull-.2302.nupkgCommunityToolkit.Labs.WinUI.Controls.Shimmer.0.1.250929-build.2302.nupkgAll 12 packages in the Sept 29 weekly release run had the malformed
pull-.RUNNUMBERsuffix instead of the correctbuild.RUNNUMBERformat.Root Cause
The
VERSION_PROPERTYenvironment variable inbuild.ymluses conditional logic to determine version suffix format:This condition checks:
mainorrel/*branch → usebuild.RUNNUMBERpull-PRNUMBER.RUNNUMBERWeekly release tags have refs like
refs/tags/release/weekly/250929, which don't match either condition, so they fall through to the pull request format. Sincegithub.event.numberis null for tag pushes, the result ispull-.RUNNUMBER.Solution
Add tag detection to the condition so release tags use the same format as main branch builds:
This change is applied in both the
buildjob (line 85) andpackagejob (line 269) to ensure consistent version formatting throughout the workflow.Testing
This fix can be validated:
scheduled-releasesworkflow manually via Actions UIbuild.RUNNUMBERsuffix instead ofpull-.RUNNUMBERRelated
Evidence
Downloaded artifacts from run 18109399189 confirmed all packages had malformed version suffix. Example packages affected: CanvasLayout, CanvasView, DataTable, MarkdownTextBlock, Marquee, OpacityMaskView, Shimmer, TitleBar, TokenView, DependencyPropertyGenerator, RivePlayer, TransitionHelper.