-
-
Notifications
You must be signed in to change notification settings - Fork 31.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,864 changed files
with
76,236 additions
and
20,026 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -32,7 +32,7 @@ jobs: | |
fetch-depth: 0 | ||
|
||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
||
|
@@ -69,7 +69,7 @@ jobs: | |
run: find ./homeassistant/components/*/translations -name "*.json" | tar zcvf translations.tar.gz -T - | ||
|
||
- name: Upload translations | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: translations | ||
path: translations.tar.gz | ||
|
@@ -116,7 +116,7 @@ jobs: | |
|
||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
if: needs.init.outputs.channel == 'dev' | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
||
|
@@ -453,7 +453,7 @@ jobs: | |
uses: actions/[email protected] | ||
|
||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
||
|
@@ -482,3 +482,56 @@ jobs: | |
export TWINE_PASSWORD="${{ secrets.TWINE_TOKEN }}" | ||
twine upload dist/* --skip-existing | ||
hassfest-image: | ||
name: Build and test hassfest image | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
packages: write | ||
attestations: write | ||
id-token: write | ||
needs: ["init"] | ||
if: github.repository_owner == 'home-assistant' | ||
env: | ||
HASSFEST_IMAGE_NAME: ghcr.io/home-assistant/hassfest | ||
HASSFEST_IMAGE_TAG: ghcr.io/home-assistant/hassfest:${{ needs.init.outputs.version }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | ||
|
||
- name: Login to GitHub Container Registry | ||
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.repository_owner }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build Docker image | ||
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6.7.0 | ||
with: | ||
context: . # So action will not pull the repository again | ||
file: ./script/hassfest/docker/Dockerfile | ||
load: true | ||
tags: ${{ env.HASSFEST_IMAGE_TAG }} | ||
|
||
- name: Run hassfest against core | ||
run: docker run --rm -v ${{ github.workspace }}/homeassistant:/github/workspace/homeassistant ${{ env.HASSFEST_IMAGE_TAG }} --core-integrations-path=/github/workspace/homeassistant/components | ||
|
||
- name: Push Docker image | ||
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true' | ||
id: push | ||
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6.7.0 | ||
with: | ||
context: . # So action will not pull the repository again | ||
file: ./script/hassfest/docker/Dockerfile | ||
push: true | ||
tags: ${{ env.HASSFEST_IMAGE_TAG }},${{ env.HASSFEST_IMAGE_NAME }}:latest | ||
|
||
- name: Generate artifact attestation | ||
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true' | ||
uses: actions/attest-build-provenance@6149ea5740be74af77f260b9db67e633f6b0a9a1 # v1.4.2 | ||
with: | ||
subject-name: ${{ env.HASSFEST_IMAGE_NAME }} | ||
subject-digest: ${{ steps.push.outputs.digest }} | ||
push-to-registry: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,7 +40,7 @@ env: | |
CACHE_VERSION: 10 | ||
UV_CACHE_VERSION: 1 | ||
MYPY_CACHE_VERSION: 8 | ||
HA_SHORT_VERSION: "2024.9" | ||
HA_SHORT_VERSION: "2024.10" | ||
DEFAULT_PYTHON: "3.12" | ||
ALL_PYTHON_VERSIONS: "['3.12']" | ||
# 10.3 is the oldest supported version | ||
|
@@ -234,7 +234,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -279,7 +279,7 @@ jobs: | |
- name: Check out code from GitHub | ||
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
id: python | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
@@ -319,7 +319,7 @@ jobs: | |
- name: Check out code from GitHub | ||
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
id: python | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
@@ -359,7 +359,7 @@ jobs: | |
- name: Check out code from GitHub | ||
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
id: python | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
|
@@ -429,17 +429,28 @@ jobs: | |
. venv/bin/activate | ||
pre-commit run --show-diff-on-failure --hook-stage manual codespell --all-files | ||
lint-hadolint: | ||
name: Check ${{ matrix.file }} | ||
runs-on: ubuntu-24.04 | ||
needs: | ||
- info | ||
- pre-commit | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
file: | ||
- Dockerfile | ||
- Dockerfile.dev | ||
steps: | ||
- name: Check out code from GitHub | ||
uses: actions/[email protected] | ||
- name: Register hadolint problem matcher | ||
run: | | ||
echo "::add-matcher::.github/workflows/matchers/hadolint.json" | ||
- name: Check Dockerfile | ||
uses: docker://hadolint/hadolint:v1.18.2 | ||
with: | ||
args: hadolint Dockerfile | ||
- name: Check Dockerfile.dev | ||
uses: docker://hadolint/hadolint:v1.18.2 | ||
- name: Check ${{ matrix.file }} | ||
uses: docker://hadolint/hadolint:v2.12.0 | ||
with: | ||
args: hadolint Dockerfile.dev | ||
args: hadolint ${{ matrix.file }} | ||
|
||
base: | ||
name: Prepare dependencies | ||
|
@@ -454,7 +465,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ matrix.python-version }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
check-latest: true | ||
|
@@ -538,7 +549,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -571,7 +582,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -605,7 +616,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -623,7 +634,7 @@ jobs: | |
. venv/bin/activate | ||
pip-licenses --format=json --output-file=licenses.json | ||
- name: Upload licenses | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: licenses | ||
path: licenses.json | ||
|
@@ -648,7 +659,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -695,7 +706,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -740,7 +751,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -815,7 +826,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ env.DEFAULT_PYTHON }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ env.DEFAULT_PYTHON }} | ||
check-latest: true | ||
|
@@ -833,7 +844,7 @@ jobs: | |
. venv/bin/activate | ||
python -m script.split_tests ${{ needs.info.outputs.test_group_count }} tests | ||
- name: Upload pytest_buckets | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: pytest_buckets | ||
path: pytest_buckets.txt | ||
|
@@ -879,7 +890,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ matrix.python-version }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
check-latest: true | ||
|
@@ -934,14 +945,14 @@ jobs: | |
2>&1 | tee pytest-${{ matrix.python-version }}-${{ matrix.group }}.txt | ||
- name: Upload pytest output | ||
if: success() || failure() && steps.pytest-full.conclusion == 'failure' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ matrix.group }} | ||
path: pytest-*.txt | ||
overwrite: true | ||
- name: Upload coverage artifact | ||
if: needs.info.outputs.skip_coverage != 'true' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: coverage-${{ matrix.python-version }}-${{ matrix.group }} | ||
path: coverage.xml | ||
|
@@ -999,7 +1010,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ matrix.python-version }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
check-latest: true | ||
|
@@ -1060,15 +1071,15 @@ jobs: | |
2>&1 | tee pytest-${{ matrix.python-version }}-${mariadb}.txt | ||
- name: Upload pytest output | ||
if: success() || failure() && steps.pytest-partial.conclusion == 'failure' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ | ||
steps.pytest-partial.outputs.mariadb }} | ||
path: pytest-*.txt | ||
overwrite: true | ||
- name: Upload coverage artifact | ||
if: needs.info.outputs.skip_coverage != 'true' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: coverage-${{ matrix.python-version }}-${{ | ||
steps.pytest-partial.outputs.mariadb }} | ||
|
@@ -1125,7 +1136,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ matrix.python-version }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
check-latest: true | ||
|
@@ -1187,15 +1198,15 @@ jobs: | |
2>&1 | tee pytest-${{ matrix.python-version }}-${postgresql}.txt | ||
- name: Upload pytest output | ||
if: success() || failure() && steps.pytest-partial.conclusion == 'failure' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ | ||
steps.pytest-partial.outputs.postgresql }} | ||
path: pytest-*.txt | ||
overwrite: true | ||
- name: Upload coverage artifact | ||
if: needs.info.outputs.skip_coverage != 'true' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: coverage-${{ matrix.python-version }}-${{ | ||
steps.pytest-partial.outputs.postgresql }} | ||
|
@@ -1271,7 +1282,7 @@ jobs: | |
uses: actions/[email protected] | ||
- name: Set up Python ${{ matrix.python-version }} | ||
id: python | ||
uses: actions/setup-python@v5.1.1 | ||
uses: actions/setup-python@v5.2.0 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
check-latest: true | ||
|
@@ -1329,14 +1340,14 @@ jobs: | |
2>&1 | tee pytest-${{ matrix.python-version }}-${{ matrix.group }}.txt | ||
- name: Upload pytest output | ||
if: success() || failure() && steps.pytest-partial.conclusion == 'failure' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ matrix.group }} | ||
path: pytest-*.txt | ||
overwrite: true | ||
- name: Upload coverage artifact | ||
if: needs.info.outputs.skip_coverage != 'true' | ||
uses: actions/upload-artifact@v4.3.6 | ||
uses: actions/upload-artifact@v4.4.0 | ||
with: | ||
name: coverage-${{ matrix.python-version }}-${{ matrix.group }} | ||
path: coverage.xml | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,11 +24,11 @@ jobs: | |
uses: actions/[email protected] | ||
|
||
- name: Initialize CodeQL | ||
uses: github/codeql-action/[email protected].4 | ||
uses: github/codeql-action/[email protected].6 | ||
with: | ||
languages: python | ||
|
||
- name: Perform CodeQL Analysis | ||
uses: github/codeql-action/[email protected].4 | ||
uses: github/codeql-action/[email protected].6 | ||
with: | ||
category: "/language:python" |
Oops, something went wrong.