From 8fdd5a7ef25587edfeb4acc513b6ae09d65fd775 Mon Sep 17 00:00:00 2001 From: Aaron Steele Date: Wed, 17 Jul 2024 13:24:46 -0700 Subject: [PATCH] debug ci --- .github/workflows/ci.yml | 36 ++++++++++++++++++------------------ install.sh | 3 +-- scripts/check-auth.sh | 2 +- scripts/env-activation.sh | 10 +++++++--- 4 files changed, 27 insertions(+), 24 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6182c395..d31d8591 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,21 +33,21 @@ jobs: - name: Setup gcloud uses: google-github-actions/setup-gcloud@v2 - - name: Install system environment and project dependencies - env: - GITHUB_CI: "true" - run: ./install.sh - - - name: Setup caching for test assets - uses: actions/cache@v4 - with: - path: assets - key: ${{ runner.os }}-${{ matrix.runner }}-assets - restore-keys: ${{ runner.os }}-${{ matrix.runner }}-assets - - - name: Run tests - uses: prefix-dev/setup-pixi@v0.8.1 - with: - pixi-version: v0.25.0 - cache: true - run: pixi run all-tests-ci + # - name: Install system environment and project dependencies + # env: + # GITHUB_CI: "true" + # run: ./install.sh + + # - name: Setup caching for test assets + # uses: actions/cache@v4 + # with: + # path: assets + # key: ${{ runner.os }}-${{ matrix.runner }}-assets + # restore-keys: ${{ runner.os }}-${{ matrix.runner }}-assets + + # - name: Run tests + # uses: prefix-dev/setup-pixi@v0.8.1 + # with: + # pixi-version: v0.25.0 + # cache: true + # run: pixi run all-tests-ci diff --git a/install.sh b/install.sh index 58507e3c..80b9ae17 100755 --- a/install.sh +++ b/install.sh @@ -142,8 +142,7 @@ __wrap__() { # install environment echo "installing b3d project dependencies..." echo " pixi install..." - pixi install - + pixi install # copy in libEGL.so cp assets/system/libEGL.so .pixi/envs/default/x86_64-conda-linux-gnu/sysroot/usr/lib64/ diff --git a/scripts/check-auth.sh b/scripts/check-auth.sh index 2b0d218c..771ba6e1 100755 --- a/scripts/check-auth.sh +++ b/scripts/check-auth.sh @@ -76,7 +76,7 @@ gcloud-global-install() { } gcloud-authenticated() { - if [ "$GITHUB_CI" = "true" ]; then + if [ "${GITHUB_CI:-}" = "true" ]; then return 0 elif gcloud auth application-default print-access-token >/dev/null; then return 0 diff --git a/scripts/env-activation.sh b/scripts/env-activation.sh index f3b539d5..639f67af 100755 --- a/scripts/env-activation.sh +++ b/scripts/env-activation.sh @@ -8,8 +8,12 @@ export TORCH_CUDA_ARCH_LIST="$capability" export XLA_FLAGS=--xla_gpu_enable_command_buffer= export XLA_PYTHON_CLIENT_PREALLOCATE=false export XLA_PYTHON_CLIENT_ALLOCATOR=platform -export CPLUS_INCLUDE_PATH="$CONDA_PREFIX/targets/x86_64-linux/include" -if ! [ -e "$CONDA_PREFIX/x86_64-conda-linux-gnu/sysroot/usr/lib64/libEGL.so" ]; then - cp assets/system/libEGL.so "$CONDA_PREFIX/x86_64-conda-linux-gnu/sysroot/usr/lib64/" +if ! [ "${CONDA_PREFIX:-}" = "" ]; then + export CPLUS_INCLUDE_PATH="$CONDA_PREFIX/targets/x86_64-linux/include" + if [ -d "$CONDA_PREFIX/x86_64-conda-linux-gnu/sysroot/usr/lib64" ]; then + if ! [ -e "$CONDA_PREFIX/x86_64-conda-linux-gnu/sysroot/usr/lib64/libEGL.so" ]; then + cp assets/system/libEGL.so "$CONDA_PREFIX/x86_64-conda-linux-gnu/sysroot/usr/lib64/" + fi + fi fi