Skip to content

feat: allow release notes from a file in release-github action - #1581

Merged
moe-ad merged 4 commits into
mainfrom
feat/gh-release-note-from-file
Oct 7, 2026
Merged

moe-ad merged 4 commits into
mainfrom
feat/gh-release-note-from-file

Conversation

@moe-ad

@moe-ad moe-ad commented Sep 25, 2026 •

Copy link
Copy Markdown
Contributor

@moe-ad moe-ad self-assigned this Sep 25, 2026
@github-actions github-actions Bot added enhancement General improvements to existing features docs Issues related to documentation labels Sep 25, 2026
@moe-ad
moe-ad marked this pull request as ready for review September 25, 2026 10:56
@moe-ad
moe-ad requested a review from a team as a code owner September 25, 2026 10:56

@jorgepiloto jorgepiloto left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I just see a potential issue here. Since the line involved does not have any changes, I'm force to leave here my comment.

The release-github/action.yml#L560-588 still writes RELEASE_NOTES_BODY to the GITHUB_ENV with a fixed EOF delimiter.

If the custom release notes happen to have a EOF letters, this can break things.

@SMoraisAnsys SMoraisAnsys left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for the changes @moe-ad Is there a reason to implement that file handling when softprops/actions-gh-release already provides a way to work with an external release note ? See here

Comment thread doc/source/migrations/index.rst Resolved
Comment thread python-utils/parse_pr.py Resolved
@moe-ad

moe-ad commented Sep 30, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the changes @moe-ad Is there a reason to implement that file handling when softprops/actions-gh-release already provides a way to work with an external release note ? See here

@SMoraisAnsys I did see that.

There is this note further down in the documentation:
image
Which implies mutual exclusivity of both options i.e. not possible to combine both. Why that is relevant is that had I decided to leverage body_path input directly, I would have had to implement extra steps for extending the contents of the file with the rest of the release note contents (e.g. artifact attestation notes) and it just made sense / easier to follow the logic by implementing things this way. FYI that we already do a similar file handling when changelog-release-notes is true, we are effectively reading from a file at the end of the day.

@moe-ad

moe-ad commented Sep 30, 2026

Copy link
Copy Markdown
Contributor Author

I just see a potential issue here. Since the line involved does not have any changes, I'm force to leave here my comment.

The release-github/action.yml#L560-588 still writes RELEASE_NOTES_BODY to the GITHUB_ENV with a fixed EOF delimiter.

If the custom release notes happen to have a EOF letters, this can break things.

Updated in 2ab8adf.

@SMoraisAnsys

Copy link
Copy Markdown
Contributor

Thanks for the changes @moe-ad Is there a reason to implement that file handling when softprops/actions-gh-release already provides a way to work with an external release note ? See here

@SMoraisAnsys I did see that.

There is this note further down in the documentation: image Which implies mutual exclusivity of both options i.e. not possible to combine both. Why that is relevant is that had I decided to leverage body_path input directly, I would have had to implement extra steps for extending the contents of the file with the rest of the release note contents (e.g. artifact attestation notes) and it just made sense / easier to follow the logic by implementing things this way. FYI that we already do a similar file handling when changelog-release-notes is true, we are effectively reading from a file at the end of the day.

I'm probably missing something here and need clarification. Given that the current approach enforce that release-notes-file input cannot be combined with changelog-release-notes or generate-release-notes, isn't that the same as the mutual exclusivity from body and body-path ?

@moe-ad

moe-ad commented Sep 30, 2026

Copy link
Copy Markdown
Contributor Author

Thanks for the changes @moe-ad Is there a reason to implement that file handling when softprops/actions-gh-release already provides a way to work with an external release note ? See here

@SMoraisAnsys I did see that.
There is this note further down in the documentation: image Which implies mutual exclusivity of both options i.e. not possible to combine both. Why that is relevant is that had I decided to leverage body_path input directly, I would have had to implement extra steps for extending the contents of the file with the rest of the release note contents (e.g. artifact attestation notes) and it just made sense / easier to follow the logic by implementing things this way. FYI that we already do a similar file handling when changelog-release-notes is true, we are effectively reading from a file at the end of the day.

I'm probably missing something here and need clarification. Given that the current approach enforce that release-notes-file input cannot be combined with changelog-release-notes or generate-release-notes, isn't that the same as the mutual exclusivity from body and body-path ?

The main take away is that routing everything through body made implementation easier and straightforward, and plugs right into the rest of the logic we already had, especially the appending of artifact attestation notes.

Had I decided to use body_path, I would have had to create a completely separate execution path that will pass everything to softprops/action-gh-release through a file. You see what I mean?

@SMoraisAnsys

Copy link
Copy Markdown
Contributor

I understand yeah. I was thinking that the main goal of providing a file content was to avoid having anything generated by our action (which doesn't seem to be the case). Maybe we could see what @heikeOnScale had in mind with #753.

If possible I would keep things simple: either you follow what we have as main stream and use our changelog/default note with/without artifacts. If one wants to use a custom release note (through file) and append artifact attestation notes, then one simply update the associated file.

@jorgepiloto jorgepiloto left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I don't see any issues with these changes. Thanks for implementing this, @moe-ad. Approving on my side.

@moe-ad
moe-ad requested a review from RobPasMue October 7, 2026 08:24
@moe-ad
moe-ad merged commit 8de6354 into main Oct 7, 2026
107 of 108 checks passed
@moe-ad
moe-ad deleted the feat/gh-release-note-from-file branch October 7, 2026 08:51
moe-ad added a commit that referenced this pull request Oct 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Issues related to documentation enhancement General improvements to existing features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Have the ability to add your own release_notes.md

5 participants