Fix OAuth2Client publish workflow to match existing OAuthClient-v tag convention#661
Closed
shehanster wants to merge 1 commit into
Closed
Fix OAuth2Client publish workflow to match existing OAuthClient-v tag convention#661shehanster wants to merge 1 commit into
shehanster wants to merge 1 commit into
Conversation
The workflow looked for client-* tags, but the repo's existing client release tags use the OAuthClient-v* convention (e.g. OAuthClient-v1.6.0). With no matching tag found, every run fell into the initial-release path and tried to republish 1.6.0, which already exists on nuget.org. Align all three places to the existing convention: the tag lookup, the version prefix strip (including the v), and the tag created after a successful publish.
Author
|
Superseded by #660 (same fix, merged). |
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
The OAuth2Client publish workflow run failed trying to push
Xero.NetStandard.OAuth2Client.1.6.0.nupkg— a version that has been on nuget.org since May 2022.Root cause: the
Check for changesstep looks for tags matchingclient-*, but the repo's client release tags use theOAuthClient-v*convention (OAuthClient-v1.5.1,OAuthClient-v1.5.3,OAuthClient-v1.6.0). With no matching tag, every run falls into the initial-release path: change detection is skipped (has_changesforcedtrue) and the version falls back to the csproj value (1.6.0) instead of bumping.Fix
Align the workflow with the existing tag convention in all three places it appears:
OAuthClient-v*OAuthClient-vprefix (including thev, so the bump arithmetic gets a plain1.6.0)OAuthClient-v<version>, so subsequent runs find the new tagExpected behaviour after merge
Next
workflow_dispatchrun will findOAuthClient-v1.6.0, detect the unpublished OAuth2Client changes since then (IdentityModel 7.0.0 fix from #556, PETOSS-506 dependency bumps from #564), compute 1.6.1 (patch bump), publish it, and tagOAuthClient-v1.6.1.