Skip to content

Releases: aio-libs/aiohttp

3.12.0b3

22 May 23:40
v3.12.0b3
b5a061b
Compare
Choose a tag to compare
3.12.0b3 Pre-release
Pre-release

Bug fixes

  • Response is now always True, instead of using MutableMapping behaviour (False when map is empty)

    Related issues and pull requests on GitHub:
    #10119.

  • Fixed connection reuse for file-like data payloads by ensuring buffer
    truncation respects content-length boundaries and preventing premature
    connection closure race -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10325, #10915, #10941, #10943.

  • Fixed pytest plugin to not use deprecated :py:mod:asyncio policy APIs.

    Related issues and pull requests on GitHub:
    #10851.

  • Fixed :py:class:~aiohttp.resolver.AsyncResolver not using the loop argument in versions 3.x where it should still be supported -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10951.

Features

  • Added a comprehensive HTTP Digest Authentication client middleware (DigestAuthMiddleware)
    that implements RFC 7616. The middleware supports all standard hash algorithms
    (MD5, SHA, SHA-256, SHA-512) with session variants, handles both 'auth' and
    'auth-int' quality of protection options, and automatically manages the
    authentication flow by intercepting 401 responses and retrying with proper
    credentials -- by :user:feus4177, :user:TimMenninger, and :user:bdraco.

    Related issues and pull requests on GitHub:
    #2213, #10725.

  • Added client middleware support -- by :user:bdraco and :user:Dreamsorcerer.

    This change allows users to add middleware to the client session and requests, enabling features like
    authentication, logging, and request/response modification without modifying the core
    request logic. Additionally, the session attribute was added to ClientRequest,
    allowing middleware to access the session for making additional requests.

    Related issues and pull requests on GitHub:
    #9732, #10902, #10952.

  • Allow user setting zlib compression backend -- by :user:TimMenninger

    This change allows the user to call :func:aiohttp.set_zlib_backend() with the
    zlib compression module of their choice. Default behavior continues to use
    the builtin zlib library.

    Related issues and pull requests on GitHub:
    #9798.

  • Added support for overriding the base URL with an absolute one in client sessions
    -- by :user:vivodi.

    Related issues and pull requests on GitHub:
    #10074.

  • Added host parameter to aiohttp_server fixture -- by :user:christianwbrock.

    Related issues and pull requests on GitHub:
    #10120.

  • Detect blocking calls in coroutines using BlockBuster -- by :user:cbornet.

    Related issues and pull requests on GitHub:
    #10433.

  • Added socket_factory to :py:class:aiohttp.TCPConnector to allow specifying custom socket options
    -- by :user:TimMenninger.

    Related issues and pull requests on GitHub:
    #10474, #10520.

  • Started building armv7l manylinux wheels -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10797.

  • Implemented shared DNS resolver management to fix excessive resolver object creation
    when using multiple client sessions. The new _DNSResolverManager singleton ensures
    only one DNSResolver object is created for default configurations, significantly
    reducing resource usage and improving performance for applications using multiple
    client sessions simultaneously -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10847, #10923, #10946.

Packaging updates and notes for downstreams

  • Removed non SPDX-license description from setup.cfg -- by :user:devanshu-ziphq.

    Related issues and pull requests on GitHub:
    #10662.

  • Added support for building against system llhttp library -- by :user:mgorny.

    This change adds support for :envvar:AIOHTTP_USE_SYSTEM_DEPS environment variable that
    can be used to build aiohttp against the system install of the llhttp library rather
    than the vendored one.

    Related issues and pull requests on GitHub:
    #10759.

  • aiodns is now installed on Windows with speedups extra -- by :user:bdraco.

    As of aiodns 3.3.0, SelectorEventLoop is no longer required when using pycares 4.7.0 or later.

    Related issues and pull requests on GitHub:
    #10823.

  • Fixed compatibility issue with Cython 3.1.1 -- by :user:bdraco

    Related issues and pull requests on GitHub:
    #10877.

Contributor-facing changes

  • Sped up tests by disabling blockbuster fixture for test_static_file_huge and test_static_file_huge_cancel tests -- by :user:dikos1337.

    Related issues and pull requests on GitHub:
    #9705, #10761.

  • Updated tests to avoid using deprecated :py:mod:asyncio policy APIs and
    make it compatible with Python 3.14.

    Related issues and pull requests on GitHub:
    #10851.

  • Added Winloop to test suite to support in the future -- by :user:Vizonex.

    Related issues and pull requests on GitHub:
    #10922.

Miscellaneous internal changes

  • Added support for the partitioned attribute in the set_cookie method.

    Related issues and pull requests on GitHub:
    #9870.

  • Setting :attr:aiohttp.web.StreamResponse.last_modified to an unsupported type will now raise :exc:TypeError instead of silently failing -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10146.


3.12.0b2

22 May 20:49
v3.12.0b2
31d3638
Compare
Choose a tag to compare
3.12.0b2 Pre-release
Pre-release

Bug fixes

  • Response is now always True, instead of using MutableMapping behaviour (False when map is empty)

    Related issues and pull requests on GitHub:
    #10119.

  • Fixed connection reuse for file-like data payloads by ensuring buffer
    truncation respects content-length boundaries and preventing premature
    connection closure race -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10325, #10915, #10941, #10943.

  • Fixed pytest plugin to not use deprecated :py:mod:asyncio policy APIs.

    Related issues and pull requests on GitHub:
    #10851.

Features

  • Added a comprehensive HTTP Digest Authentication client middleware (DigestAuthMiddleware)
    that implements RFC 7616. The middleware supports all standard hash algorithms
    (MD5, SHA, SHA-256, SHA-512) with session variants, handles both 'auth' and
    'auth-int' quality of protection options, and automatically manages the
    authentication flow by intercepting 401 responses and retrying with proper
    credentials -- by :user:feus4177, :user:TimMenninger, and :user:bdraco.

    Related issues and pull requests on GitHub:
    #2213, #10725.

  • Added client middleware support -- by :user:bdraco and :user:Dreamsorcerer.

    This change allows users to add middleware to the client session and requests, enabling features like
    authentication, logging, and request/response modification without modifying the core
    request logic. Additionally, the session attribute was added to ClientRequest,
    allowing middleware to access the session for making additional requests.

    Related issues and pull requests on GitHub:
    #9732, #10902.

  • Allow user setting zlib compression backend -- by :user:TimMenninger

    This change allows the user to call :func:aiohttp.set_zlib_backend() with the
    zlib compression module of their choice. Default behavior continues to use
    the builtin zlib library.

    Related issues and pull requests on GitHub:
    #9798.

  • Added support for overriding the base URL with an absolute one in client sessions
    -- by :user:vivodi.

    Related issues and pull requests on GitHub:
    #10074.

  • Added host parameter to aiohttp_server fixture -- by :user:christianwbrock.

    Related issues and pull requests on GitHub:
    #10120.

  • Detect blocking calls in coroutines using BlockBuster -- by :user:cbornet.

    Related issues and pull requests on GitHub:
    #10433.

  • Added socket_factory to :py:class:aiohttp.TCPConnector to allow specifying custom socket options
    -- by :user:TimMenninger.

    Related issues and pull requests on GitHub:
    #10474, #10520.

  • Started building armv7l manylinux wheels -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10797.

  • Implemented shared DNS resolver management to fix excessive resolver object creation
    when using multiple client sessions. The new _DNSResolverManager singleton ensures
    only one DNSResolver object is created for default configurations, significantly
    reducing resource usage and improving performance for applications using multiple
    client sessions simultaneously -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10847, #10923, #10946.

Packaging updates and notes for downstreams

  • Removed non SPDX-license description from setup.cfg -- by :user:devanshu-ziphq.

    Related issues and pull requests on GitHub:
    #10662.

  • Added support for building against system llhttp library -- by :user:mgorny.

    This change adds support for :envvar:AIOHTTP_USE_SYSTEM_DEPS environment variable that
    can be used to build aiohttp against the system install of the llhttp library rather
    than the vendored one.

    Related issues and pull requests on GitHub:
    #10759.

  • aiodns is now installed on Windows with speedups extra -- by :user:bdraco.

    As of aiodns 3.3.0, SelectorEventLoop is no longer required when using pycares 4.7.0 or later.

    Related issues and pull requests on GitHub:
    #10823.

  • Fixed compatibility issue with Cython 3.1.1 -- by :user:bdraco

    Related issues and pull requests on GitHub:
    #10877.

Contributor-facing changes

  • Sped up tests by disabling blockbuster fixture for test_static_file_huge and test_static_file_huge_cancel tests -- by :user:dikos1337.

    Related issues and pull requests on GitHub:
    #9705, #10761.

  • Updated tests to avoid using deprecated :py:mod:asyncio policy APIs and
    make it compatible with Python 3.14.

    Related issues and pull requests on GitHub:
    #10851.

  • Added Winloop to test suite to support in the future -- by :user:Vizonex.

    Related issues and pull requests on GitHub:
    #10922.

Miscellaneous internal changes

  • Added support for the partitioned attribute in the set_cookie method.

    Related issues and pull requests on GitHub:
    #9870.

  • Setting :attr:aiohttp.web.StreamResponse.last_modified to an unsupported type will now raise :exc:TypeError instead of silently failing -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10146.


3.12.0b1

22 May 18:44
v3.12.0b1
69a7fd7
Compare
Choose a tag to compare
3.12.0b1 Pre-release
Pre-release

Bug fixes

  • Response is now always True, instead of using MutableMapping behaviour (False when map is empty)

    Related issues and pull requests on GitHub:
    #10119.

  • Fixed connection reuse for file-like data payloads by ensuring buffer
    truncation respects content-length boundaries and preventing premature
    connection closure race -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10325, #10915.

  • Fixed pytest plugin to not use deprecated :py:mod:asyncio policy APIs.

    Related issues and pull requests on GitHub:
    #10851.

Features

  • Added a comprehensive HTTP Digest Authentication client middleware (DigestAuthMiddleware)
    that implements RFC 7616. The middleware supports all standard hash algorithms
    (MD5, SHA, SHA-256, SHA-512) with session variants, handles both 'auth' and
    'auth-int' quality of protection options, and automatically manages the
    authentication flow by intercepting 401 responses and retrying with proper
    credentials -- by :user:feus4177, :user:TimMenninger, and :user:bdraco.

    Related issues and pull requests on GitHub:
    #2213, #10725.

  • Added client middleware support -- by :user:bdraco and :user:Dreamsorcerer.

    This change allows users to add middleware to the client session and requests, enabling features like
    authentication, logging, and request/response modification without modifying the core
    request logic. Additionally, the session attribute was added to ClientRequest,
    allowing middleware to access the session for making additional requests.

    Related issues and pull requests on GitHub:
    #9732, #10902.

  • Allow user setting zlib compression backend -- by :user:TimMenninger

    This change allows the user to call :func:aiohttp.set_zlib_backend() with the
    zlib compression module of their choice. Default behavior continues to use
    the builtin zlib library.

    Related issues and pull requests on GitHub:
    #9798.

  • Added support for overriding the base URL with an absolute one in client sessions
    -- by :user:vivodi.

    Related issues and pull requests on GitHub:
    #10074.

  • Added host parameter to aiohttp_server fixture -- by :user:christianwbrock.

    Related issues and pull requests on GitHub:
    #10120.

  • Detect blocking calls in coroutines using BlockBuster -- by :user:cbornet.

    Related issues and pull requests on GitHub:
    #10433.

  • Added socket_factory to :py:class:aiohttp.TCPConnector to allow specifying custom socket options
    -- by :user:TimMenninger.

    Related issues and pull requests on GitHub:
    #10474, #10520.

  • Started building armv7l manylinux wheels -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10797.

  • Implemented shared DNS resolver management to fix excessive resolver object creation
    when using multiple client sessions. The new _DNSResolverManager singleton ensures
    only one DNSResolver object is created for default configurations, significantly
    reducing resource usage and improving performance for applications using multiple
    client sessions simultaneously -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10847, #10923.

Packaging updates and notes for downstreams

  • Removed non SPDX-license description from setup.cfg -- by :user:devanshu-ziphq.

    Related issues and pull requests on GitHub:
    #10662.

  • Added support for building against system llhttp library -- by :user:mgorny.

    This change adds support for :envvar:AIOHTTP_USE_SYSTEM_DEPS environment variable that
    can be used to build aiohttp against the system install of the llhttp library rather
    than the vendored one.

    Related issues and pull requests on GitHub:
    #10759.

  • aiodns is now installed on Windows with speedups extra -- by :user:bdraco.

    As of aiodns 3.3.0, SelectorEventLoop is no longer required when using pycares 4.7.0 or later.

    Related issues and pull requests on GitHub:
    #10823.

  • Fixed compatibility issue with Cython 3.1.1 -- by :user:bdraco

    Related issues and pull requests on GitHub:
    #10877.

Contributor-facing changes

  • Sped up tests by disabling blockbuster fixture for test_static_file_huge and test_static_file_huge_cancel tests -- by :user:dikos1337.

    Related issues and pull requests on GitHub:
    #9705, #10761.

  • Updated tests to avoid using deprecated :py:mod:asyncio policy APIs and
    make it compatible with Python 3.14.

    Related issues and pull requests on GitHub:
    #10851.

  • Added Winloop to test suite to support in the future -- by :user:Vizonex.

    Related issues and pull requests on GitHub:
    #10922.

Miscellaneous internal changes

  • Added support for the partitioned attribute in the set_cookie method.

    Related issues and pull requests on GitHub:
    #9870.

  • Setting :attr:aiohttp.web.StreamResponse.last_modified to an unsupported type will now raise :exc:TypeError instead of silently failing -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10146.


3.12.0b0

20 May 23:24
v3.12.0b0
a61fcc6
Compare
Choose a tag to compare
3.12.0b0 Pre-release
Pre-release

Bug fixes

  • Response is now always True, instead of using MutableMapping behaviour (False when map is empty)

    Related issues and pull requests on GitHub:
    #10119.

  • Fixed pytest plugin to not use deprecated :py:mod:asyncio policy APIs.

    Related issues and pull requests on GitHub:
    #10851.

Features

  • Added a comprehensive HTTP Digest Authentication client middleware (DigestAuthMiddleware)
    that implements RFC 7616. The middleware supports all standard hash algorithms
    (MD5, SHA, SHA-256, SHA-512) with session variants, handles both 'auth' and
    'auth-int' quality of protection options, and automatically manages the
    authentication flow by intercepting 401 responses and retrying with proper
    credentials -- by :user:feus4177, :user:TimMenninger, and :user:bdraco.

    Related issues and pull requests on GitHub:
    #2213, #10725.

  • Added client middleware support -- by :user:bdraco and :user:Dreamsorcerer.

    This change allows users to add middleware to the client session and requests, enabling features like
    authentication, logging, and request/response modification without modifying the core
    request logic. Additionally, the session attribute was added to ClientRequest,
    allowing middleware to access the session for making additional requests.

    Related issues and pull requests on GitHub:
    #9732, #10902.

  • Allow user setting zlib compression backend -- by :user:TimMenninger

    This change allows the user to call :func:aiohttp.set_zlib_backend() with the
    zlib compression module of their choice. Default behavior continues to use
    the builtin zlib library.

    Related issues and pull requests on GitHub:
    #9798.

  • Added support for overriding the base URL with an absolute one in client sessions
    -- by :user:vivodi.

    Related issues and pull requests on GitHub:
    #10074.

  • Added host parameter to aiohttp_server fixture -- by :user:christianwbrock.

    Related issues and pull requests on GitHub:
    #10120.

  • Detect blocking calls in coroutines using BlockBuster -- by :user:cbornet.

    Related issues and pull requests on GitHub:
    #10433.

  • Added socket_factory to :py:class:aiohttp.TCPConnector to allow specifying custom socket options
    -- by :user:TimMenninger.

    Related issues and pull requests on GitHub:
    #10474, #10520.

  • Started building armv7l manylinux wheels -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10797.

  • Implemented shared DNS resolver management to fix excessive resolver object creation
    when using multiple client sessions. The new _DNSResolverManager singleton ensures
    only one DNSResolver object is created for default configurations, significantly
    reducing resource usage and improving performance for applications using multiple
    client sessions simultaneously -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10847.

Packaging updates and notes for downstreams

  • Removed non SPDX-license description from setup.cfg -- by :user:devanshu-ziphq.

    Related issues and pull requests on GitHub:
    #10662.

  • aiodns is now installed on Windows with speedups extra -- by :user:bdraco.

    As of aiodns 3.3.0, SelectorEventLoop is no longer required when using pycares 4.7.0 or later.

    Related issues and pull requests on GitHub:
    #10823.

  • Fixed compatibility issue with Cython 3.1.1 -- by :user:bdraco

    Related issues and pull requests on GitHub:
    #10877.

Contributor-facing changes

  • Sped up tests by disabling blockbuster fixture for test_static_file_huge and test_static_file_huge_cancel tests -- by :user:dikos1337.

    Related issues and pull requests on GitHub:
    #9705, #10761.

  • Updated tests to avoid using deprecated :py:mod:asyncio policy APIs and
    make it compatible with Python 3.14.

    Related issues and pull requests on GitHub:
    #10851.

Miscellaneous internal changes

  • Added support for the partitioned attribute in the set_cookie method.

    Related issues and pull requests on GitHub:
    #9870.

  • Setting :attr:aiohttp.web.StreamResponse.last_modified to an unsupported type will now raise :exc:TypeError instead of silently failing -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10146.


3.11.18

21 Apr 09:39
v3.11.18
2be611a
Compare
Choose a tag to compare

Bug fixes

  • Disabled TLS in TLS warning (when using HTTPS proxies) for uvloop and newer Python versions -- by :user:lezgomatt.

    Related issues and pull requests on GitHub:
    #7686.

  • Fixed reading fragmented WebSocket messages when the payload was masked -- by :user:bdraco.

    The problem first appeared in 3.11.17

    Related issues and pull requests on GitHub:
    #10764.


3.11.17

19 Apr 21:37
v3.11.17
11be7e2
Compare
Choose a tag to compare

Miscellaneous internal changes

  • Optimized web server performance when access logging is disabled by reducing time syscalls -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10713.

  • Improved web server performance when connection can be reused -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10714.

  • Improved performance of the WebSocket reader -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10740.

  • Improved performance of the WebSocket reader with large messages -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10744.


3.11.16

02 Apr 02:14
v3.11.16
c723b3c
Compare
Choose a tag to compare

Bug fixes

  • Replaced deprecated asyncio.iscoroutinefunction with its counterpart from inspect
    -- by :user:layday.

    Related issues and pull requests on GitHub:
    #10634.

  • Fixed :class:multidict.CIMultiDict being mutated when passed to :class:aiohttp.web.Response -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10672.


3.11.15

01 Apr 04:47
v3.11.15
d2d3621
Compare
Choose a tag to compare

Bug fixes

  • Reverted explicitly closing sockets if an exception is raised during create_connection -- by :user:bdraco.

    This change originally appeared in aiohttp 3.11.13

    Related issues and pull requests on GitHub:
    #10464, #10617, #10656.

Miscellaneous internal changes

  • Improved performance of WebSocket buffer handling -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10601.

  • Improved performance of serializing headers -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10625.


3.11.14

17 Mar 02:41
1a48a62
Compare
Choose a tag to compare

Bug fixes

  • Fixed an issue where dns queries were delayed indefinitely when an exception occurred in a trace.send_dns_cache_miss
    -- by :user:logioniz.

    Related issues and pull requests on GitHub:
    #10529.

  • Fixed DNS resolution on platforms that don't support socket.AI_ADDRCONFIG -- by :user:maxbachmann.

    Related issues and pull requests on GitHub:
    #10542.

  • The connector now raises :exc:aiohttp.ClientConnectionError instead of :exc:OSError when failing to explicitly close the socket after :py:meth:asyncio.loop.create_connection fails -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10551.

  • Break cyclic references at connection close when there was a traceback -- by :user:bdraco.

    Special thanks to :user:availov for reporting the issue.

    Related issues and pull requests on GitHub:
    #10556.

  • Break cyclic references when there is an exception handling a request -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10569.

Features

  • Improved logging on non-overlapping WebSocket client protocols to include the remote address -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10564.

Miscellaneous internal changes

  • Improved performance of parsing content types by adding a cache in the same manner currently done with mime types -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10552.


3.11.13

24 Feb 15:57
v3.11.13
6f09c51
Compare
Choose a tag to compare

Bug fixes

  • Removed a break statement inside the finally block in :py:class:~aiohttp.web.RequestHandler
    -- by :user:Cycloctane.

    Related issues and pull requests on GitHub:
    #10434.

  • Changed connection creation to explicitly close sockets if an exception is raised in the event loop's create_connection method -- by :user:top-oai.

    Related issues and pull requests on GitHub:
    #10464.

Packaging updates and notes for downstreams

  • Fixed test test_write_large_payload_deflate_compression_data_in_eof_writelines failing with Python 3.12.9+ or 3.13.2+ -- by :user:bdraco.

    Related issues and pull requests on GitHub:
    #10423.

Miscellaneous internal changes

  • Added human-readable error messages to the exceptions for WebSocket disconnects due to PONG not being received -- by :user:bdraco.

    Previously, the error messages were empty strings, which made it hard to determine what went wrong.

    Related issues and pull requests on GitHub:
    #10422.