Skip to content

Commit 7c1fb36

Browse files
authored
chore(dev/release): Update verification instructions for forthcoming release (#652)
This PR updates dev/release/README.md with the new version numbers, including a few changes that were required based on updated versions of the referenced images. I also had to be more flexible about the `python` used by the R package to do the bundling since on Windows `python3` launches an interactive Window and fails (while `python` is the thing that gets installed more typically by the Python installer). I removed centos7 from the directions since that image no longer exists! (We still test against it in CI using an old previously built image).
1 parent fc5ed2a commit 7c1fb36

File tree

2 files changed

+63
-89
lines changed

2 files changed

+63
-89
lines changed

dev/release/README.md

Lines changed: 48 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ Release candidates for nanoarrow are uploaded to https://dist.apache.org/repos/d
2525
prior to a release vote being called on the
2626
[Apache Arrow developer mailing list](https://lists.apache.org/[email protected]).
2727
A script (`verify-release-candidate.sh`) is provided to verify such a release candidate.
28-
For example, to verify nanoarrow 0.5.0-rc0, one could run:
28+
For example, to verify nanoarrow 0.6.0-rc0, one could run:
2929

3030
```bash
3131
git clone https://github.com/apache/arrow-nanoarrow.git arrow-nanoarrow
3232
cd arrow-nanoarrow/dev/release
33-
./verify-release-candidate.sh 0.5.0 0
33+
./verify-release-candidate.sh 0.6.0 0
3434
```
3535

3636
Full verification requires [CMake](https://cmake.org/download/) to build and run the test
@@ -56,19 +56,19 @@ manager except on Windows (see below).
5656
To run only C library verification (requires CMake and Arrow C++ but not R or Python):
5757

5858
```bash
59-
TEST_DEFAULT=0 TEST_C=1 TEST_C_BUNDLED=1 ./verify-release-candidate.sh 0.5.0 0
59+
TEST_DEFAULT=0 TEST_C=1 TEST_C_BUNDLED=1 ./verify-release-candidate.sh 0.6.0 0
6060
```
6161

6262
To run only R package verification (requires R but not CMake or Arrow C++):
6363

6464
```bash
65-
TEST_DEFAULT=0 TEST_R=1 ./verify-release-candidate.sh 0.5.0 0
65+
TEST_DEFAULT=0 TEST_R=1 ./verify-release-candidate.sh 0.6.0 0
6666
```
6767

6868
To run only Python verification (requires Python but not CMake or Arrow C++):
6969

7070
```bash
71-
TEST_DEFAULT=0 TEST_PYTHON=1 ./verify-release-candidate.sh 0.5.0 0
71+
TEST_DEFAULT=0 TEST_PYTHON=1 ./verify-release-candidate.sh 0.6.0 0
7272
```
7373

7474
### MacOS
@@ -120,7 +120,7 @@ conda create --name nanoarrow-verify-rc
120120
conda activate nanoarrow-verify-rc
121121
conda config --set channel_priority strict
122122

123-
conda install -c conda-forge compilers git cmake arrow-cpp
123+
conda install -c conda-forge compilers git cmake libarrow
124124
# For R (see below about potential interactions with system R
125125
# before installing via conda on MacOS)
126126
conda install -c conda-forge r-testthat r-hms r-blob r-pkgbuild r-bit64
@@ -148,17 +148,17 @@ the verification script.
148148

149149
```bash
150150
# Build Arrow C++ from source
151-
curl https://github.com/apache/arrow/archive/refs/tags/apache-arrow-14.0.2.tar.gz | \
151+
curl -L https://github.com/apache/arrow/archive/refs/tags/apache-arrow-17.0.0.tar.gz | \
152152
tar -zxf -
153153
mkdir arrow-build && cd arrow-build
154-
cmake ../apache-arrow-14.0.2/cpp -DCMAKE_INSTALL_PREFIX=../arrow
154+
cmake ../apache-arrow-17.0.0/cpp -DCMAKE_INSTALL_PREFIX=../arrow-minimal
155155
cmake --build .
156-
cmake --install . --prefix=../arrow --config=Debug
156+
cmake --install . --prefix=../arrow-minimal --config=Debug
157157
cd ..
158158

159159
# Pass location of Arrow and R to the verification script
160-
export NANOARROW_CMAKE_OPTIONS="-DArrow_DIR=$(pwd -W)/arrow/lib/cmake/Arrow -Dgtest_force_shared_crt=ON -DNANOARROW_ARROW_STATIC=ON"
161-
export R_HOME="/c/Program Files/R/R-4.2.2"
160+
export NANOARROW_CMAKE_OPTIONS="-DCMAKE_PREFIX_PATH=$(pwd -W)/arrow-minimal -Dgtest_force_shared_crt=ON -DNANOARROW_ARROW_STATIC=ON"
161+
export R_HOME="/c/Program Files/R/R-4.4.1"
162162
```
163163

164164
### Debian/Ubuntu
@@ -196,7 +196,7 @@ On Arch Linux (e.g., `docker run --rm -it archlinux:latest`, you can install all
196196
using `pacman`):
197197

198198
```bash
199-
pacman -S git gcc make cmake r-base gnupg curl arrow
199+
pacman -Sy git gcc make cmake r-base gnupg curl arrow python
200200
```
201201

202202
### Alpine Linux
@@ -220,47 +220,6 @@ apk add bash linux-headers git cmake R R-dev g++ gnupg curl apache-arrow-dev \
220220
python3-dev
221221
```
222222

223-
### Centos7
224-
225-
On Centos7 (e.g., `docker run --rm -it centos:7`), most prerequisites are
226-
available via `yum install` except Arrow C++, which must be built from
227-
source. Arrow C++ 9.0.0 was the last version to support the default system
228-
compiler (gcc 4.8).
229-
230-
```bash
231-
yum install epel-release # needed to install R
232-
yum install git gnupg curl R gcc-c++ cmake3
233-
234-
# Needed to get a warning-free R CMD check if the en_US.UTF-8 locale is not defined
235-
# (e.g., in the centos:7 docker image)
236-
# localedef -c -f UTF-8 -i en_US en_US.UTF-8
237-
# export LC_ALL=en_US.UTF-8
238-
239-
# Build Arrow C++ 9.0.0 from source
240-
curl -L https://github.com/apache/arrow/archive/refs/tags/apache-arrow-9.0.0.tar.gz | tar -zxf - && \
241-
mkdir /arrow-build && \
242-
cd /arrow-build && \
243-
cmake3 ../arrow-apache-arrow-9.0.0/cpp \
244-
-DARROW_JEMALLOC=OFF \
245-
-DARROW_SIMD_LEVEL=NONE \
246-
-DCMAKE_INSTALL_PREFIX=../arrow && \
247-
cmake3 --build . && \
248-
make install
249-
250-
# Pass location of Arrow, cmake, and ctest to the verification script
251-
export NANOARROW_CMAKE_OPTIONS="-DArrow_DIR=$(pwd)/arrow/lib64/cmake/arrow"
252-
export CMAKE_BIN=cmake3
253-
export CTEST_BIN=ctest3
254-
255-
# gpg on centos7 errors for some keys in the Arrow KEYS file. This does
256-
# not skip verifying signatures, just allows errors for unsupported entries in
257-
# the global Arrow KEYS file.
258-
export NANOARROW_ACCEPT_IMPORT_GPG_KEYS_ERROR=1
259-
260-
# System Python on centos7 is not new enough to support the Python package
261-
export TEST_PYTHON=0
262-
```
263-
264223
### Big endian
265224

266225
One can verify a nanoarrow release candidate on big endian by setting
@@ -270,7 +229,7 @@ One can verify a nanoarrow release candidate on big endian by setting
270229
## Creating a release candidate
271230

272231
The first step to creating a nanoarrow release is to create a `maint-VERSION` branch
273-
(e.g., `usethis::pr_init("maint-0.5.0")`) and push the branch to `upstream`. This is
232+
(e.g., `usethis::pr_init("maint-0.6.0")`) and push the branch to `upstream`. This is
274233
a good opportunity to run though the above instructions to make sure the verification
275234
script and instructions are up-to-date.
276235
targeting the maint-XX branch that was just pushed.
@@ -290,11 +249,11 @@ When these steps are complete, run
290249
```bash
291250
# from the repository root
292251
# 01-prepare.sh <nanoarrow-dir> <prev_veresion> <version> <next_version> <rc-num>
293-
dev/release/01-prepare.sh . 0.4.0 0.5.0 0.6.0 0
252+
dev/release/01-prepare.sh . 0.5.0 0.6.0 0.7.0 0
294253
```
295254

296255
This will update version numbers, the changelong, and create the git tag
297-
`apache-arrow-nanoarrow-0.5.0-rc0`. Check to make sure that the changelog
256+
`apache-arrow-nanoarrow-0.6.0-rc0`. Check to make sure that the changelog
298257
and versions are what you expect them to be before pushing the tag (you
299258
may wish to do this by opening a dummy PR to run CI and look at the diff
300259
from the main branch).
@@ -318,7 +277,7 @@ file to exist setting the appropriate `GPG_KEY_ID` environment variable.
318277

319278
```bash
320279
# 02-sign.sh <version> <rc-num>
321-
dev/release/02-sign.sh 0.5.0 0
280+
dev/release/02-sign.sh 0.6.0 0
322281
```
323282

324283
Finally, run
@@ -330,7 +289,7 @@ file to exist setting the appropriate `APACHE_USERNAME` environment variable.
330289

331290
```
332291
# 03-source.sh $0 <version> <rc-num>
333-
dev/release/03-source.sh 0.5.0 0
292+
dev/release/03-source.sh 0.6.0 0
334293
```
335294

336295
You should check that the release verification runs locally and/or
@@ -340,11 +299,11 @@ start a
340299
At this point the release candidate is suitable for a vote on the Apache Arrow developer mailing list.
341300

342301
```
343-
[VOTE] Release nanoarrow 0.5.0
302+
[VOTE] Release nanoarrow 0.6.0
344303
345304
Hello,
346305
347-
I would like to propose the following release candidate (rc0) of Apache Arrow nanoarrow [0] version 0.5.0. This is an initial release consisting of 44 resolved GitHub issues from 5 contributors [1].
306+
I would like to propose the following release candidate (rc0) of Apache Arrow nanoarrow [0] version 0.6.0. This is an initial release consisting of 44 resolved GitHub issues from 5 contributors [1].
348307
349308
This release candidate is based on commit: {rc_commit} [2]
350309
@@ -355,15 +314,15 @@ Please download, verify checksums and signatures, run the unit tests, and vote o
355314
356315
The vote will be open for at least 72 hours.
357316
358-
[ ] +1 Release this as Apache Arrow nanoarrow 0.5.0
317+
[ ] +1 Release this as Apache Arrow nanoarrow 0.6.0
359318
[ ] +0
360-
[ ] -1 Do not release this as Apache Arrow nanoarrow 0.5.0 because...
319+
[ ] -1 Do not release this as Apache Arrow nanoarrow 0.6.0 because...
361320
362321
[0] https://github.com/apache/arrow-nanoarrow
363322
[1] https://github.com/apache/arrow-nanoarrow/milestone/4?closed=1
364-
[2] https://github.com/apache/arrow-nanoarrow/tree/apache-arrow-nanoarrow-0.5.0-rc0
365-
[3] https://dist.apache.org/repos/dist/dev/arrow/apache-arrow-nanoarrow-0.5.0-rc0/
366-
[4] https://github.com/apache/arrow-nanoarrow/blob/apache-arrow-nanoarrow-0.5.0-rc0/CHANGELOG.md
323+
[2] https://github.com/apache/arrow-nanoarrow/tree/apache-arrow-nanoarrow-0.6.0-rc0
324+
[3] https://dist.apache.org/repos/dist/dev/arrow/apache-arrow-nanoarrow-0.6.0-rc0/
325+
[4] https://github.com/apache/arrow-nanoarrow/blob/apache-arrow-nanoarrow-0.6.0-rc0/CHANGELOG.md
367326
[5] https://github.com/apache/arrow-nanoarrow/blob/main/dev/release/README.md
368327
```
369328

@@ -397,7 +356,7 @@ and mark it as closed.
397356
The reporter system for Arrow can be found at
398357
<https://reporter.apache.org/addrelease.html?arrow>. To add a release, a
399358
PMC member must log in with their Apache username/password. The release
400-
names are in the form `NANOARROW-0.5.0`.
359+
names are in the form `NANOARROW-0.6.0`.
401360

402361
### Upload artifacts to Subversion / Create GitHub Release
403362

@@ -407,7 +366,7 @@ This script must be run by a PMC member whose `APACHE_USERNAME` environment vari
407366
has been set in `.env`.
408367

409368
```bash
410-
dev/release/post-01-upload.sh 0.5.0 0
369+
dev/release/post-01-upload.sh 0.6.0 0
411370
```
412371

413372
### Submit R package to CRAN
@@ -419,8 +378,8 @@ Before a release candidate is created, the first section of
419378
`usethis::use_release_issue()` should all be completed (i.e., any changes
420379
after release should be minor tweaks). The steps are:
421380

422-
- Ensure you are on the release branch (i.e., `git switch maint-0.5.0`)
423-
- Run `usethis::pr_init("r-cran-maint-0.5.0")` and push the branch to your
381+
- Ensure you are on the release branch (i.e., `git switch maint-0.6.0`)
382+
- Run `usethis::pr_init("r-cran-maint-0.6.0")` and push the branch to your
424383
fork.
425384
- Ensure `cran_comments.md` is up-to-date.
426385
- Run `devtools::check()` locally and verify that the package version is correct
@@ -432,12 +391,12 @@ after release should be minor tweaks). The steps are:
432391
Any changes required at this stage should be made as a PR into `main` and
433392
cherry-picked into the `r-cran-maint-XXX` packaging branch. (i.e.,
434393
`git cherry-pick 01234abcdef`). If any changes
435-
to the source are required, bump the "tweak" version (e.g., `Version: 0.5.0.1`
394+
to the source are required, bump the "tweak" version (e.g., `Version: 0.6.0.1`
436395
in `DESCRIPTION`).
437396

438397
### Submit Python package to PyPI
439398

440-
The Python package source distribution and wheels are built using the [Build Python Wheels](https://github.com/apache/arrow-nanoarrow/actions/workflows/python-wheels.yaml) action on the `maint-0.5.0` branch after cutting the release candidate.
399+
The Python package source distribution and wheels are built using the [Build Python Wheels](https://github.com/apache/arrow-nanoarrow/actions/workflows/python-wheels.yaml) action on the `maint-0.6.0` branch after cutting the release candidate.
441400

442401
To submit these to PyPI, download all assets from the run into a folder (e.g., `python/dist`) and run:
443402

@@ -467,18 +426,18 @@ git clone -b asf-site --single-branch https://github.com/apache/arrow-nanoarrow.
467426
cd arrow-nanoarrow
468427
```
469428

470-
Download the [0.5.0 documentation](https://github.com/apache/arrow-nanoarrow/releases/download/apache-arrow-nanoarrow-0.5.0/docs.tgz):
429+
Download the [0.6.0 documentation](https://github.com/apache/arrow-nanoarrow/releases/download/apache-arrow-nanoarrow-0.6.0/docs.tgz):
471430

472431
```shell
473-
curl -L https://github.com/apache/arrow-nanoarrow/releases/download/apache-arrow-nanoarrow-0.5.0/docs.tgz \
432+
curl -L https://github.com/apache/arrow-nanoarrow/releases/download/apache-arrow-nanoarrow-0.6.0/docs.tgz \
474433
-o docs.tgz
475434
```
476435

477-
Extract the documentation and rename the directory to `0.5.0`:
436+
Extract the documentation and rename the directory to `0.6.0`:
478437

479438
```shell
480439
tar -xvzf docs.tgz
481-
mv nanoarrow-docs 0.5.0
440+
mv nanoarrow-docs 0.6.0
482441
```
483442

484443
Then remove the existing `latest` directory and run the extraction again, renaming to `latest` instead:
@@ -489,7 +448,7 @@ tar -xvzf docs.tgz
489448
mv nanoarrow-docs latest
490449
```
491450

492-
Finally, update `switcher.json` with entries pointing `/latest/` and `/0.5.0/` to `"version": "0.5.0"`:
451+
Finally, update `switcher.json` with entries pointing `/latest/` and `/0.6.0/` to `"version": "0.6.0"`:
493452

494453
```json
495454
[
@@ -498,16 +457,16 @@ Finally, update `switcher.json` with entries pointing `/latest/` and `/0.5.0/` t
498457
"url": "https://arrow.apache.org/nanoarrow/main/"
499458
},
500459
{
501-
"version": "0.5.0",
460+
"version": "0.6.0",
502461
"url": "https://arrow.apache.org/nanoarrow/latest/"
503462
},
504463
{
505-
"version": "0.5.0",
506-
"url": "https://arrow.apache.org/nanoarrow/0.5.0/"
464+
"version": "0.6.0",
465+
"url": "https://arrow.apache.org/nanoarrow/0.6.0/"
507466
},
508467
{
509-
"version": "0.4.0",
510-
"url": "https://arrow.apache.org/nanoarrow/0.4.0/"
468+
"version": "0.5.0",
469+
"url": "https://arrow.apache.org/nanoarrow/0.5.0/"
511470
},
512471
...
513472
]
@@ -529,9 +488,9 @@ the `mail-relay.apache.org` outgoing server.
529488
Email template:
530489

531490
```
532-
[ANNOUNCE] Apache Arrow nanoarrow 0.5.0 Released
491+
[ANNOUNCE] Apache Arrow nanoarrow 0.6.0 Released
533492
534-
The Apache Arrow community is pleased to announce the 0.5.0 release of
493+
The Apache Arrow community is pleased to announce the 0.6.0 release of
535494
Apache Arrow nanoarrow. This initial release covers 79 resolved issues
536495
from 9 contributors[1].
537496
@@ -567,10 +526,10 @@ Please report any feedback to the mailing lists ([6], [7]).
567526
Regards,
568527
The Apache Arrow Community
569528
570-
[1] https://github.com/apache/arrow-nanoarrow/issues?q=milestone%3A%22nanoarrow+0.5.0%22+is%3Aclosed
571-
[2] https://www.apache.org/dyn/closer.cgi/arrow/apache-arrow-nanoarrow-0.5.0
572-
[3] https://github.com/apache/arrow-nanoarrow/blob/apache-arrow-nanoarrow-0.5.0/CHANGELOG.md
573-
[4] https://arrow.apache.org/blog/2024/05/27/nanoarrow-0.5.0-release/
529+
[1] https://github.com/apache/arrow-nanoarrow/issues?q=milestone%3A%22nanoarrow+0.6.0%22+is%3Aclosed
530+
[2] https://www.apache.org/dyn/closer.cgi/arrow/apache-arrow-nanoarrow-0.6.0
531+
[3] https://github.com/apache/arrow-nanoarrow/blob/apache-arrow-nanoarrow-0.6.0/CHANGELOG.md
532+
[4] https://arrow.apache.org/blog/2024/05/27/nanoarrow-0.6.0-release/
574533
[5] https://arrow.apache.org/nanoarrow/
575534
[6] https://lists.apache.org/[email protected]
576535
[7] https://lists.apache.org/[email protected]
@@ -586,7 +545,7 @@ using:
586545
# Once
587546
export APACHE_USERNAME=xxx
588547
# Once for every release candidate
589-
svn rm --username=$APACHE_USERNAME -m "Clean up svn artifacts" https://dist.apache.org/repos/dist/dev/arrow/apache-arrow-nanoarrow-0.5.0-rc0/
548+
svn rm --username=$APACHE_USERNAME -m "Clean up svn artifacts" https://dist.apache.org/repos/dist/dev/arrow/apache-arrow-nanoarrow-0.6.0-rc0/
590549
```
591550

592551
### Bumped versions on main
@@ -595,5 +554,5 @@ This is handled by
595554
[post-02-bump-versions.sh](https://github.com/apache/arrow-nanoarrow/blob/main/dev/release/post-02-bump-versions.sh). Create a branch and then run:
596555

597556
```bash
598-
dev/release/post-02-bump-versions.sh . 0.5.0 0.6.0
557+
dev/release/post-02-bump-versions.sh . 0.6.0 0.7.0
599558
```

r/bootstrap.R

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,21 @@
1818
# Use ci/scripts/bundle.py to generate source files/headers that are
1919
# easier to use with the default R package build system
2020

21+
python <- function() {
22+
from_env <- Sys.getenv("PYTHON_BIN", "python3")
23+
has_from_env <- system(
24+
paste(from_env, "--version"),
25+
ignore.stdout = TRUE,
26+
ignore.stderr = TRUE
27+
)
28+
29+
if (has_from_env == 0) {
30+
from_env
31+
} else {
32+
"python"
33+
}
34+
}
35+
2136
run_bundler <- function() {
2237
args <- c(
2338
"--symbol-namespace=RPkg",

0 commit comments

Comments
 (0)