Skip to content

Commit 2715a32

Browse files
authored
chore: update release documentation (#1494)
* Update release documentation * Minor change to workflow because release start at 1
1 parent 398980d commit 2715a32

File tree

2 files changed

+32
-30
lines changed

2 files changed

+32
-30
lines changed

.github/workflows/verify-release-candidate.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ on:
2727
required: true
2828
type: string
2929
rc_number:
30-
description: Release candidate number (e.g., 0)
30+
description: Release candidate number (e.g., 1)
3131
required: true
3232
type: string
3333

dev/release/README.md

Lines changed: 31 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ required due to changes in DataFusion rather than having a large amount of work
2626
is available.
2727

2828
When there is a new official release of DataFusion, we update the `main` branch to point to that, update the version
29-
number, and create a new release branch, such as `branch-0.8`. Once this branch is created, we switch the `main` branch
29+
number, and create a new release branch, such as `branch-53`. Once this branch is created, we switch the `main` branch
3030
back to using GitHub dependencies. The release activity (such as generating the changelog) can then happen on the
3131
release branch without blocking ongoing development in the `main` branch.
3232

33-
We can cherry-pick commits from the `main` branch into `branch-0.8` as needed and then create new patch releases
33+
We can cherry-pick commits from the `main` branch into `branch-53` as needed and then create new patch releases
3434
from that branch.
3535

3636
## Detailed Guide
@@ -54,7 +54,8 @@ Before creating a new release:
5454

5555
- We need to ensure that the main branch does not have any GitHub dependencies
5656
- a PR should be created and merged to update the major version number of the project
57-
- A new release branch should be created, such as `branch-0.8`
57+
- A new release branch should be created, such as `branch-53`
58+
- It is best to push this branch to the apache repository rather than a personal fork in case patch releases are required.
5859

5960
## Preparing a Release Candidate
6061

@@ -65,14 +66,14 @@ We maintain a `CHANGELOG.md` so our users know what has been changed between rel
6566
The changelog is generated using a Python script:
6667

6768
```bash
68-
$ GITHUB_TOKEN=<TOKEN> ./dev/release/generate-changelog.py 24.0.0 HEAD 25.0.0 > dev/changelog/25.0.0.md
69+
$ GITHUB_TOKEN=<TOKEN> ./dev/release/generate-changelog.py 52.0.0 HEAD 53.0.0 > dev/changelog/53.0.0.md
6970
```
7071

7172
This script creates a changelog from GitHub PRs based on the labels associated with them as well as looking for
7273
titles starting with `feat:`, `fix:`, or `docs:` . The script will produce output similar to:
7374

7475
```
75-
Fetching list of commits between 24.0.0 and HEAD
76+
Fetching list of commits between 52.0.0 and HEAD
7677
Fetching pull requests
7778
Categorizing pull requests
7879
Generating changelog content
@@ -81,6 +82,7 @@ Generating changelog content
8182
### Update the version number
8283

8384
The only place you should need to update the version is in the root `Cargo.toml`.
85+
You will need to update this both in the workspace section and also in the dependencies.
8486
After updating the toml file, run `cargo update` to update the cargo lock file.
8587
If you do not want to update all the dependencies, you can instead run `cargo build`
8688
which should only update the version number for `datafusion-python`.
@@ -94,14 +96,14 @@ you need to push a tag to start the CI process for release candidates. The follo
9496
the upstream repository is called `apache`.
9597

9698
```bash
97-
git tag 0.8.0-rc1
98-
git push apache 0.8.0-rc1
99+
git tag 53.0.0-rc1
100+
git push apache 53.0.0-rc1
99101
```
100102

101103
### Create a source release
102104

103105
```bash
104-
./dev/release/create-tarball.sh 0.8.0 1
106+
./dev/release/create-tarball.sh 53.0.0 1
105107
```
106108

107109
This will also create the email template to send to the mailing list.
@@ -124,34 +126,34 @@ Click on the action and scroll down to the bottom of the page titled "Artifacts"
124126
contain files such as:
125127

126128
```text
127-
datafusion-22.0.0-cp37-abi3-macosx_10_7_x86_64.whl
128-
datafusion-22.0.0-cp37-abi3-macosx_11_0_arm64.whl
129-
datafusion-22.0.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
130-
datafusion-22.0.0-cp37-abi3-win_amd64.whl
129+
datafusion-53.0.0-cp37-abi3-macosx_10_7_x86_64.whl
130+
datafusion-53.0.0-cp37-abi3-macosx_11_0_arm64.whl
131+
datafusion-53.0.0-cp37-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
132+
datafusion-53.0.0-cp37-abi3-win_amd64.whl
131133
```
132134

133135
Upload the wheels to testpypi.
134136

135137
```bash
136138
unzip dist.zip
137139
python3 -m pip install --upgrade setuptools twine build
138-
python3 -m twine upload --repository testpypi datafusion-22.0.0-cp37-abi3-*.whl
140+
python3 -m twine upload --repository testpypi datafusion-53.0.0-cp37-abi3-*.whl
139141
```
140142

141143
When prompted for username, enter `__token__`. When prompted for a password, enter a valid GitHub Personal Access Token
142144

143145
#### Publish Python Source Distribution to testpypi
144146

145-
Download the source tarball created in the previous step, untar it, and run:
147+
Download the source tarball from the Apache server created in the previous step, untar it, and run:
146148

147149
```bash
148150
maturin sdist
149151
```
150152

151-
This will create a file named `dist/datafusion-0.7.0.tar.gz`. Upload this to testpypi:
153+
This will create a file named `dist/datafusion-53.0.0.tar.gz`. Upload this to testpypi:
152154

153155
```bash
154-
python3 -m twine upload --repository testpypi dist/datafusion-0.7.0.tar.gz
156+
python3 -m twine upload --repository testpypi dist/datafusion-53.0.0.tar.gz
155157
```
156158

157159
### Run Verify Release Candidate Workflow
@@ -162,8 +164,8 @@ Before sending the vote email, run the manually triggered GitHub Actions workflo
162164

163165
1. Go to https://github.com/apache/datafusion-python/actions/workflows/verify-release-candidate.yml
164166
2. Click "Run workflow"
165-
3. Set `version` to the release version (for example, `52.0.0`)
166-
4. Set `rc_number` to the RC number (for example, `0`)
167+
3. Set `version` to the release version (for example, `53.0.0`)
168+
4. Set `rc_number` to the RC number (for example, `1`)
167169
5. Wait for all jobs to complete successfully
168170

169171
Include a short note in the vote email template that this workflow was run across all OS/architecture
@@ -183,7 +185,7 @@ Releases may be verified using `verify-release-candidate.sh`:
183185

184186
```bash
185187
git clone https://github.com/apache/datafusion-python.git
186-
dev/release/verify-release-candidate.sh 48.0.0 1
188+
dev/release/verify-release-candidate.sh 53.0.0 1
187189
```
188190

189191
Alternatively, one can run unit tests against a testpypi release candidate:
@@ -195,15 +197,15 @@ cd datafusion-python
195197

196198
# checkout the release commit
197199
git fetch --tags
198-
git checkout 40.0.0-rc1
200+
git checkout 53.0.0-rc1
199201
git submodule update --init --recursive
200202

201203
# create the env
202204
python3 -m venv .venv
203205
source .venv/bin/activate
204206

205207
# install release candidate
206-
pip install --extra-index-url https://test.pypi.org/simple/ datafusion==40.0.0
208+
pip install --extra-index-url https://test.pypi.org/simple/ datafusion==53.0.0
207209

208210
# install test dependencies
209211
pip install pytest numpy pytest-asyncio
@@ -224,15 +226,15 @@ Once the vote passes, we can publish the release.
224226
Create the source release tarball:
225227

226228
```bash
227-
./dev/release/release-tarball.sh 0.8.0 1
229+
./dev/release/release-tarball.sh 53.0.0 1
228230
```
229231

230232
### Publishing Rust Crate to crates.io
231233

232234
Some projects depend on the Rust crate directly, so we publish this to crates.io
233235

234236
```shell
235-
cargo publish
237+
cargo publish --workspace
236238
```
237239

238240
### Publishing Python Artifacts to PyPi
@@ -252,15 +254,15 @@ Pypi packages auto upload to conda-forge via [datafusion feedstock](https://gith
252254
### Push the Release Tag
253255

254256
```bash
255-
git checkout 0.8.0-rc1
256-
git tag 0.8.0
257-
git push apache 0.8.0
257+
git checkout 53.0.0-rc1
258+
git tag 53.0.0
259+
git push apache 53.0.0
258260
```
259261

260262
### Add the release to Apache Reporter
261263

262264
Add the release to https://reporter.apache.org/addrelease.html?datafusion with a version name prefixed with `DATAFUSION-PYTHON`,
263-
for example `DATAFUSION-PYTHON-31.0.0`.
265+
for example `DATAFUSION-PYTHON-53.0.0`.
264266

265267
The release information is used to generate a template for a board report (see example from Apache Arrow
266268
[here](https://github.com/apache/arrow/pull/14357)).
@@ -283,7 +285,7 @@ svn ls https://dist.apache.org/repos/dist/dev/datafusion | grep datafusion-pytho
283285
Delete a release candidate:
284286

285287
```bash
286-
svn delete -m "delete old DataFusion RC" https://dist.apache.org/repos/dist/dev/datafusion/apache-datafusion-python-7.1.0-rc1/
288+
svn delete -m "delete old DataFusion RC" https://dist.apache.org/repos/dist/dev/datafusion/apache-datafusion-python-53.0.0-rc1/
287289
```
288290

289291
#### Deleting old releases from `release` svn
@@ -299,5 +301,5 @@ svn ls https://dist.apache.org/repos/dist/release/datafusion | grep datafusion-p
299301
Delete a release:
300302

301303
```bash
302-
svn delete -m "delete old DataFusion release" https://dist.apache.org/repos/dist/release/datafusion/datafusion-python-7.0.0
304+
svn delete -m "delete old DataFusion release" https://dist.apache.org/repos/dist/release/datafusion/datafusion-python-52.0.0
303305
```

0 commit comments

Comments
 (0)