Skip to content

fix: explicitly specify tag_name in GitHub Release step#94

Merged
mkistler merged 2 commits intomainfrom
copilot/update-release-workflow-tag-error
Feb 27, 2026
Merged

fix: explicitly specify tag_name in GitHub Release step#94
mkistler merged 2 commits intomainfrom
copilot/update-release-workflow-tag-error

Conversation

Copy link
Contributor

Copilot AI commented Feb 26, 2026

When the release workflow creates a tag mid-run, the softprops/action-gh-release step can fail to locate it automatically, resulting in a "GitHub Releases requires a tag" error.

Change

  • Added tag_name: ${{ steps.package-version.outputs.tag }} to the Create GitHub Release step's with block, explicitly passing the tag output from the earlier package-version step:
- name: Create GitHub Release
  uses: softprops/action-gh-release@v2
  with:
    tag_name: ${{ steps.package-version.outputs.tag }}
    generate_release_notes: true
Original prompt

Update the release workflow to fix the 'GitHub Releases requires a tag' error. Currently, the 'Create GitHub Release' step in .github/workflows/release.yaml can fail when the workflow is triggered by a commit to main and the tag is created within the workflow, because the release step does not explicitly specify which tag to use.

Solution:

  • In the 'Create GitHub Release' step, add 'tag_name: ${{ steps.package-version.outputs.tag }}' to the 'with' block.

This ensures the correct tag is referenced regardless of how the workflow was triggered, addressing failures when the tag is not automatically available in the release step context.

This pull request was created from Copilot chat.


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Co-authored-by: mkistler <800728+mkistler@users.noreply.github.com>
Copilot AI changed the title [WIP] Update release workflow to fix 'GitHub Releases requires a tag' error fix: explicitly specify tag_name in GitHub Release step Feb 26, 2026
Copy link
Contributor

@mkistler mkistler left a comment

Choose a reason for hiding this comment

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

Looks good. 👍

@mkistler mkistler marked this pull request as ready for review February 26, 2026 14:50
@mkistler
Copy link
Contributor

I think I have hit every little glitch imaginable in this workflow. I'm hoping that this finally fixes things.

@mkistler mkistler merged commit d7c330b into main Feb 27, 2026
4 checks passed
@mkistler mkistler deleted the copilot/update-release-workflow-tag-error branch February 27, 2026 20:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants