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

yuxia pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/fluss-rust.git


The following commit(s) were added to refs/heads/main by this push:
     new 6d9c89f  [chore] Fix build fail on mac os (#61)
6d9c89f is described below

commit 6d9c89f74a1e1c185e21c2551c33c02abcb4eb36
Author: Evan <[email protected]>
AuthorDate: Tue Nov 25 13:21:59 2025 +0100

    [chore] Fix build fail on mac os (#61)
---
 .github/.DS_Store        | Bin 6148 -> 0 bytes
 .github/workflows/ci.yml |  55 +++++++++++++++++++++++++++++++++++++----------
 2 files changed, 44 insertions(+), 11 deletions(-)

diff --git a/.github/.DS_Store b/.github/.DS_Store
deleted file mode 100644
index 7adc49d..0000000
Binary files a/.github/.DS_Store and /dev/null differ
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 69625f8..cf7a126 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -54,17 +54,34 @@ jobs:
         os:
           - ubuntu-latest
           - macos-latest
+        python: ["3.11", "3.12", "3.13"]
     steps:
       - uses: actions/checkout@v4
+
+      - name: Set up Python
+        uses: actions/setup-python@v5
+        with:
+          python-version: ${{ matrix.python }}
+
       - name: Install protoc
         run: |
-          if [ "$RUNNER_OS" == "Linux" ]; then
+          if [ "$RUNNER_OS" = "Linux" ]; then
             sudo apt-get update && sudo apt-get install -y protobuf-compiler
-          elif [ "$RUNNER_OS" == "macOS" ]; then
+          elif [ "$RUNNER_OS" = "macOS" ]; then
             brew install protobuf
           fi
+
+      - name: Rust Cache
+        uses: actions/cache@v4
+        with:
+          path: |
+            ~/.cargo/registry
+            ~/.cargo/git
+            target
+          key: build-${{ runner.os }}-${{ matrix.python }}-${{ 
hashFiles('**/Cargo.lock') }}
+
       - name: Build
-        run: cargo build
+        run: cargo build --workspace --all-targets
 
   test:
     runs-on: ${{ matrix.os }}
@@ -73,26 +90,42 @@ jobs:
         os:
           - ubuntu-latest
           - macos-latest
+        python: ["3.11", "3.12", "3.13"]
     steps:
       - uses: actions/checkout@v4
+
+      - name: Set up Python
+        uses: actions/setup-python@v5
+        with:
+          python-version: ${{ matrix.python }}
+
       - name: Install protoc
         run: |
-          if [ "$RUNNER_OS" == "Linux" ]; then
+          if [ "$RUNNER_OS" = "Linux" ]; then
             sudo apt-get update && sudo apt-get install -y protobuf-compiler
-          elif [ "$RUNNER_OS" == "macOS" ]; then
+          elif [ "$RUNNER_OS" = "macOS" ]; then
             brew install protobuf
           fi
+
+      - name: Rust Cache
+        uses: actions/cache@v4
+        with:
+          path: |
+            ~/.cargo/registry
+            ~/.cargo/git
+            target
+          key: test-${{ runner.os }}-${{ matrix.python }}-${{ 
hashFiles('**/Cargo.lock') }}
+
       - name: Unit Test
         run: cargo test --all-targets --workspace
         env:
           RUST_LOG: DEBUG
           RUST_BACKTRACE: full
-      - name: Integration Test
-        # only run IT in linux since no docker in macos by default
+
+      - name: Integration Test (Linux only)
+        if: runner.os == 'Linux'
         run: |
-          if [ "$RUNNER_OS" == "Linux" ]; then
-            RUST_TEST_THREADS=1 cargo test --features integration_tests 
--all-targets --workspace  -- --nocapture
-          fi
+          RUST_TEST_THREADS=1 cargo test --features integration_tests 
--all-targets --workspace -- --nocapture
         env:
           RUST_LOG: DEBUG
-          RUST_BACKTRACE: full
\ No newline at end of file
+          RUST_BACKTRACE: full

Reply via email to