Skip to content

Commit 1e03506

Browse files
authored
2024.9.0b0: It's beta time (#124807)
2 parents 2d5289e + 2856525 commit 1e03506

File tree

2,275 files changed

+65437
-50509
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,275 files changed

+65437
-50509
lines changed

.core_files.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ components: &components
6161
- homeassistant/components/auth/**
6262
- homeassistant/components/automation/**
6363
- homeassistant/components/backup/**
64+
- homeassistant/components/blueprint/**
6465
- homeassistant/components/bluetooth/**
6566
- homeassistant/components/cloud/**
6667
- homeassistant/components/config/**
@@ -146,6 +147,7 @@ requirements: &requirements
146147
- homeassistant/package_constraints.txt
147148
- requirements*.txt
148149
- pyproject.toml
150+
- script/licenses.py
149151

150152
any:
151153
- *base_platforms

.github/workflows/builder.yml

Lines changed: 57 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ jobs:
6969
run: find ./homeassistant/components/*/translations -name "*.json" | tar zcvf translations.tar.gz -T -
7070

7171
- name: Upload translations
72-
uses: actions/[email protected].4
72+
uses: actions/[email protected].6
7373
with:
7474
name: translations
7575
path: translations.tar.gz
@@ -197,7 +197,7 @@ jobs:
197197
password: ${{ secrets.GITHUB_TOKEN }}
198198

199199
- name: Build base image
200-
uses: home-assistant/builder@2024.03.5
200+
uses: home-assistant/builder@2024.08.2
201201
with:
202202
args: |
203203
$BUILD_ARGS \
@@ -263,7 +263,7 @@ jobs:
263263
password: ${{ secrets.GITHUB_TOKEN }}
264264

265265
- name: Build base image
266-
uses: home-assistant/builder@2024.03.5
266+
uses: home-assistant/builder@2024.08.2
267267
with:
268268
args: |
269269
$BUILD_ARGS \
@@ -323,7 +323,7 @@ jobs:
323323
uses: actions/[email protected]
324324

325325
- name: Install Cosign
326-
uses: sigstore/cosign-installer@v3.5.0
326+
uses: sigstore/cosign-installer@v3.6.0
327327
with:
328328
cosign-release: "v2.2.3"
329329

@@ -482,3 +482,56 @@ jobs:
482482
export TWINE_PASSWORD="${{ secrets.TWINE_TOKEN }}"
483483
484484
twine upload dist/* --skip-existing
485+
486+
hassfest-image:
487+
name: Build and test hassfest image
488+
runs-on: ubuntu-latest
489+
permissions:
490+
contents: read
491+
packages: write
492+
attestations: write
493+
id-token: write
494+
needs: ["init", "build_base"]
495+
if: github.repository_owner == 'home-assistant'
496+
env:
497+
HASSFEST_IMAGE_NAME: ghcr.io/home-assistant/hassfest
498+
HASSFEST_IMAGE_TAG: ghcr.io/home-assistant/hassfest:${{ needs.init.outputs.version }}
499+
steps:
500+
- name: Checkout repository
501+
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
502+
503+
- name: Login to GitHub Container Registry
504+
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 # v3.3.0
505+
with:
506+
registry: ghcr.io
507+
username: ${{ github.repository_owner }}
508+
password: ${{ secrets.GITHUB_TOKEN }}
509+
510+
- name: Build Docker image
511+
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6.7.0
512+
with:
513+
context: ./script/hassfest/docker
514+
build-args: BASE_IMAGE=ghcr.io/home-assistant/amd64-homeassistant:${{ needs.init.outputs.version }}
515+
load: true
516+
tags: ${{ env.HASSFEST_IMAGE_TAG }}
517+
518+
- name: Run hassfest against core
519+
run: docker run --rm -v ${{ github.workspace }}/homeassistant:/github/workspace/homeassistant ${{ env.HASSFEST_IMAGE_TAG }} --core-integrations-path=/github/workspace/homeassistant/components
520+
521+
- name: Push Docker image
522+
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true'
523+
id: push
524+
uses: docker/build-push-action@5cd11c3a4ced054e52742c5fd54dca954e0edd85 # v6.7.0
525+
with:
526+
context: ./script/hassfest/docker
527+
build-args: BASE_IMAGE=ghcr.io/home-assistant/amd64-homeassistant:${{ needs.init.outputs.version }}
528+
push: true
529+
tags: ${{ env.HASSFEST_IMAGE_TAG }},${{ env.HASSFEST_IMAGE_NAME }}:latest
530+
531+
- name: Generate artifact attestation
532+
if: needs.init.outputs.channel != 'dev' && needs.init.outputs.publish == 'true'
533+
uses: actions/attest-build-provenance@6149ea5740be74af77f260b9db67e633f6b0a9a1 # v1.4.2
534+
with:
535+
subject-name: ${{ env.HASSFEST_IMAGE_NAME }}
536+
subject-digest: ${{ steps.push.outputs.digest }}
537+
push-to-registry: true

.github/workflows/ci.yaml

Lines changed: 37 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,16 @@ on:
3131
description: "Only run mypy"
3232
default: false
3333
type: boolean
34+
audit-licenses-only:
35+
description: "Only run audit licenses"
36+
default: false
37+
type: boolean
3438

3539
env:
36-
CACHE_VERSION: 9
40+
CACHE_VERSION: 10
3741
UV_CACHE_VERSION: 1
3842
MYPY_CACHE_VERSION: 8
39-
HA_SHORT_VERSION: "2024.8"
43+
HA_SHORT_VERSION: "2024.9"
4044
DEFAULT_PYTHON: "3.12"
4145
ALL_PYTHON_VERSIONS: "['3.12']"
4246
# 10.3 is the oldest supported version
@@ -222,6 +226,7 @@ jobs:
222226
if: |
223227
github.event.inputs.pylint-only != 'true'
224228
&& github.event.inputs.mypy-only != 'true'
229+
&& github.event.inputs.audit-licenses-only != 'true'
225230
needs:
226231
- info
227232
steps:
@@ -343,6 +348,7 @@ jobs:
343348
pre-commit run --hook-stage manual ruff --all-files --show-diff-on-failure
344349
env:
345350
RUFF_OUTPUT_FORMAT: github
351+
346352
lint-other:
347353
name: Check other linters
348354
runs-on: ubuntu-24.04
@@ -508,8 +514,7 @@ jobs:
508514
uv pip install -U "pip>=21.3.1" setuptools wheel
509515
uv pip install -r requirements.txt
510516
python -m script.gen_requirements_all ci
511-
uv pip install -r requirements_all_pytest.txt
512-
uv pip install -r requirements_test.txt
517+
uv pip install -r requirements_all_pytest.txt -r requirements_test.txt
513518
uv pip install -e . --config-settings editable_mode=compat
514519
515520
hassfest:
@@ -518,6 +523,7 @@ jobs:
518523
if: |
519524
github.event.inputs.pylint-only != 'true'
520525
&& github.event.inputs.mypy-only != 'true'
526+
&& github.event.inputs.audit-licenses-only != 'true'
521527
needs:
522528
- info
523529
- base
@@ -556,6 +562,7 @@ jobs:
556562
if: |
557563
github.event.inputs.pylint-only != 'true'
558564
&& github.event.inputs.mypy-only != 'true'
565+
&& github.event.inputs.audit-licenses-only != 'true'
559566
needs:
560567
- info
561568
- base
@@ -589,7 +596,10 @@ jobs:
589596
- info
590597
- base
591598
if: |
592-
needs.info.outputs.requirements == 'true'
599+
(github.event.inputs.pylint-only != 'true'
600+
&& github.event.inputs.mypy-only != 'true'
601+
|| github.event.inputs.audit-licenses-only == 'true')
602+
&& needs.info.outputs.requirements == 'true'
593603
steps:
594604
- name: Check out code from GitHub
595605
uses: actions/[email protected]
@@ -613,7 +623,7 @@ jobs:
613623
. venv/bin/activate
614624
pip-licenses --format=json --output-file=licenses.json
615625
- name: Upload licenses
616-
uses: actions/[email protected].4
626+
uses: actions/[email protected].6
617627
with:
618628
name: licenses
619629
path: licenses.json
@@ -628,6 +638,7 @@ jobs:
628638
timeout-minutes: 20
629639
if: |
630640
github.event.inputs.mypy-only != 'true'
641+
&& github.event.inputs.audit-licenses-only != 'true'
631642
|| github.event.inputs.pylint-only == 'true'
632643
needs:
633644
- info
@@ -672,7 +683,9 @@ jobs:
672683
runs-on: ubuntu-24.04
673684
timeout-minutes: 20
674685
if: |
675-
(github.event.inputs.mypy-only != 'true' || github.event.inputs.pylint-only == 'true')
686+
(github.event.inputs.mypy-only != 'true'
687+
&& github.event.inputs.audit-licenses-only != 'true'
688+
|| github.event.inputs.pylint-only == 'true')
676689
&& (needs.info.outputs.tests_glob || needs.info.outputs.test_full_suite == 'true')
677690
needs:
678691
- info
@@ -703,20 +716,21 @@ jobs:
703716
run: |
704717
. venv/bin/activate
705718
python --version
706-
pylint --ignore-missing-annotations=y tests
719+
pylint tests
707720
- name: Run pylint (partially)
708721
if: needs.info.outputs.test_full_suite == 'false'
709722
shell: bash
710723
run: |
711724
. venv/bin/activate
712725
python --version
713-
pylint --ignore-missing-annotations=y tests/components/${{ needs.info.outputs.tests_glob }}
726+
pylint tests/components/${{ needs.info.outputs.tests_glob }}
714727
715728
mypy:
716729
name: Check mypy
717730
runs-on: ubuntu-24.04
718731
if: |
719732
github.event.inputs.pylint-only != 'true'
733+
&& github.event.inputs.audit-licenses-only != 'true'
720734
|| github.event.inputs.mypy-only == 'true'
721735
needs:
722736
- info
@@ -781,6 +795,7 @@ jobs:
781795
&& github.event.inputs.lint-only != 'true'
782796
&& github.event.inputs.pylint-only != 'true'
783797
&& github.event.inputs.mypy-only != 'true'
798+
&& github.event.inputs.audit-licenses-only != 'true'
784799
&& needs.info.outputs.test_full_suite == 'true'
785800
needs:
786801
- info
@@ -818,7 +833,7 @@ jobs:
818833
. venv/bin/activate
819834
python -m script.split_tests ${{ needs.info.outputs.test_group_count }} tests
820835
- name: Upload pytest_buckets
821-
uses: actions/[email protected].4
836+
uses: actions/[email protected].6
822837
with:
823838
name: pytest_buckets
824839
path: pytest_buckets.txt
@@ -831,6 +846,7 @@ jobs:
831846
&& github.event.inputs.lint-only != 'true'
832847
&& github.event.inputs.pylint-only != 'true'
833848
&& github.event.inputs.mypy-only != 'true'
849+
&& github.event.inputs.audit-licenses-only != 'true'
834850
&& needs.info.outputs.test_full_suite == 'true'
835851
needs:
836852
- info
@@ -918,14 +934,14 @@ jobs:
918934
2>&1 | tee pytest-${{ matrix.python-version }}-${{ matrix.group }}.txt
919935
- name: Upload pytest output
920936
if: success() || failure() && steps.pytest-full.conclusion == 'failure'
921-
uses: actions/[email protected].4
937+
uses: actions/[email protected].6
922938
with:
923939
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ matrix.group }}
924940
path: pytest-*.txt
925941
overwrite: true
926942
- name: Upload coverage artifact
927943
if: needs.info.outputs.skip_coverage != 'true'
928-
uses: actions/[email protected].4
944+
uses: actions/[email protected].6
929945
with:
930946
name: coverage-${{ matrix.python-version }}-${{ matrix.group }}
931947
path: coverage.xml
@@ -951,6 +967,7 @@ jobs:
951967
&& github.event.inputs.lint-only != 'true'
952968
&& github.event.inputs.pylint-only != 'true'
953969
&& github.event.inputs.mypy-only != 'true'
970+
&& github.event.inputs.audit-licenses-only != 'true'
954971
&& needs.info.outputs.mariadb_groups != '[]'
955972
needs:
956973
- info
@@ -1043,15 +1060,15 @@ jobs:
10431060
2>&1 | tee pytest-${{ matrix.python-version }}-${mariadb}.txt
10441061
- name: Upload pytest output
10451062
if: success() || failure() && steps.pytest-partial.conclusion == 'failure'
1046-
uses: actions/[email protected].4
1063+
uses: actions/[email protected].6
10471064
with:
10481065
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{
10491066
steps.pytest-partial.outputs.mariadb }}
10501067
path: pytest-*.txt
10511068
overwrite: true
10521069
- name: Upload coverage artifact
10531070
if: needs.info.outputs.skip_coverage != 'true'
1054-
uses: actions/[email protected].4
1071+
uses: actions/[email protected].6
10551072
with:
10561073
name: coverage-${{ matrix.python-version }}-${{
10571074
steps.pytest-partial.outputs.mariadb }}
@@ -1076,6 +1093,7 @@ jobs:
10761093
&& github.event.inputs.lint-only != 'true'
10771094
&& github.event.inputs.pylint-only != 'true'
10781095
&& github.event.inputs.mypy-only != 'true'
1096+
&& github.event.inputs.audit-licenses-only != 'true'
10791097
&& needs.info.outputs.postgresql_groups != '[]'
10801098
needs:
10811099
- info
@@ -1169,15 +1187,15 @@ jobs:
11691187
2>&1 | tee pytest-${{ matrix.python-version }}-${postgresql}.txt
11701188
- name: Upload pytest output
11711189
if: success() || failure() && steps.pytest-partial.conclusion == 'failure'
1172-
uses: actions/[email protected].4
1190+
uses: actions/[email protected].6
11731191
with:
11741192
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{
11751193
steps.pytest-partial.outputs.postgresql }}
11761194
path: pytest-*.txt
11771195
overwrite: true
11781196
- name: Upload coverage artifact
11791197
if: needs.info.outputs.skip_coverage != 'true'
1180-
uses: actions/[email protected].4
1198+
uses: actions/[email protected].6
11811199
with:
11821200
name: coverage-${{ matrix.python-version }}-${{
11831201
steps.pytest-partial.outputs.postgresql }}
@@ -1220,6 +1238,7 @@ jobs:
12201238
&& github.event.inputs.lint-only != 'true'
12211239
&& github.event.inputs.pylint-only != 'true'
12221240
&& github.event.inputs.mypy-only != 'true'
1241+
&& github.event.inputs.audit-licenses-only != 'true'
12231242
&& needs.info.outputs.tests_glob
12241243
&& needs.info.outputs.test_full_suite == 'false'
12251244
needs:
@@ -1310,14 +1329,14 @@ jobs:
13101329
2>&1 | tee pytest-${{ matrix.python-version }}-${{ matrix.group }}.txt
13111330
- name: Upload pytest output
13121331
if: success() || failure() && steps.pytest-partial.conclusion == 'failure'
1313-
uses: actions/[email protected].4
1332+
uses: actions/[email protected].6
13141333
with:
13151334
name: pytest-${{ github.run_number }}-${{ matrix.python-version }}-${{ matrix.group }}
13161335
path: pytest-*.txt
13171336
overwrite: true
13181337
- name: Upload coverage artifact
13191338
if: needs.info.outputs.skip_coverage != 'true'
1320-
uses: actions/[email protected].4
1339+
uses: actions/[email protected].6
13211340
with:
13221341
name: coverage-${{ matrix.python-version }}-${{ matrix.group }}
13231342
path: coverage.xml

.github/workflows/codeql.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@ jobs:
2424
uses: actions/[email protected]
2525

2626
- name: Initialize CodeQL
27-
uses: github/codeql-action/init@v3.25.15
27+
uses: github/codeql-action/init@v3.26.5
2828
with:
2929
languages: python
3030

3131
- name: Perform CodeQL Analysis
32-
uses: github/codeql-action/analyze@v3.25.15
32+
uses: github/codeql-action/analyze@v3.26.5
3333
with:
3434
category: "/language:python"

0 commit comments

Comments
 (0)