Skip to content
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

Add script to automatically update changelog #2660

Merged
merged 24 commits into from
Dec 22, 2023

Conversation

charlesbvll
Copy link
Member

@charlesbvll charlesbvll commented Nov 29, 2023

Issue

Description

Currently we have to manually update the changelog with all new changes since the previous release. This is very tedious.

Related issues/PRs

N/A

Proposal

Explanation

This new script allows us to add changelog entries based on all new PRs' descriptions.
By default, it will search for a Changelog entry section in the description of the PR, if it is empty, it will just use the title of the PR for the changelog entry, without any description. If it is non existent, it will categorize the PR as "General improvement" and add it to the changelog accordingly. If it exists, it will use it to add a description to the change.

Note that a system of tokens is also in place:

  • <general> is for classifying a PR as a general improvement.
  • <skip> is to not add the PR to the changelog
  • <baselines> is to add a general baselines change to the PR
  • <examples> is to add a general examples change to the PR
  • <sdk> is to add a general sdk change to the PR
  • <simulations> is to add a general simulations change to the PR

Once those tokens are detected, if the corresponding entry (like - **General improvements**) doesn't already exist, it gets automatically created, and otherwise, PRs' URLs are added at the end of the list inside the parenthesis.

Checklist

  • Implement proposed change
  • Update changelog entry below
  • Make CI checks pass
  • Ping maintainers on Slack (channel #contributions)

Changelog entry

Any other comments?

In the new PR template, is the default flag.

Copy link
Member

@Robert-Steiner Robert-Steiner left a comment

Choose a reason for hiding this comment

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

Great work! I really like the script 👍

src/py/flwr_tool/update_changelog.py Outdated Show resolved Hide resolved
.github/PULL_REQUEST_TEMPLATE.md Show resolved Hide resolved
src/py/flwr_tool/update_changelog.py Outdated Show resolved Hide resolved
@tanertopal
Copy link
Member

@charlesbvll This is cool! I believe it would be helpful to write a small guide in the docs "CONTRIBUTOR HOW-TO GUIDES" section on how this works, with a few examples to send to new contributors to explain it.

@danieljanes @Robert-Steiner thoughts?

@charlesbvll
Copy link
Member Author

@charlesbvll This is cool! I believe it would be helpful to write a small guide in the docs "CONTRIBUTOR HOW-TO GUIDES" section on how this works, with a few examples to send to new contributors to explain it.

@danieljanes @Robert-Steiner thoughts?

I just added a quick mention at the moment, where we talk about the description of the PR, but maybe I can add a new section at the end of the doc, like an appendix, giving more details and some examples.

@charlesbvll
Copy link
Member Author

@charlesbvll This is cool! I believe it would be helpful to write a small guide in the docs "CONTRIBUTOR HOW-TO GUIDES" section on how this works, with a few examples to send to new contributors to explain it.
@danieljanes @Robert-Steiner thoughts?

I just added a quick mention at the moment, where we talk about the description of the PR, but maybe I can add a new section at the end of the doc, like an appendix, giving more details and some examples.

@tanertopal I added an appendix, I think the PR is ready for review

Copy link
Member

@Robert-Steiner Robert-Steiner left a comment

Choose a reason for hiding this comment

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

From my side it looks good!

@tanertopal tanertopal merged commit 53e352c into main Dec 22, 2023
28 checks passed
@tanertopal tanertopal deleted the add-update-changelog-script branch December 22, 2023 12:26
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.

4 participants