Skip to content

Commit

Permalink
Bump aiohttp to 3.9.4 (#110730)
Browse files Browse the repository at this point in the history
* Bump aiohttp to 3.9.4

This is rc0 for now but will be updated when the full release it out

* cleanup cruft

* regen

* fix tests (these changes are fine)

* chunk size is too small to read since boundry is now enforced

* chunk size is too small to read since boundry is now enforced
  • Loading branch information
bdraco authored Apr 11, 2024
1 parent db38da8 commit 137514e
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion homeassistant/package_constraints.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ aiodiscover==2.0.0
aiodns==3.2.0
aiohttp-fast-url-dispatcher==0.3.0
aiohttp-zlib-ng==0.3.1
aiohttp==3.9.3
aiohttp==3.9.4
aiohttp_cors==0.7.0
astral==2.2
async-interrupt==1.1.1
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ classifiers = [
requires-python = ">=3.12.0"
dependencies = [
"aiodns==3.2.0",
"aiohttp==3.9.3",
"aiohttp==3.9.4",
"aiohttp_cors==0.7.0",
"aiohttp-fast-url-dispatcher==0.3.0",
"aiohttp-zlib-ng==0.3.1",
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

# Home Assistant Core
aiodns==3.2.0
aiohttp==3.9.3
aiohttp==3.9.4
aiohttp_cors==0.7.0
aiohttp-fast-url-dispatcher==0.3.0
aiohttp-zlib-ng==0.3.1
Expand Down
8 changes: 4 additions & 4 deletions tests/components/file_upload/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,9 @@ async def test_upload_large_file(
file_upload.TEMP_DIR_NAME + f"-{getrandbits(10):03x}",
),
patch(
# Patch one megabyte to 8 bytes to prevent having to use big files in tests
# Patch one megabyte to 50 bytes to prevent having to use big files in tests
"homeassistant.components.file_upload.ONE_MEGABYTE",
8,
50,
),
):
res = await client.post("/api/file_upload", data={"file": large_file_io})
Expand Down Expand Up @@ -152,9 +152,9 @@ def write(self, data: bytes) -> None:
file_upload.TEMP_DIR_NAME + f"-{getrandbits(10):03x}",
),
patch(
# Patch one megabyte to 8 bytes to prevent having to use big files in tests
# Patch one megabyte to 50 bytes to prevent having to use big files in tests
"homeassistant.components.file_upload.ONE_MEGABYTE",
8,
50,
),
patch(
"homeassistant.components.file_upload.Path.open", return_value=_mock_open()
Expand Down
2 changes: 1 addition & 1 deletion tests/components/websocket_api/test_auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ async def test_auth_close_after_revoke(
hass.auth.async_remove_refresh_token(refresh_token)

msg = await websocket_client.receive()
assert msg.type == aiohttp.WSMsgType.CLOSED
assert msg.type is aiohttp.WSMsgType.CLOSE
assert websocket_client.closed


Expand Down
6 changes: 3 additions & 3 deletions tests/components/websocket_api/test_http.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ async def test_pending_msg_overflow(
for idx in range(10):
await websocket_client.send_json({"id": idx + 1, "type": "ping"})
msg = await websocket_client.receive()
assert msg.type == WSMsgType.CLOSED
assert msg.type is WSMsgType.CLOSE


async def test_cleanup_on_cancellation(
Expand Down Expand Up @@ -249,7 +249,7 @@ def instantiate_handler(*args):
)

msg = await websocket_client.receive()
assert msg.type == WSMsgType.CLOSED
assert msg.type is WSMsgType.CLOSE
assert "Client unable to keep up with pending messages" in caplog.text
assert "Stayed over 5 for 5 seconds" in caplog.text
assert "overload" in caplog.text
Expand Down Expand Up @@ -297,7 +297,7 @@ def instantiate_handler(*args):
msg = await websocket_client.receive()
assert msg.type == WSMsgType.TEXT
msg = await websocket_client.receive()
assert msg.type == WSMsgType.CLOSED
assert msg.type is WSMsgType.CLOSE
assert "Client unable to keep up with pending messages" not in caplog.text


Expand Down
2 changes: 1 addition & 1 deletion tests/components/websocket_api/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ async def test_quiting_hass(hass: HomeAssistant, websocket_client) -> None:

msg = await websocket_client.receive()

assert msg.type == WSMsgType.CLOSED
assert msg.type is WSMsgType.CLOSE


async def test_unknown_command(websocket_client) -> None:
Expand Down

0 comments on commit 137514e

Please sign in to comment.