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

lidavidm pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-adbc.git


The following commit(s) were added to refs/heads/main by this push:
     new 3168e091d ci: work around download-artifact bug (#2067)
3168e091d is described below

commit 3168e091d2b80c3af3fe697681fd3e437e52e090
Author: David Li <[email protected]>
AuthorDate: Thu Aug 8 12:09:03 2024 +0900

    ci: work around download-artifact bug (#2067)
    
    Work around actions/download-artifact#346.
    
    Fixes #2061.
---
 .github/workflows/native-unix.yml | 46 ++++++++++++++++++++++++++++++++++-----
 1 file changed, 41 insertions(+), 5 deletions(-)

diff --git a/.github/workflows/native-unix.yml 
b/.github/workflows/native-unix.yml
index 687d62e80..e062dc23a 100644
--- a/.github/workflows/native-unix.yml
+++ b/.github/workflows/native-unix.yml
@@ -130,12 +130,23 @@ jobs:
           export PATH=$RUNNER_TOOL_CACHE/go/${GO_VERSION}/${{ matrix.goarch 
}}/bin:$PATH
           ./ci/scripts/go_build.sh "$(pwd)" "$(pwd)/build" "$HOME/local"
 
+      # XXX: GitHub broke upload/download-artifact.  To avoid symlinks being
+      # converted into weird files, tar the files ourselves first.
+      # https://github.com/apache/arrow-adbc/issues/2061
+      # https://github.com/actions/download-artifact/issues/346
+
+      - name: tar artifacts
+        shell: bash -l {0}
+        run: |
+          cd
+          tar czf ~/local.tgz local
+
       - uses: actions/upload-artifact@v4
         with:
           name: driver-manager-${{ matrix.os }}
           retention-days: 3
           path: |
-            ~/local
+            ~/local.tgz
 
   # ------------------------------------------------------------
   # C/C++ (builds and tests)
@@ -355,7 +366,13 @@ jobs:
       - uses: actions/download-artifact@v4
         with:
           name: driver-manager-${{ matrix.os }}
-          path: ~/local
+          path: "~"
+
+      - name: untar artifacts
+        shell: bash -l {0}
+        run: |
+          cd
+          tar xvf ~/local.tgz
 
       - name: Build GLib Driver Manager
         shell: bash -l {0}
@@ -477,7 +494,13 @@ jobs:
       - uses: actions/download-artifact@v4
         with:
           name: driver-manager-${{ matrix.os }}
-          path: ~/local
+          path: "~"
+
+      - name: untar artifacts
+        shell: bash -l {0}
+        run: |
+          cd
+          tar xvf ~/local.tgz
 
       - name: Go Build
         shell: bash -l {0}
@@ -561,7 +584,13 @@ jobs:
       - uses: actions/download-artifact@v4
         with:
           name: driver-manager-${{ matrix.os }}
-          path: ~/local
+          path: "~"
+
+      - name: untar artifacts
+        shell: bash -l {0}
+        run: |
+          cd
+          tar xvf ~/local.tgz
 
       - name: Build
         shell: bash -l {0}
@@ -668,10 +697,17 @@ jobs:
         if: matrix.os == 'ubuntu-latest'
         run: |
           sudo sysctl vm.mmap_rnd_bits=28
+
       - uses: actions/download-artifact@v4
         with:
           name: driver-manager-${{ matrix.os }}
-          path: ~/local
+          path: "~"
+
+      - name: untar artifacts
+        shell: bash -l {0}
+        run: |
+          cd
+          tar xvf ~/local.tgz
 
       - name: Build Python
         shell: bash -l {0}

Reply via email to