fix(test): pin aiohttp<3.14 to work around aioresponses incompatibility - #532
Merged
Merged
Conversation
CI has been red on both Python 3.11 and 3.14 jobs since the runner picked up aiohttp 3.14, which added a required ClientResponse `stream_writer` kwarg that aioresponses 0.7.9 (latest release) doesn't pass -- 11 tests fail with TypeError. Upstream fix is open but unreleased (pnuckowski/aioresponses#288). Test-only pin; doesn't affect the library's own aiohttp>=3.8.1 floor in pyproject.toml/requirements.txt. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PPpQYEKnQFCiy3GS3D2fKs
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
stream_writerkwarg toClientResponse.__init__.aioresponses0.7.9 (latest release) doesn't pass it when building mock responses, so every test that exercisesConnection.request()throughaioresponsesfails withTypeError: ClientResponse.__init__() missing 1 required keyword-only argument: 'stream_writer'(11 failures).aiohttp<3.14inrequirements-test.txtonly — this doesn't touch the library's ownaiohttp>=3.8.1floor inpyproject.toml/requirements.txt, so it has no effect on downstream consumers (e.g. Home Assistant Core, which currently pinsaiohttp==3.13.5anyway).aiohttp.BasicAuthdeprecation warning (also present in the logs) as-is for now — fixing it properly means switching toaiohttp.encode_basic_auth(), which requires bumping the floor toaiohttp>=3.14.0. That would make PyISY's requirements incompatible with HA Core's currentaiohttp==3.13.5pin, so it's out of scope here.Test plan
pytest— 448 passed locally withaiohttp==3.13.5installedpre-commit run --all-files— clean🤖 Generated with Claude Code
https://claude.ai/code/session_01PPpQYEKnQFCiy3GS3D2fKs