| 1 |
--- |
| 2 |
name: Minor Version Release Checklist |
| 3 |
about: About to release a new minor version? (Maintainers Only!) |
| 4 |
title: '' |
| 5 |
labels: '' |
| 6 |
assignees: '' |
| 7 |
|
| 8 |
--- |
| 9 |
|
| 10 |
# Minor Release Overview: v<!-- Insert Version Here, e.g. 5.4.0 --> |
| 11 |
|
| 12 |
This issue will summarize the status and discussion in preparation for the new release. It will be used to track the progress of the release and to ensure that all the necessary steps are taken. It will serve as a checklist for the release and will be used to communicate the status of the release to the community. |
| 13 |
|
| 14 |
> ⚠️ **Warning:** The release checklist is a living document. It will be updated as the release progresses. Please check back often to ensure that you are up to date with the latest information. |
| 15 |
|
| 16 |
## Checklist |
| 17 |
- [ ] Codebase Stability |
| 18 |
- [ ] Breaking Changes Validation |
| 19 |
- [ ] Compile Changelog |
| 20 |
- [ ] Release |
| 21 |
- [ ] Release Announcement |
| 22 |
|
| 23 |
# Release Details |
| 24 |
The release manager is responsible for completing the release end-to-end ensuring that all the necessary steps are taken and that the release is completed in a timely manner. This is usually the owner of the release issue but may be assigned to a different maintainer if necessary. |
| 25 |
|
| 26 |
- Release Manager: <!-- Insert Release Manager Here --> |
| 27 |
- Release Date: <!-- Insert Release Date Here --> |
| 28 |
- Release Branch: `main` |
| 29 |
|
| 30 |
# Release Steps |
| 31 |
The release manager is expected to execute the checklist below. The release manager is also responsible for ensuring that the checklist is updated as the release progresses. Any changes or issues should be communicated under this issue for centralized tracking. |
| 32 |
|
| 33 |
# Potential Release Blockers |
| 34 |
|
| 35 |
## 1. Codebase Stability |
| 36 |
- [ ] The `main` branch build passes |
| 37 |
|
| 38 |
[](https://github.com/celery/celery/actions/workflows/python-package.yml) |
| 39 |
|
| 40 |
## 2. Breaking Changes Validation |
| 41 |
A patch release should not contain any breaking changes. The release manager is responsible for reviewing all of the merged PRs since the last release to ensure that there are no breaking changes. If there are any breaking changes, the release manager should discuss with the maintainers to determine the best course of action if an obvious solution is not apparent. |
| 42 |
|
| 43 |
## 3. Compile Changelog |
| 44 |
The release changelog is set in two different places: |
| 45 |
1. The [Changelog.rst](https://github.com/celery/celery/blob/main/Changelog.rst) that uses the RST format. |
| 46 |
2. The GitHub Release auto-generated changelog that uses the Markdown format. This is auto-generated by the GitHub Draft Release UI. |
| 47 |
|
| 48 |
> ⚠️ **Warning:** The pre-commit changes should not be included in the changelog. |
| 49 |
|
| 50 |
To generate the changelog automatically, [draft a new release](https://github.com/celery/celery/releases/new) on GitHub using a fake new version tag for the automatic changelog generation. Notice the actual tag creation is done **on publish** so we can use that to generate the changelog and then delete the draft release without publishing it thus avoiding creating a new tag. |
| 51 |
|
| 52 |
- Create a new tag |
| 53 |
<img width="502" alt="CleanShot 2023-09-05 at 22 06 24@2x" src="https://github.com/celery/celery/assets/4662342/69d7eb78-0dd1-4a37-9266-d718e2340fad"> |
| 54 |
|
| 55 |
- Generate Markdown release notes |
| 56 |
<img width="389" alt="CleanShot 2023-09-05 at 22 13 39@2x" src="https://github.com/celery/celery/assets/4662342/83c6a4b6-1676-496e-8d75-5a6b10352b5b"> |
| 57 |
|
| 58 |
- Copy the generated release notes. |
| 59 |
|
| 60 |
- Delete the draft release without publishing it. |
| 61 |
|
| 62 |
### 3.1 Changelog.rst |
| 63 |
Once you have the actual changes, you need to convert it to rst format and add it to the [Changelog.rst](https://github.com/celery/celery/blob/main/Changelog.rst) file. The new version block needs to follow the following format: |
| 64 |
```rst |
| 65 |
.. _version-x.y.z: |
| 66 |
|
| 67 |
x.y.z |
| 68 |
===== |
| 69 |
|
| 70 |
:release-date: YYYY-MM-DD HH:MM P.M/A.M TimeZone |
| 71 |
:release-by: Release Manager Name |
| 72 |
|
| 73 |
Changes list in RST format. |
| 74 |
``` |
| 75 |
|
| 76 |
These changes will reflect in the [Change history](https://docs.celeryq.dev/en/stable/changelog.html) section of the documentation. |
| 77 |
|
| 78 |
### 3.2 Changelog PR |
| 79 |
The changes to the [Changelog.rst](https://github.com/celery/celery/blob/main/Changelog.rst) file should be submitted as a PR. This will PR should be the last merged PR before the release. |
| 80 |
|
| 81 |
## 4. Release |
| 82 |
### 4.1 Prepare releasing environment |
| 83 |
Before moving forward with the release, the release manager should ensure that bumpversion and twine are installed. These are required to publish the release. |
| 84 |
|
| 85 |
### 4.2 Bump version |
| 86 |
The release manager should bump the version using the following command: |
| 87 |
```bash |
| 88 |
bumpversion patch |
| 89 |
``` |
| 90 |
The changes should be pushed directly to main by the release manager. |
| 91 |
|
| 92 |
At this point, the git log should appear somewhat similar to this: |
| 93 |
``` |
| 94 |
commit XXX (HEAD -> main, tag: vX.Y.Z, upstream/main, origin/main) |
| 95 |
Author: Release Manager |
| 96 |
Date: YYY |
| 97 |
|
| 98 |
Bump version: a.b.c → x.y.z |
| 99 |
|
| 100 |
commit XXX |
| 101 |
Author: Release Manager |
| 102 |
Date: YYY |
| 103 |
|
| 104 |
Added changelog for vX.Y.Z (#1234) |
| 105 |
``` |
| 106 |
If everything looks good, the bump version commit can be directly pushed to `main`: |
| 107 |
```bash |
| 108 |
git push origin main --tags |
| 109 |
``` |
| 110 |
|
| 111 |
### 4.3 Publish release to PyPI |
| 112 |
The release manager should publish the release to PyPI using the following commands running under the root directory of the repository: |
| 113 |
```bash |
| 114 |
python setup.py clean build sdist bdist_wheel |
| 115 |
``` |
| 116 |
If the build is successful, the release manager should publish the release to PyPI using the following command: |
| 117 |
```bash |
| 118 |
twine upload dist/celery-X.Y.Z* |
| 119 |
``` |
| 120 |
|
| 121 |
> ⚠️ **Warning:** The release manager should double check that the release details are correct (project/version) before publishing the release to PyPI. |
| 122 |
|
| 123 |
> ⚠️ **Critical Reminder:** Should the released package prove to be faulty or need retraction for any reason, do not delete it from PyPI. The appropriate course of action is to "yank" the release. |
| 124 |
|
| 125 |
## Release Announcement |
| 126 |
After the release is published, the release manager should create a new GitHub Release and set it as the latest release. |
| 127 |
|
| 128 |
<img width="401" alt="CleanShot 2023-09-05 at 22 51 24@2x" src="https://github.com/celery/celery/assets/4662342/6edcba33-b6a9-4242-85e8-8260a2ede868"> |
| 129 |
|
| 130 |
### Add Release Notes |
| 131 |
On a per-case basis, the release manager may also attach an additional release note to the auto-generated release notes. This is usually done when there are important changes that are not reflected in the auto-generated release notes. |
| 132 |
|
| 133 |
### OpenCollective Update |
| 134 |
After successfully publishing the new release, the release manager is responsible for announcing it on the project's OpenCollective [page](https://opencollective.com/celery/updates). This is to engage with the community and keep backers and sponsors in the loop. |
| 135 |
|
| 136 |
|