This is an automated email from the ASF dual-hosted git repository.

jiayu pushed a commit to branch branch-0.1.0
in repository https://gitbox.apache.org/repos/asf/sedona-spatialbench.git

commit b97f769151f80e4aef446543305180251d356805
Author: Jia Yu <[email protected]>
AuthorDate: Tue Nov 25 21:00:06 2025 -0800

    Update release script
---
 dev/release/README.md                   | 35 +++++++++++++++++++++++++++++----
 dev/release/check-rat-report.py         |  1 +
 dev/release/rat_exclude_files.txt       |  1 +
 dev/release/run-rat.sh                  |  1 +
 dev/release/sign-assets.sh              |  1 +
 dev/release/upload-candidate.sh         |  1 +
 dev/release/upload-release.sh           |  1 +
 dev/release/verify-release-candidate.sh | 30 +++++++++++++++++++++++++---
 8 files changed, 64 insertions(+), 7 deletions(-)

diff --git a/dev/release/README.md b/dev/release/README.md
index 745bc93..8860e43 100644
--- a/dev/release/README.md
+++ b/dev/release/README.md
@@ -21,18 +21,45 @@
 
 ## Verifying a release candidate
 
-Release candidates are verified using the script `verify-release-candidate.sh 
<version> <rc_num>`.
-For example, to verify SpatialBench 0.1.0 RC1, run:
+### Testing locally (before creating a release candidate)
+
+Before creating a release candidate, you should test your local checkout:
 
 ```shell
 # git clone https://github.com/apache/sedona-spatialbench.git && cd 
sedona-spatialbench
 # or
 # cd existing/sedona-spatialbench && git fetch upstream && git switch main && 
git pull upstream main
+dev/release/verify-release-candidate.sh
+```
+
+This will run all verification tests on your local checkout without requiring 
any release artifacts.
+
+### Testing a local tarball
+
+If you have a tarball you want to test before uploading:
+
+```shell
+dev/release/verify-release-candidate.sh 
/path/to/apache-sedona-spatialbench-0.1.0.tar.gz
+```
+
+### Verifying an official release candidate
+
+Once a release candidate has been uploaded to Apache dist, verify it using:
+
+```shell
 dev/release/verify-release-candidate.sh 0.1.0 1
 ```
 
-Release verification requires a recent Rust toolchain. This toolchain can be 
installed
-by following instructions from <https://rustup.rs/>.
+This will download the release candidate from 
`https://dist.apache.org/repos/dist/dev/sedona/` and verify it.
+
+Release verification requires:
+- A recent Rust toolchain (can be installed from <https://rustup.rs/>)
+- Java (for Apache RAT license checking)
+- Python (for RAT report filtering)
+
+The verification script will:
+1. Run Apache RAT to check all files have proper license headers
+2. Build and test all Rust crates in the workspace
 
 When verifying via Docker or on a smaller machine it may be necessary to limit 
the
 number of parallel jobs to avoid running out of memory:
diff --git a/dev/release/check-rat-report.py b/dev/release/check-rat-report.py
index b9fd85a..6a6da09 100644
--- a/dev/release/check-rat-report.py
+++ b/dev/release/check-rat-report.py
@@ -57,3 +57,4 @@ if not all_ok:
 print("OK")
 sys.exit(0)
 
+
diff --git a/dev/release/rat_exclude_files.txt 
b/dev/release/rat_exclude_files.txt
index c3a17d7..5a4c249 100644
--- a/dev/release/rat_exclude_files.txt
+++ b/dev/release/rat_exclude_files.txt
@@ -9,3 +9,4 @@ spatialbench/data/sf-v1/*.tbl.gz
 spatialbench/data/sf-v1/*.parquet
 dev/release/rat_exclude_files.txt
 
+
diff --git a/dev/release/run-rat.sh b/dev/release/run-rat.sh
index 78eba22..807dedf 100755
--- a/dev/release/run-rat.sh
+++ b/dev/release/run-rat.sh
@@ -41,3 +41,4 @@ else
   exit 1
 fi
 
+
diff --git a/dev/release/sign-assets.sh b/dev/release/sign-assets.sh
index 18f56c8..1e51d5c 100755
--- a/dev/release/sign-assets.sh
+++ b/dev/release/sign-assets.sh
@@ -147,3 +147,4 @@ upload_asset_signatures() {
 
 main "$@"
 
+
diff --git a/dev/release/upload-candidate.sh b/dev/release/upload-candidate.sh
index bffba60..d381497 100755
--- a/dev/release/upload-candidate.sh
+++ b/dev/release/upload-candidate.sh
@@ -82,3 +82,4 @@ header() {
 
 main "$@"
 
+
diff --git a/dev/release/upload-release.sh b/dev/release/upload-release.sh
index 71bf530..abe03ad 100755
--- a/dev/release/upload-release.sh
+++ b/dev/release/upload-release.sh
@@ -53,3 +53,4 @@ main() {
 
 main "$@"
 
+
diff --git a/dev/release/verify-release-candidate.sh 
b/dev/release/verify-release-candidate.sh
index 4a55d9b..f1bc88a 100755
--- a/dev/release/verify-release-candidate.sh
+++ b/dev/release/verify-release-candidate.sh
@@ -28,7 +28,7 @@ fi
 check_dependencies() {
   local missing_deps=0
 
-  local required_deps=("curl" "git" "gpg" "cargo")
+  local required_deps=("curl" "git" "gpg" "cargo" "java" "python")
   for dep in "${required_deps[@]}"; do
     if ! command -v $dep &> /dev/null; then
       echo "Error: $dep is not installed or not in PATH"
@@ -102,12 +102,19 @@ show_info() {
 SPATIALBENCH_DIST_URL='https://dist.apache.org/repos/dist/dev/sedona'
 
 download_dist_file() {
-  curl \
+  local url="${SPATIALBENCH_DIST_URL}/$1"
+  if ! curl \
     --silent \
     --show-error \
     --fail \
     --location \
-    --remote-name $SPATIALBENCH_DIST_URL/$1
+    --remote-name "$url"; then
+    echo "Error: Failed to download $url"
+    echo "This usually means the release candidate has not been uploaded yet."
+    echo "To test locally, run: $0"
+    echo "Or to test a local tarball: $0 /path/to/tarball.tar.gz"
+    exit 1
+  fi
 }
 
 download_rc_file() {
@@ -196,6 +203,18 @@ test_rust() {
   popd
 }
 
+test_rat() {
+  show_header "Running Apache RAT license check"
+
+  local -r release_dir="$( cd "$( dirname "${BASH_SOURCE[0]:-$0}")" && pwd )"
+  pushd "${SPATIALBENCH_SOURCE_DIR}"
+  
+  # Run RAT check using the run-rat.sh script
+  bash "${release_dir}/run-rat.sh" "${SPATIALBENCH_SOURCE_DIR}"
+  
+  popd
+}
+
 ensure_source_directory() {
   show_header "Ensuring source directory"
 
@@ -234,6 +253,10 @@ ensure_source_directory() {
 test_source_distribution() {
   pushd $SPATIALBENCH_SOURCE_DIR
 
+  if [ ${TEST_RAT} -gt 0 ]; then
+    test_rat
+  fi
+
   if [ ${TEST_RUST} -gt 0 ]; then
     test_rust
   fi
@@ -247,6 +270,7 @@ test_source_distribution() {
 : ${TEST_DEFAULT:=1}
 
 : ${TEST_SOURCE:=${TEST_DEFAULT}}
+: ${TEST_RAT:=${TEST_SOURCE}}
 : ${TEST_RUST:=${TEST_SOURCE}}
 
 TEST_SUCCESS=no

Reply via email to