From bedefed784115eb233a22c0e192b957de92b2a85 Mon Sep 17 00:00:00 2001 From: Cheng Date: Sat, 13 Dec 2025 13:00:51 +0900 Subject: [PATCH] Fix ccache getting disabled (#2905) --- .github/actions/setup-linux/action.yml | 20 +++++++++++++------- .github/workflows/release.yml | 2 ++ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.github/actions/setup-linux/action.yml b/.github/actions/setup-linux/action.yml index 10b993fd0..4b22b65d7 100644 --- a/.github/actions/setup-linux/action.yml +++ b/.github/actions/setup-linux/action.yml @@ -10,23 +10,29 @@ inputs: description: 'Version of python to set up' required: false default: '3.10' + use-ccache: + description: 'Whether to enable ccache' + required: false + default: 'true' runs: using: "composite" steps: - - name: Use ccache - if: ${{ runner.arch == 'x86_64' }} - uses: hendrikmuhs/ccache-action@v1.2 - with: - key: ccache-${{ runner.os }}-${{ runner.arch }}-${{ inputs.toolkit }}-py${{ inputs.python-version }} - max-size: 1GB - - name: Install common dependencies shell: bash run: | sudo apt-get update sudo apt-get install -y libblas-dev liblapack-dev liblapacke-dev zip + - name: Use ccache + if: ${{ inputs.use-ccache == 'true' }} + uses: hendrikmuhs/ccache-action@v1.2 + with: + key: ccache-${{ runner.os }}-${{ runner.arch }}-${{ inputs.toolkit }} + max-size: 1GB + # ccache-action bug: running "apt-get update" fails on large arm runner. + update-package-index: false + - uses: actions/setup-python@v6 with: python-version: ${{ inputs.python-version }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f974b147d..02ebc7e6a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -57,6 +57,7 @@ jobs: - uses: ./.github/actions/setup-linux with: python-version: ${{ matrix.python_version }} + use-ccache: false - uses: ./.github/actions/build-linux-release with: build-backend: ${{ matrix.python-version == '3.10' }} @@ -141,6 +142,7 @@ jobs: - uses: ./.github/actions/setup-linux with: toolkit: ${{ matrix.toolkit }} + use-ccache: false - name: Build Python package uses: ./.github/actions/build-cuda-release with: