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

paleolimbot pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/sedona-db.git


The following commit(s) were added to refs/heads/main by this push:
     new 44cd170  chore(ci): Bump caches (#222)
44cd170 is described below

commit 44cd170a5b3fee5af3b58a1f4a52330d91090324
Author: Dewey Dunnington <[email protected]>
AuthorDate: Thu Oct 16 14:25:32 2025 -0500

    chore(ci): Bump caches (#222)
---
 .github/workflows/packaging.yml     |  2 +-
 .github/workflows/python-wheels.yml |  4 ++--
 .github/workflows/python.yml        |  4 ++--
 .github/workflows/r.yml             | 26 ++++++++++++++++++++------
 .github/workflows/rust.yml          |  5 +++--
 5 files changed, 28 insertions(+), 13 deletions(-)

diff --git a/.github/workflows/packaging.yml b/.github/workflows/packaging.yml
index c4c116e..4e640fa 100644
--- a/.github/workflows/packaging.yml
+++ b/.github/workflows/packaging.yml
@@ -111,7 +111,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache (but share with the 
python.yml workflow)
-          prefix-key: "python-v1"
+          prefix-key: "python-v2"
 
       - name: Install docs requirements
         run: |
diff --git a/.github/workflows/python-wheels.yml 
b/.github/workflows/python-wheels.yml
index 441d7b0..2232cc8 100644
--- a/.github/workflows/python-wheels.yml
+++ b/.github/workflows/python-wheels.yml
@@ -60,7 +60,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache
-          prefix-key: "python-wheel-windows-latest-v1"
+          prefix-key: "python-wheel-windows-latest-v2"
 
       - name: Clone vcpkg
         uses: actions/checkout@v4
@@ -117,7 +117,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache
-          prefix-key: "python-wheel-macOS-latest-v1"
+          prefix-key: "python-wheel-macOS-latest-v2"
 
       - name: Clone vcpkg
         uses: actions/checkout@v4
diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml
index 2f447b5..fd242e5 100644
--- a/.github/workflows/python.yml
+++ b/.github/workflows/python.yml
@@ -92,7 +92,7 @@ jobs:
         with:
           path: vcpkg/packages
           # Bump the number at the end of this line to force a new dependency 
build
-          key: vcpkg-installed-${{ runner.os }}-${{ runner.arch }}-${{ 
env.VCPKG_REF }}-1
+          key: vcpkg-installed-${{ runner.os }}-${{ runner.arch }}-${{ 
env.VCPKG_REF }}-2
 
       - name: Install vcpkg dependencies
         if: steps.cache-vcpkg.outputs.cache-hit != 'true'
@@ -112,7 +112,7 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache (sync with packaging.yml)
-          prefix-key: "python-v1"
+          prefix-key: "python-v2"
 
       - name: Install
         run: |
diff --git a/.github/workflows/r.yml b/.github/workflows/r.yml
index 2a384e6..151809b 100644
--- a/.github/workflows/r.yml
+++ b/.github/workflows/r.yml
@@ -61,16 +61,19 @@ jobs:
           use-public-rspm: true
 
       - name: Use stable Rust
-        id: rust
+        if: matrix.config.os != 'windows-latest'
         run: |
           rustup toolchain install stable --no-self-update
           rustup default stable
 
-      # GHA runner installs GNU target by default, but --no-self-update might
-      # remove it, so run `target add` to ensure the GNU target installed.
-      - name: Setup Rust (Windows)
+      # Set the default toolchain here so that rust-cache saves/restores
+      # the correct target. (The R package will use this target regardless,
+      # this just in theory helps the cache)
+      - name: Use stable Rust (windows)
         if: matrix.config.os == 'windows-latest'
-        run: rustup target add x86_64-pc-windows-gnu
+        run: |
+          rustup toolchain install stable-x86_64-pc-windows-gnu 
--no-self-update
+          rustup default stable-x86_64-pc-windows-gnu
 
       - name: Install dependencies (Linux)
         if: matrix.config.os == 'ubuntu-latest'
@@ -83,7 +86,18 @@ jobs:
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache
-          prefix-key: "r-v2"
+          prefix-key: "r-v3"
+          # The R package uses its own target directory
+          workspaces: ". -> r/sedonadb/src/rust/target"
+
+      # Explicitly specify for Windows, which otherwise chooses a shorter 
version
+      # to work around a path length limitation when building from longer 
starting paths.
+      # This allows us to use a common cache configuration for Windows, MacOS, 
and Linux
+      - name: Set R/Rust target directory
+        if: matrix.config.os == 'windows-latest'
+        run: |
+          echo "SEDONADB_TARGET_DIR=$(pwd -W)/r/sedonadb/src/rust/target" >> 
$GITHUB_ENV
+        shell: bash
 
       - uses: r-lib/actions/setup-r-dependencies@v2
         with:
diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml
index f7ea8d1..6095911 100644
--- a/.github/workflows/rust.yml
+++ b/.github/workflows/rust.yml
@@ -91,7 +91,7 @@ jobs:
         with:
           path: vcpkg/packages
           # Bump the number at the end of this line to force a new dependency 
build
-          key: vcpkg-installed-${{ runner.os }}-${{ runner.arch }}-${{ 
env.VCPKG_REF }}-1
+          key: vcpkg-installed-${{ runner.os }}-${{ runner.arch }}-${{ 
env.VCPKG_REF }}-2
 
       - name: Install vcpkg dependencies
         if: steps.cache-vcpkg.outputs.cache-hit != 'true'
@@ -106,10 +106,11 @@ jobs:
         run: |
           rustup toolchain install stable --no-self-update
           rustup default stable
+
       - uses: Swatinem/rust-cache@v2
         with:
           # Update this key to force a new cache
-          prefix-key: "rust-${{ matrix.name }}-v3"
+          prefix-key: "rust-${{ matrix.name }}-v4"
 
       - name: Free Disk Space (Ubuntu)
         uses: jlumbroso/free-disk-space@main

Reply via email to