Skip to content

Commit 9f8f259

Browse files
committed
Merge tag 'refs/tags/2025.09.0'
2 parents 4ccf5a9 + e6785d6 commit 9f8f259

Some content is hidden

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

45 files changed

+1009
-207
lines changed

.github/workflows/builder.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ jobs:
125125

126126
- name: Set up Python ${{ env.DEFAULT_PYTHON }}
127127
if: needs.init.outputs.publish == 'true'
128-
uses: actions/setup-python@v5.6.0
128+
uses: actions/setup-python@v6.0.0
129129
with:
130130
python-version: ${{ env.DEFAULT_PYTHON }}
131131

.github/workflows/ci.yaml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
uses: actions/[email protected]
3030
- name: Set up Python
3131
id: python
32-
uses: actions/setup-python@v5.6.0
32+
uses: actions/setup-python@v6.0.0
3333
with:
3434
python-version: ${{ env.DEFAULT_PYTHON }}
3535
- name: Restore Python virtual environment
@@ -70,7 +70,7 @@ jobs:
7070
- name: Check out code from GitHub
7171
uses: actions/[email protected]
7272
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
73-
uses: actions/setup-python@v5.6.0
73+
uses: actions/setup-python@v6.0.0
7474
id: python
7575
with:
7676
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -113,7 +113,7 @@ jobs:
113113
- name: Check out code from GitHub
114114
uses: actions/[email protected]
115115
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
116-
uses: actions/setup-python@v5.6.0
116+
uses: actions/setup-python@v6.0.0
117117
id: python
118118
with:
119119
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -171,7 +171,7 @@ jobs:
171171
- name: Check out code from GitHub
172172
uses: actions/[email protected]
173173
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
174-
uses: actions/setup-python@v5.6.0
174+
uses: actions/setup-python@v6.0.0
175175
id: python
176176
with:
177177
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -215,7 +215,7 @@ jobs:
215215
- name: Check out code from GitHub
216216
uses: actions/[email protected]
217217
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
218-
uses: actions/setup-python@v5.6.0
218+
uses: actions/setup-python@v6.0.0
219219
id: python
220220
with:
221221
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -259,7 +259,7 @@ jobs:
259259
- name: Check out code from GitHub
260260
uses: actions/[email protected]
261261
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
262-
uses: actions/setup-python@v5.6.0
262+
uses: actions/setup-python@v6.0.0
263263
id: python
264264
with:
265265
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -295,7 +295,7 @@ jobs:
295295
- name: Check out code from GitHub
296296
uses: actions/[email protected]
297297
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
298-
uses: actions/setup-python@v5.6.0
298+
uses: actions/setup-python@v6.0.0
299299
id: python
300300
with:
301301
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -341,7 +341,7 @@ jobs:
341341
- name: Check out code from GitHub
342342
uses: actions/[email protected]
343343
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
344-
uses: actions/setup-python@v5.6.0
344+
uses: actions/setup-python@v6.0.0
345345
id: python
346346
with:
347347
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -400,7 +400,7 @@ jobs:
400400
- name: Check out code from GitHub
401401
uses: actions/[email protected]
402402
- name: Set up Python ${{ needs.prepare.outputs.python-version }}
403-
uses: actions/setup-python@v5.6.0
403+
uses: actions/setup-python@v6.0.0
404404
id: python
405405
with:
406406
python-version: ${{ needs.prepare.outputs.python-version }}
@@ -428,4 +428,4 @@ jobs:
428428
coverage report
429429
coverage xml
430430
- name: Upload coverage to Codecov
431-
uses: codecov/[email protected].0
431+
uses: codecov/[email protected].1

.github/workflows/restrict-task-creation.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
if: github.event.issue.type.name == 'Task'
1313
steps:
1414
- name: Check if user is authorized
15-
uses: actions/github-script@v7
15+
uses: actions/github-script@v8
1616
with:
1717
script: |
1818
const issueAuthor = context.payload.issue.user.login;

.github/workflows/stale.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ jobs:
99
stale:
1010
runs-on: ubuntu-latest
1111
steps:
12-
- uses: actions/stale@v9.1.0
12+
- uses: actions/stale@v10.0.0
1313
with:
1414
repo-token: ${{ secrets.GITHUB_TOKEN }}
1515
days-before-stale: 30

requirements.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ brotli==1.1.0
88
ciso8601==2.3.3
99
colorlog==6.9.0
1010
cpe==1.3.1
11-
cryptography==45.0.6
11+
cryptography==45.0.7
1212
debugpy==1.8.16
1313
deepmerge==2.0
1414
dirhash==0.5.0
@@ -17,13 +17,13 @@ faust-cchardet==2.1.19
1717
gitpython==3.1.45
1818
jinja2==3.1.6
1919
log-rate-limit==1.4.2
20-
orjson==3.11.2
20+
orjson==3.11.3
2121
pulsectl==24.12.0
2222
pyudev==0.24.3
2323
PyYAML==6.0.2
2424
requests==2.32.5
2525
securetar==2025.2.1
26-
sentry-sdk==2.35.0
26+
sentry-sdk==2.36.0
2727
setuptools==80.9.0
2828
voluptuous==0.15.2
2929
dbus-fast==2.44.3

requirements_tests.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
astroid==3.3.11
2-
coverage==7.10.5
2+
coverage==7.10.6
33
mypy==1.17.1
44
pre-commit==4.3.0
55
pylint==3.3.8
66
pytest-aiohttp==1.1.0
77
pytest-asyncio==0.25.2
88
pytest-cov==6.2.1
99
pytest-timeout==2.4.0
10-
pytest==8.4.1
11-
ruff==0.12.10
10+
pytest==8.4.2
11+
ruff==0.12.12
1212
time-machine==2.19.0
1313
types-docker==7.1.0.20250822
1414
types-pyyaml==6.0.12.20250822

supervisor/addons/addon.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,9 @@
6767
from ..docker.stats import DockerStats
6868
from ..exceptions import (
6969
AddonConfigurationError,
70+
AddonNotSupportedError,
7071
AddonsError,
7172
AddonsJobError,
72-
AddonsNotSupportedError,
7373
ConfigurationFileError,
7474
DockerError,
7575
HomeAssistantAPIError,
@@ -1172,7 +1172,7 @@ async def stats(self) -> DockerStats:
11721172
async def write_stdin(self, data) -> None:
11731173
"""Write data to add-on stdin."""
11741174
if not self.with_stdin:
1175-
raise AddonsNotSupportedError(
1175+
raise AddonNotSupportedError(
11761176
f"Add-on {self.slug} does not support writing to stdin!", _LOGGER.error
11771177
)
11781178

@@ -1419,7 +1419,7 @@ def _extract_tarfile() -> tuple[TemporaryDirectory, dict[str, Any]]:
14191419

14201420
# If available
14211421
if not self._available(data[ATTR_SYSTEM]):
1422-
raise AddonsNotSupportedError(
1422+
raise AddonNotSupportedError(
14231423
f"Add-on {self.slug} is not available for this platform",
14241424
_LOGGER.error,
14251425
)

supervisor/addons/manager.py

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
from ..const import AddonBoot, AddonStartup, AddonState
1515
from ..coresys import CoreSys, CoreSysAttributes
1616
from ..exceptions import (
17+
AddonNotSupportedError,
1718
AddonsError,
1819
AddonsJobError,
19-
AddonsNotSupportedError,
2020
CoreDNSError,
2121
DockerError,
2222
HassioError,
@@ -184,7 +184,9 @@ async def shutdown(self, stage: AddonStartup) -> None:
184184
on_condition=AddonsJobError,
185185
concurrency=JobConcurrency.QUEUE,
186186
)
187-
async def install(self, slug: str) -> None:
187+
async def install(
188+
self, slug: str, *, validation_complete: asyncio.Event | None = None
189+
) -> None:
188190
"""Install an add-on."""
189191
self.sys_jobs.current.reference = slug
190192

@@ -197,6 +199,10 @@ async def install(self, slug: str) -> None:
197199

198200
store.validate_availability()
199201

202+
# If being run in the background, notify caller that validation has completed
203+
if validation_complete:
204+
validation_complete.set()
205+
200206
await Addon(self.coresys, slug).install()
201207

202208
_LOGGER.info("Add-on '%s' successfully installed", slug)
@@ -226,7 +232,11 @@ async def uninstall(self, slug: str, *, remove_config: bool = False) -> None:
226232
on_condition=AddonsJobError,
227233
)
228234
async def update(
229-
self, slug: str, backup: bool | None = False
235+
self,
236+
slug: str,
237+
backup: bool | None = False,
238+
*,
239+
validation_complete: asyncio.Event | None = None,
230240
) -> asyncio.Task | None:
231241
"""Update add-on.
232242
@@ -251,6 +261,10 @@ async def update(
251261
# Check if available, Maybe something have changed
252262
store.validate_availability()
253263

264+
# If being run in the background, notify caller that validation has completed
265+
if validation_complete:
266+
validation_complete.set()
267+
254268
if backup:
255269
await self.sys_backups.do_backup_partial(
256270
name=f"addon_{addon.slug}_{addon.version}",
@@ -293,7 +307,7 @@ async def rebuild(self, slug: str, *, force: bool = False) -> asyncio.Task | Non
293307
"Version changed, use Update instead Rebuild", _LOGGER.error
294308
)
295309
if not force and not addon.need_build:
296-
raise AddonsNotSupportedError(
310+
raise AddonNotSupportedError(
297311
"Can't rebuild a image based add-on", _LOGGER.error
298312
)
299313

supervisor/addons/model.py

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,12 @@
8989
)
9090
from ..coresys import CoreSys
9191
from ..docker.const import Capabilities
92-
from ..exceptions import AddonsNotSupportedError
92+
from ..exceptions import (
93+
AddonNotSupportedArchitectureError,
94+
AddonNotSupportedError,
95+
AddonNotSupportedHomeAssistantVersionError,
96+
AddonNotSupportedMachineTypeError,
97+
)
9398
from ..jobs.const import JOB_GROUP_ADDON
9499
from ..jobs.job_group import JobGroup
95100
from ..utils import version_is_new_enough
@@ -680,19 +685,17 @@ def _validate_availability(
680685
"""Validate if addon is available for current system."""
681686
# Architecture
682687
if not self.sys_arch.is_supported(config[ATTR_ARCH]):
683-
raise AddonsNotSupportedError(
684-
f"Add-on {self.slug} not supported on this platform, supported architectures: {', '.join(config[ATTR_ARCH])}",
685-
logger,
688+
raise AddonNotSupportedArchitectureError(
689+
logger, slug=self.slug, architectures=config[ATTR_ARCH]
686690
)
687691

688692
# Machine / Hardware
689693
machine = config.get(ATTR_MACHINE)
690694
if machine and (
691695
f"!{self.sys_machine}" in machine or self.sys_machine not in machine
692696
):
693-
raise AddonsNotSupportedError(
694-
f"Add-on {self.slug} not supported on this machine, supported machine types: {', '.join(machine)}",
695-
logger,
697+
raise AddonNotSupportedMachineTypeError(
698+
logger, slug=self.slug, machine_types=machine
696699
)
697700

698701
# Home Assistant
@@ -701,16 +704,15 @@ def _validate_availability(
701704
if version and not version_is_new_enough(
702705
self.sys_homeassistant.version, version
703706
):
704-
raise AddonsNotSupportedError(
705-
f"Add-on {self.slug} not supported on this system, requires Home Assistant version {version} or greater",
706-
logger,
707+
raise AddonNotSupportedHomeAssistantVersionError(
708+
logger, slug=self.slug, version=str(version)
707709
)
708710

709711
def _available(self, config) -> bool:
710712
"""Return True if this add-on is available on this platform."""
711713
try:
712714
self._validate_availability(config)
713-
except AddonsNotSupportedError:
715+
except AddonNotSupportedError:
714716
return False
715717

716718
return True

supervisor/api/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -735,6 +735,10 @@ def _register_store(self) -> None:
735735
"/store/addons/{addon}/documentation",
736736
api_store.addons_addon_documentation,
737737
),
738+
web.get(
739+
"/store/addons/{addon}/availability",
740+
api_store.addons_addon_availability,
741+
),
738742
web.post(
739743
"/store/addons/{addon}/install", api_store.addons_addon_install
740744
),

0 commit comments

Comments
 (0)