feat: added caching to the gitea workflow
Some checks failed
Integration Testing / Integration Tests (2025.9.4, 3.13) (push) Failing after 30s

Signed-off-by: Rafal Zielinski <sq4ind@gmail.com>
This commit is contained in:
2025-10-02 12:53:33 +01:00
parent bd32d3d00d
commit 1ca157def4

View File

@@ -13,7 +13,7 @@ jobs:
strategy: strategy:
matrix: matrix:
python-version: ["3.13"] python-version: ["3.13"]
home-assistant-version: ["2024.12.0", "2025.9.4"] home-assistant-version: ["2025.9.4"]
steps: steps:
- name: Checkout Code - name: Checkout Code
@@ -23,6 +23,50 @@ jobs:
uses: actions/setup-python@v5 uses: actions/setup-python@v5
with: with:
python-version: ${{ matrix.python-version }} python-version: ${{ matrix.python-version }}
cache: 'pip' # Built-in pip caching
- name: Cache pip dependencies
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-${{ hashFiles('**/requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-
${{ runner.os }}-pip-${{ matrix.python-version }}-
${{ runner.os }}-pip-
- name: Cache pytest cache
uses: actions/cache@v4
with:
path: .pytest_cache
key: ${{ runner.os }}-pytest-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-pytest-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-
${{ runner.os }}-pytest-${{ matrix.python-version }}-
${{ runner.os }}-pytest-
- name: Cache Home Assistant installation
uses: actions/cache@v4
with:
path: |
/opt/hostedtoolcache/Python/${{ matrix.python-version }}*/x64/lib/python*/site-packages/homeassistant*
~/.local/lib/python*/site-packages/homeassistant*
key: ${{ runner.os }}-ha-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}
restore-keys: |
${{ runner.os }}-ha-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}
- name: Cache coverage data
uses: actions/cache@v4
with:
path: |
.coverage
.coverage.*
htmlcov/
key: ${{ runner.os }}-coverage-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-coverage-${{ matrix.python-version }}-${{ matrix.home-assistant-version }}-
${{ runner.os }}-coverage-${{ matrix.python-version }}-
${{ runner.os }}-coverage-
- name: Install Dependencies - name: Install Dependencies
run: | run: |