Skip to content

Commit

Permalink
Fix disabling cache when in forks or dependatbot (#1996)
Browse files Browse the repository at this point in the history
* Check if sccache is setup by Prep build

* different debugging message

* bad conditional statement
  • Loading branch information
gpmayorga authored Dec 9, 2024
1 parent 25e7ea5 commit df1219b
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 3 deletions.
1 change: 0 additions & 1 deletion .github/actions/sccache-gcloud/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ runs:
# echo "SCCACHE_GCS_KEY_PATH=${{ steps.gauth.credentials_file_path }}" >> $GITHUB_ENV
- name: setup Rust sccache wrapper
if: ${{ inputs.cache == 'enabled' }}
shell: bash
run: |
echo "RUSTC_WRAPPER=sccache" >> $GITHUB_ENV
Expand Down
17 changes: 15 additions & 2 deletions .github/workflows/sanity-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,19 @@ jobs:
# Required for integration tests evm interaction
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1

- name: Debug GitHub Environment Variables
shell: bash
run: |
echo "SCCACHE_GCS_BUCKET=${SCCACHE_GCS_BUCKET}"
echo "SCCACHE_GCS_RW_MODE=${SCCACHE_GCS_RW_MODE}"
echo "RUSTC_WRAPPER=${RUSTC_WRAPPER}"
echo "CARGO_INCREMENTAL=${CARGO_INCREMENTAL}"
- name: Runing cargo ${{ matrix.target }}
run: ./ci/run-check.sh
env:
TARGET: ${{ matrix.target }}
RUSTC_WRAPPER: "sccache"

benchmark-check:
if: ${{ !github.event.pull_request.draft }}
Expand All @@ -63,10 +70,16 @@ jobs:
GWIP: ${{ secrets.GWIP_SCCACHE }}
GSA: ${{ secrets.GSA_SCCACHE }}

- name: Debug GitHub Environment Variables
shell: bash
run: |
echo "SCCACHE_GCS_BUCKET=${SCCACHE_GCS_BUCKET}"
echo "SCCACHE_GCS_RW_MODE=${SCCACHE_GCS_RW_MODE}"
echo "RUSTC_WRAPPER=${RUSTC_WRAPPER}"
echo "CARGO_INCREMENTAL=${CARGO_INCREMENTAL}"
- name: Runing cargo ${{ matrix.target }}
run: ./ci/run-check.sh
env:
TARGET: benchmark-check
RUNTIME: ${{ matrix.runtime }}
RUSTC_WRAPPER: "sccache"

0 comments on commit df1219b

Please sign in to comment.