8000 Update aiohttp-cors to 0.8.1 (#145976) · home-assistant/core@1754261 · GitHub
[go: up one dir, main page]

Skip to content

Commit 1754261

Browse files
authored
Update aiohttp-cors to 0.8.1 (#145976)
* Update aiohttp-cors to 0.8.1 * Fix mypy
1 parent 885367e commit 1754261

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

homeassistant/components/http/cors.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,14 @@ def setup_cors(app: Application, origins: list[str]) -> None:
3939
cors = aiohttp_cors.setup(
4040
app,
4141
defaults={
42-
host: aiohttp_cors.ResourceOptions(
42+
host: aiohttp_cors.ResourceOptions( # type: ignore[no-untyped-call]
4343
allow_headers=ALLOWED_CORS_HEADERS, allow_methods="*"
4444
)
4545
for host in origins
4646
},
4747
)
4848

49-
cors_added = set()
49+
cors_added: set[str] = set()
5050

5151
def _allow_cors(
5252
route: AbstractRoute | AbstractResource,
@@ -69,13 +69,13 @@ def _allow_cors(
6969
if path_str in cors_added:
7070
return
7171

72-
cors.add(route, config)
72+
cors.add(route, config) # type: ignore[arg-type]
7373
cors_added.add(path_str)
7474

7575
app[KEY_ALLOW_ALL_CORS] = lambda route: _allow_cors(
7676
route,
7777
{
78-
"*": aiohttp_cors.ResourceOptions(
78+
"*": aiohttp_cors.ResourceOptions( # type: ignore[no-untyped-call]
7979
allow_headers=ALLOWED_CORS_HEADERS, allow_methods="*"
8080
)
8181
},

homeassistant/package_constraints.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ aiohasupervisor==0.3.1
77
aiohttp-asyncmdnsresolver==0.1.1
88
aiohttp-fast-zlib==0.2.3
99
aiohttp==3.12.6
10-
aiohttp_cors==0.7.0
10+
aiohttp_cors==0.8.1
1111
aiousbwatcher==1.1.1
1212
aiozoneinfo==0.2.3
1313
annotatedyaml==0.4.5

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ dependencies = [
2929
# Lib can be removed with 2025.11
3030
"aiohasupervisor==0.3.1",
3131
"aiohttp==3.12.6",
32-
"aiohttp_cors==0.7.0",
32+
"aiohttp_cors==0.8.1",
3333
"aiohttp-fast-zlib==0.2.3",
3434
"aiohttp-asyncmdnsresolver==0.1.1",
3535
"aiozoneinfo==0.2.3",

requirements.txt

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)
0