- update to 3.9.0:
* Introduced ``AppKey`` for static typing support of ``Application`` storage. * Added a graceful shutdown period which allows pending tasks to complete before the application's cleanup is called. * Added `handler_cancellation`_ parameter to cancel web handler on client disconnection. * This (optionally) reintroduces a feature removed in a previous release. * Recommended for those looking for an extra level of protection against denial-of-service attacks. * Added support for setting response header parameters ``max_line_size`` and ``max_field_size``. * Added ``auto_decompress`` parameter to ``ClientSession.request`` to override ``ClientSession._auto_decompress``. * Changed ``raise_for_status`` to allow a coroutine. * Added client brotli compression support (optional with runtime check). * Added ``client_max_size`` to ``BaseRequest.clone()`` to allow overriding the request body size. -- :user:`anesabml`. * Added a middleware type alias ``aiohttp.typedefs.Middleware``. * Exported ``HTTPMove`` which can be used to catch any redirection request that has a location -- :user:`dreamsorcerer`. * Changed the ``path`` parameter in ``web.run_app()`` to accept a ``pathlib.Path`` object. * Performance: Skipped filtering ``CookieJar`` when the jar is empty or all cookies have expired. * Performance: Only check origin if insecure scheme and there OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-aiohttp?expand=0&rev=106
This commit is contained in:
parent
66f26a47f7
commit
80453ee8c0
@ -1,65 +0,0 @@
|
|||||||
From f984bea2a14c11cb5560aa02263126ed5e1d68bc Mon Sep 17 00:00:00 2001
|
|
||||||
From: Daniel Garcia Moreno <daniel.garcia@suse.com>
|
|
||||||
Date: Wed, 26 Apr 2023 09:27:18 +0200
|
|
||||||
Subject: [PATCH] Update update_query calls to work with latest yarl
|
|
||||||
|
|
||||||
This patch pass "{}" when params is "None" to the url.update_query to
|
|
||||||
avoid setting the url params to None.
|
|
||||||
|
|
||||||
Related to this change in yarl:
|
|
||||||
https://github.com/aio-libs/yarl/commit/dd86b3435093b9ca251ecb7831346b92a3f16b25
|
|
||||||
|
|
||||||
Fix https://github.com/aio-libs/aiohttp/issues/7259
|
|
||||||
---
|
|
||||||
aiohttp/client.py | 10 +++++-----
|
|
||||||
1 file changed, 5 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
Index: aiohttp-3.8.4/aiohttp/client.py
|
|
||||||
===================================================================
|
|
||||||
--- aiohttp-3.8.4.orig/aiohttp/client.py
|
|
||||||
+++ aiohttp-3.8.4/aiohttp/client.py
|
|
||||||
@@ -460,7 +460,7 @@ class ClientSession:
|
|
||||||
]
|
|
||||||
|
|
||||||
for trace in traces:
|
|
||||||
- await trace.send_request_start(method, url.update_query(params), headers)
|
|
||||||
+ await trace.send_request_start(method, url.update_query(params or {}), headers)
|
|
||||||
|
|
||||||
timer = tm.timer()
|
|
||||||
try:
|
|
||||||
@@ -578,7 +578,7 @@ class ClientSession:
|
|
||||||
|
|
||||||
for trace in traces:
|
|
||||||
await trace.send_request_redirect(
|
|
||||||
- method, url.update_query(params), headers, resp
|
|
||||||
+ method, url.update_query(params or {}), headers, resp
|
|
||||||
)
|
|
||||||
|
|
||||||
redirects += 1
|
|
||||||
@@ -630,7 +630,7 @@ class ClientSession:
|
|
||||||
headers.pop(hdrs.AUTHORIZATION, None)
|
|
||||||
|
|
||||||
url = parsed_url
|
|
||||||
- params = None
|
|
||||||
+ params = {}
|
|
||||||
resp.release()
|
|
||||||
continue
|
|
||||||
|
|
||||||
@@ -653,7 +653,7 @@ class ClientSession:
|
|
||||||
|
|
||||||
for trace in traces:
|
|
||||||
await trace.send_request_end(
|
|
||||||
- method, url.update_query(params), headers, resp
|
|
||||||
+ method, url.update_query(params or {}), headers, resp
|
|
||||||
)
|
|
||||||
return resp
|
|
||||||
|
|
||||||
@@ -666,7 +666,7 @@ class ClientSession:
|
|
||||||
|
|
||||||
for trace in traces:
|
|
||||||
await trace.send_request_exception(
|
|
||||||
- method, url.update_query(params), headers, e
|
|
||||||
+ method, url.update_query(params or {}), headers, e
|
|
||||||
)
|
|
||||||
raise
|
|
||||||
|
|
@ -1,3 +0,0 @@
|
|||||||
version https://git-lfs.github.com/spec/v1
|
|
||||||
oid sha256:b0cf2a4501bff9330a8a5248b4ce951851e415bdcce9dc158e76cfd55e15085c
|
|
||||||
size 7352172
|
|
3
aiohttp-3.9.0.tar.gz
Normal file
3
aiohttp-3.9.0.tar.gz
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
version https://git-lfs.github.com/spec/v1
|
||||||
|
oid sha256:09f23292d29135025e19e8ff4f0a68df078fe4ee013bca0105b2e803989de92d
|
||||||
|
size 7475063
|
@ -1,3 +1,123 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Sat Nov 25 22:51:20 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
- update to 3.9.0:
|
||||||
|
* Introduced ``AppKey`` for static typing support of
|
||||||
|
``Application`` storage.
|
||||||
|
* Added a graceful shutdown period which allows pending tasks
|
||||||
|
to complete before the application's cleanup is called.
|
||||||
|
* Added `handler_cancellation`_ parameter to cancel web handler on
|
||||||
|
client disconnection.
|
||||||
|
* This (optionally) reintroduces a feature removed in a
|
||||||
|
previous release.
|
||||||
|
* Recommended for those looking for an extra level of
|
||||||
|
protection against denial-of-service attacks.
|
||||||
|
* Added support for setting response header parameters
|
||||||
|
``max_line_size`` and ``max_field_size``.
|
||||||
|
* Added ``auto_decompress`` parameter to
|
||||||
|
``ClientSession.request`` to override
|
||||||
|
``ClientSession._auto_decompress``.
|
||||||
|
* Changed ``raise_for_status`` to allow a coroutine.
|
||||||
|
* Added client brotli compression support (optional with
|
||||||
|
runtime check).
|
||||||
|
* Added ``client_max_size`` to ``BaseRequest.clone()`` to allow
|
||||||
|
overriding the request body size. -- :user:`anesabml`.
|
||||||
|
* Added a middleware type alias
|
||||||
|
``aiohttp.typedefs.Middleware``.
|
||||||
|
* Exported ``HTTPMove`` which can be used to catch any
|
||||||
|
redirection request that has a location -- :user:`dreamsorcerer`.
|
||||||
|
* Changed the ``path`` parameter in ``web.run_app()`` to accept
|
||||||
|
a ``pathlib.Path`` object.
|
||||||
|
* Performance: Skipped filtering ``CookieJar`` when the jar is
|
||||||
|
empty or all cookies have expired.
|
||||||
|
* Performance: Only check origin if insecure scheme and there
|
||||||
|
are origins to treat as secure, in
|
||||||
|
``CookieJar.filter_cookies()``.
|
||||||
|
* Performance: Used timestamp instead of ``datetime`` to
|
||||||
|
achieve faster cookie expiration in ``CookieJar``.
|
||||||
|
* Added support for passing a custom server name parameter to
|
||||||
|
HTTPS connection.
|
||||||
|
* Added support for using Basic Auth credentials from
|
||||||
|
:file:`.netrc` file when making HTTP requests with the
|
||||||
|
* :py:class:`~aiohttp.ClientSession` ``trust_env`` argument is
|
||||||
|
set to ``True``. -- by :user:`yuvipanda`.
|
||||||
|
* Turned access log into no-op when the logger is disabled.
|
||||||
|
* Added typing information to ``RawResponseMessage``. -- by
|
||||||
|
:user:`Gobot1234`
|
||||||
|
* Removed ``async-timeout`` for Python 3.11+ (replaced with
|
||||||
|
``asyncio.timeout()`` on newer releases).
|
||||||
|
* Added support for ``brotlicffi`` as an alternative to
|
||||||
|
``brotli`` (fixing Brotli support on PyPy).
|
||||||
|
* Added ``WebSocketResponse.get_extra_info()`` to access a
|
||||||
|
protocol transport's extra info.
|
||||||
|
* Allow ``link`` argument to be set to None/empty in HTTP 451
|
||||||
|
exception.
|
||||||
|
* Fixed client timeout not working when incoming data is always
|
||||||
|
available without waiting. -- by :user:`Dreamsorcerer`.
|
||||||
|
* Fixed ``readuntil`` to work with a delimiter of more than one
|
||||||
|
character.
|
||||||
|
* Added ``__repr__`` to ``EmptyStreamReader`` to avoid
|
||||||
|
``AttributeError``.
|
||||||
|
* Fixed bug when using ``TCPConnector`` with
|
||||||
|
``ttl_dns_cache=0``.
|
||||||
|
* Fixed response returned from expect handler being thrown
|
||||||
|
away. -- by :user:`Dreamsorcerer`
|
||||||
|
* Avoided raising ``UnicodeDecodeError`` in multipart and in
|
||||||
|
HTTP headers parsing.
|
||||||
|
* Changed ``sock_read`` timeout to start after writing has
|
||||||
|
finished, avoiding read timeouts caused by an unfinished
|
||||||
|
write. -- by :user:`dtrifiro`
|
||||||
|
* Fixed missing query in tracing method URLs when using
|
||||||
|
``yarl`` 1.9+.
|
||||||
|
* Changed max 32-bit timestamp to an aware datetime object, for
|
||||||
|
consistency with the non-32-bit one, and to avoid a
|
||||||
|
``DeprecationWarning`` on Python 3.12.
|
||||||
|
* Fixed ``EmptyStreamReader.iter_chunks()`` never ending.
|
||||||
|
* Fixed a rare ``RuntimeError: await wasn't used with future``
|
||||||
|
exception.
|
||||||
|
* Fixed issue with insufficient HTTP method and version
|
||||||
|
validation.
|
||||||
|
* Added check to validate that absolute URIs have schemes.
|
||||||
|
* Fixed unhandled exception when Python HTTP parser encounters
|
||||||
|
unpaired Unicode surrogates.
|
||||||
|
* Updated parser to disallow invalid characters in header field
|
||||||
|
names and stop accepting LF as a request line separator.
|
||||||
|
* Fixed Python HTTP parser not treating 204/304/1xx as an empty
|
||||||
|
body.
|
||||||
|
* Ensure empty body response for 1xx/204/304 per RFC 9112 sec
|
||||||
|
6.3.
|
||||||
|
* Fixed an issue when a client request is closed before
|
||||||
|
completing a chunked payload. -- by :user:`Dreamsorcerer`
|
||||||
|
* Edge Case Handling for ResponseParser for missing reason
|
||||||
|
value.
|
||||||
|
* Fixed ``ClientWebSocketResponse.close_code`` being
|
||||||
|
erroneously set to ``None`` when there are concurrent async
|
||||||
|
tasks receiving data and closing the connection.
|
||||||
|
* Added HTTP method validation.
|
||||||
|
* Fixed arbitrary sequence types being allowed to inject values
|
||||||
|
via version parameter. -- by :user:`Dreamsorcerer`
|
||||||
|
* Performance: Fixed increase in latency with small messages
|
||||||
|
from websocket compression changes.
|
||||||
|
* Improved Documentation
|
||||||
|
* Fixed the `ClientResponse.release`'s type in the doc. Changed
|
||||||
|
from `comethod` to `method`.
|
||||||
|
* Added information on behavior of base_url parameter in
|
||||||
|
`ClientSession`.
|
||||||
|
* Completed ``trust_env`` parameter description to honor
|
||||||
|
``wss_proxy``, ``ws_proxy`` or ``no_proxy`` env.
|
||||||
|
* Dropped Python 3.6 support.
|
||||||
|
* Dropped Python 3.7 support. -- by :user:`Dreamsorcerer`
|
||||||
|
* Removed support for abandoned ``tokio`` event loop.
|
||||||
|
* Made ``print`` argument in ``run_app()`` optional.
|
||||||
|
* Improved performance of ``ceil_timeout`` in some cases.
|
||||||
|
* Changed importing Gunicorn to happen on-demand, decreasing
|
||||||
|
import time by ~53%. -- :user:`Dreamsorcerer`
|
||||||
|
* Improved import time by replacing ``http.server`` with
|
||||||
|
``http.HTTPStatus``.
|
||||||
|
* Fixed annotation of ``ssl`` parameter to disallow ``True``.
|
||||||
|
- drop Update-update_query-calls-to-work-with-latest-yarl.patch
|
||||||
|
(upstream)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Nov 7 11:52:54 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
Tue Nov 7 11:52:54 UTC 2023 - Dirk Müller <dmueller@suse.com>
|
||||||
|
|
||||||
|
@ -16,31 +16,26 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
%define skip_python2 1
|
|
||||||
# requires some unavailable modules
|
|
||||||
%bcond_with docs
|
%bcond_with docs
|
||||||
%{?sle15_python_module_pythons}
|
%{?sle15_python_module_pythons}
|
||||||
Name: python-aiohttp
|
Name: python-aiohttp
|
||||||
Version: 3.8.6
|
Version: 3.9.0
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Asynchronous HTTP client/server framework
|
Summary: Asynchronous HTTP client/server framework
|
||||||
License: Apache-2.0
|
License: Apache-2.0
|
||||||
URL: https://github.com/aio-libs/aiohttp
|
URL: https://github.com/aio-libs/aiohttp
|
||||||
Source: https://files.pythonhosted.org/packages/source/a/aiohttp/aiohttp-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/a/aiohttp/aiohttp-%{version}.tar.gz
|
||||||
# PATCH-FIX-UPSTREAM Update-update_query-calls-to-work-with-latest-yarl.patch gh#aio-libs/aiohttp#7260
|
|
||||||
Patch0: Update-update_query-calls-to-work-with-latest-yarl.patch
|
|
||||||
# PATCH-FIX-OPENSUSE remove-re-assert.patch mcepl@suse.com
|
# PATCH-FIX-OPENSUSE remove-re-assert.patch mcepl@suse.com
|
||||||
# We really don’t need beautifuly presented exceptions for our testing
|
# We really don’t need beautifuly presented exceptions for our testing
|
||||||
Patch1: remove-re-assert.patch
|
Patch1: remove-re-assert.patch
|
||||||
Requires: python-aiosignal >= 1.1.2
|
Requires: python-aiosignal >= 1.1.2
|
||||||
Requires: python-attrs >= 17.3.0
|
Requires: python-attrs >= 17.3.0
|
||||||
Requires: python-frozenlist >= 1.1.1
|
Requires: python-frozenlist >= 1.1.1
|
||||||
|
# %if %python_version_nodots < 311
|
||||||
Requires: (python-async_timeout >= 4.0 with python-async_timeout < 5)
|
Requires: (python-async_timeout >= 4.0 with python-async_timeout < 5)
|
||||||
Requires: (python-asynctest = 0.13.0 if python-base < 3.8)
|
# %endif
|
||||||
Requires: (python-charset-normalizer >= 2.0 with python-charset-normalizer < 4)
|
Requires: (python-charset-normalizer >= 2.0 with python-charset-normalizer < 4)
|
||||||
Requires: (python-idna_ssl >= 1.0 if python-base < 3.7)
|
|
||||||
Requires: (python-multidict >= 4.5 with python-multidict < 7)
|
Requires: (python-multidict >= 4.5 with python-multidict < 7)
|
||||||
Requires: (python-typing_extensions >= 3.7.4 if python-base < 3.8)
|
|
||||||
Requires: (python-yarl >= 1.0 with python-yarl < 2)
|
Requires: (python-yarl >= 1.0 with python-yarl < 2)
|
||||||
Recommends: python-Brotli
|
Recommends: python-Brotli
|
||||||
Recommends: python-aiodns
|
Recommends: python-aiodns
|
||||||
@ -48,24 +43,21 @@ Recommends: python-cChardet
|
|||||||
Suggests: %{name}-doc
|
Suggests: %{name}-doc
|
||||||
# SECTION build requirements
|
# SECTION build requirements
|
||||||
BuildRequires: %{python_module Cython}
|
BuildRequires: %{python_module Cython}
|
||||||
BuildRequires: %{python_module devel >= 3.6}
|
BuildRequires: %{python_module devel >= 3.9}
|
||||||
BuildRequires: %{python_module pip}
|
BuildRequires: %{python_module pip}
|
||||||
|
BuildRequires: %{python_module python-on-whales}
|
||||||
BuildRequires: %{python_module setuptools}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module wheel}
|
BuildRequires: %{python_module wheel}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: http-parser-devel
|
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
# /SECTION
|
# /SECTION
|
||||||
# SECTION install requirements
|
# SECTION install requirements
|
||||||
BuildRequires: %{python_module aiosignal >= 1.1.2}
|
BuildRequires: %{python_module aiosignal >= 1.1.2}
|
||||||
BuildRequires: %{python_module async_timeout >= 4.0 with %python-async_timeout < 5}
|
BuildRequires: %{python_module async_timeout >= 4.0 with %python-async_timeout < 5}
|
||||||
BuildRequires: %{python_module asynctest = 0.13.0 if %python-base < 3.8}
|
|
||||||
BuildRequires: %{python_module attrs >= 17.3.0}
|
BuildRequires: %{python_module attrs >= 17.3.0}
|
||||||
BuildRequires: %{python_module charset-normalizer >= 2.0 with %python-charset-normalizer < 4}
|
BuildRequires: %{python_module charset-normalizer >= 2.0 with %python-charset-normalizer < 4}
|
||||||
BuildRequires: %{python_module frozenlist >= 1.1.1}
|
BuildRequires: %{python_module frozenlist >= 1.1.1}
|
||||||
BuildRequires: %{python_module idna_ssl >= 1.0 if %python-base < 3.7}
|
|
||||||
BuildRequires: %{python_module multidict >= 4.5 with %python-multidict < 7}
|
BuildRequires: %{python_module multidict >= 4.5 with %python-multidict < 7}
|
||||||
BuildRequires: %{python_module typing_extensions >= 3.7.4 if %python-base < 3.8}
|
|
||||||
BuildRequires: %{python_module yarl >= 1.0 with %python-yarl < 2}
|
BuildRequires: %{python_module yarl >= 1.0 with %python-yarl < 2}
|
||||||
# /SECTION
|
# /SECTION
|
||||||
# SECTION test requirements
|
# SECTION test requirements
|
||||||
@ -78,6 +70,8 @@ BuildRequires: %{python_module proxy.py}
|
|||||||
BuildRequires: %{python_module pytest >= 6.2.0}
|
BuildRequires: %{python_module pytest >= 6.2.0}
|
||||||
BuildRequires: %{python_module pytest-mock}
|
BuildRequires: %{python_module pytest-mock}
|
||||||
BuildRequires: %{python_module pytest-timeout}
|
BuildRequires: %{python_module pytest-timeout}
|
||||||
|
BuildRequires: %{python_module pytest-xdist}
|
||||||
|
BuildRequires: %{python_module time-machine}
|
||||||
BuildRequires: %{python_module trustme}
|
BuildRequires: %{python_module trustme}
|
||||||
# /SECTION
|
# /SECTION
|
||||||
# SECTION docs
|
# SECTION docs
|
||||||
@ -137,17 +131,9 @@ donttest+=" or test_client_session_timeout_zero or test_requote_redirect_url_def
|
|||||||
# flaky
|
# flaky
|
||||||
donttest+=" or test_https_proxy_unsupported_tls_in_tls"
|
donttest+=" or test_https_proxy_unsupported_tls_in_tls"
|
||||||
# not running under pytest ?!
|
# not running under pytest ?!
|
||||||
donttest+=" or test_no_warnings"
|
donttest+=" or test_circular_imports"
|
||||||
%{python_expand # Does not work on python <= 3.6
|
test -d aiohttp && mv aiohttp aiohttp.bkp
|
||||||
if [ %{$python_version_nodots} -eq 36 ]; then
|
%pytest_arch %{?jobs: -n %jobs} tests -k "not ($donttest ${$python_donttest})"
|
||||||
#See https://github.com/openSUSE/python-rpm-macros#flavor-expansion for an explanation of this hack
|
|
||||||
$python_donttest=" or test_read_boundary_with_incomplete_chunk"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
# Disable DeprecationWarning to avoid error with the latest setuptools
|
|
||||||
# and pkg_resources deprecation
|
|
||||||
%pytest_arch tests -rsEf -k "not ($donttest ${$python_donttest})" -W ignore::DeprecationWarning
|
|
||||||
|
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
|
@ -5,17 +5,19 @@
|
|||||||
tests/test_web_response.py | 27 ++++++++++++---------------
|
tests/test_web_response.py | 27 ++++++++++++---------------
|
||||||
4 files changed, 20 insertions(+), 24 deletions(-)
|
4 files changed, 20 insertions(+), 24 deletions(-)
|
||||||
|
|
||||||
--- a/tests/test_client_session.py
|
Index: aiohttp-3.9.0/tests/test_client_session.py
|
||||||
+++ b/tests/test_client_session.py
|
===================================================================
|
||||||
@@ -3,6 +3,7 @@ import contextlib
|
--- aiohttp-3.9.0.orig/tests/test_client_session.py
|
||||||
|
+++ aiohttp-3.9.0/tests/test_client_session.py
|
||||||
|
@@ -2,6 +2,7 @@ import asyncio
|
||||||
|
import contextlib
|
||||||
import gc
|
import gc
|
||||||
import io
|
import io
|
||||||
import json
|
|
||||||
+import re
|
+import re
|
||||||
import sys
|
import json
|
||||||
from http.cookies import SimpleCookie
|
from http.cookies import SimpleCookie
|
||||||
from typing import Any, List
|
from typing import Any, List
|
||||||
@@ -10,7 +11,6 @@ from unittest import mock
|
@@ -9,7 +10,6 @@ from unittest import mock
|
||||||
|
|
||||||
import pytest
|
import pytest
|
||||||
from multidict import CIMultiDict, MultiDict
|
from multidict import CIMultiDict, MultiDict
|
||||||
@ -23,7 +25,7 @@
|
|||||||
from yarl import URL
|
from yarl import URL
|
||||||
|
|
||||||
import aiohttp
|
import aiohttp
|
||||||
@@ -322,8 +322,8 @@ def test_connector_loop(loop) -> None:
|
@@ -320,8 +320,8 @@ def test_connector_loop(loop) -> None:
|
||||||
|
|
||||||
loop.run_until_complete(make_sess())
|
loop.run_until_complete(make_sess())
|
||||||
assert (
|
assert (
|
||||||
@ -34,8 +36,10 @@
|
|||||||
)
|
)
|
||||||
another_loop.run_until_complete(connector.close())
|
another_loop.run_until_complete(connector.close())
|
||||||
|
|
||||||
--- a/tests/test_streams.py
|
Index: aiohttp-3.9.0/tests/test_streams.py
|
||||||
+++ b/tests/test_streams.py
|
===================================================================
|
||||||
|
--- aiohttp-3.9.0.orig/tests/test_streams.py
|
||||||
|
+++ aiohttp-3.9.0/tests/test_streams.py
|
||||||
@@ -3,13 +3,13 @@
|
@@ -3,13 +3,13 @@
|
||||||
import abc
|
import abc
|
||||||
import asyncio
|
import asyncio
|
||||||
@ -50,8 +54,8 @@
|
|||||||
-from re_assert import Matches
|
-from re_assert import Matches
|
||||||
|
|
||||||
from aiohttp import streams
|
from aiohttp import streams
|
||||||
from aiohttp.helpers import PY_311
|
|
||||||
@@ -1075,7 +1075,7 @@ class TestStreamReader:
|
@@ -1102,7 +1102,7 @@ class TestStreamReader:
|
||||||
loop = asyncio.get_event_loop()
|
loop = asyncio.get_event_loop()
|
||||||
stream = self._make_one()
|
stream = self._make_one()
|
||||||
stream._waiter = loop.create_future()
|
stream._waiter = loop.create_future()
|
||||||
@ -60,8 +64,10 @@
|
|||||||
stream._waiter.set_result(None)
|
stream._waiter.set_result(None)
|
||||||
await stream._waiter
|
await stream._waiter
|
||||||
stream._waiter = None
|
stream._waiter = None
|
||||||
--- a/tests/test_urldispatch.py
|
Index: aiohttp-3.9.0/tests/test_urldispatch.py
|
||||||
+++ b/tests/test_urldispatch.py
|
===================================================================
|
||||||
|
--- aiohttp-3.9.0.orig/tests/test_urldispatch.py
|
||||||
|
+++ aiohttp-3.9.0/tests/test_urldispatch.py
|
||||||
@@ -5,7 +5,6 @@ from collections.abc import Container, I
|
@@ -5,7 +5,6 @@ from collections.abc import Container, I
|
||||||
from urllib.parse import unquote
|
from urllib.parse import unquote
|
||||||
|
|
||||||
@ -97,8 +103,10 @@
|
|||||||
|
|
||||||
|
|
||||||
async def test_match_info_with_plus(router) -> None:
|
async def test_match_info_with_plus(router) -> None:
|
||||||
--- a/tests/test_web_response.py
|
Index: aiohttp-3.9.0/tests/test_web_response.py
|
||||||
+++ b/tests/test_web_response.py
|
===================================================================
|
||||||
|
--- aiohttp-3.9.0.orig/tests/test_web_response.py
|
||||||
|
+++ aiohttp-3.9.0/tests/test_web_response.py
|
||||||
@@ -2,13 +2,13 @@ import collections.abc
|
@@ -2,13 +2,13 @@ import collections.abc
|
||||||
import datetime
|
import datetime
|
||||||
import gzip
|
import gzip
|
||||||
@ -125,7 +133,7 @@
|
|||||||
|
|
||||||
|
|
||||||
async def test_compression_no_accept() -> None:
|
async def test_compression_no_accept() -> None:
|
||||||
@@ -776,7 +778,7 @@ def test_response_cookies() -> None:
|
@@ -843,7 +845,7 @@ def test_response_cookies() -> None:
|
||||||
'Set-Cookie: name=("")?; '
|
'Set-Cookie: name=("")?; '
|
||||||
"expires=Thu, 01 Jan 1970 00:00:00 GMT; Max-Age=0; Path=/"
|
"expires=Thu, 01 Jan 1970 00:00:00 GMT; Max-Age=0; Path=/"
|
||||||
)
|
)
|
||||||
@ -134,7 +142,7 @@
|
|||||||
|
|
||||||
resp.set_cookie("name", "value", domain="local.host")
|
resp.set_cookie("name", "value", domain="local.host")
|
||||||
expected = "Set-Cookie: name=value; Domain=local.host; Path=/"
|
expected = "Set-Cookie: name=value; Domain=local.host; Path=/"
|
||||||
@@ -828,7 +830,7 @@ def test_response_cookie__issue_del_cook
|
@@ -895,7 +897,7 @@ def test_response_cookie__issue_del_cook
|
||||||
'Set-Cookie: name=("")?; '
|
'Set-Cookie: name=("")?; '
|
||||||
"expires=Thu, 01 Jan 1970 00:00:00 GMT; Max-Age=0; Path=/"
|
"expires=Thu, 01 Jan 1970 00:00:00 GMT; Max-Age=0; Path=/"
|
||||||
)
|
)
|
||||||
@ -143,7 +151,7 @@
|
|||||||
|
|
||||||
|
|
||||||
def test_cookie_set_after_del() -> None:
|
def test_cookie_set_after_del() -> None:
|
||||||
@@ -1069,14 +1071,13 @@ async def test_send_headers_for_empty_bo
|
@@ -1136,14 +1138,13 @@ async def test_send_headers_for_empty_bo
|
||||||
await resp.write_eof()
|
await resp.write_eof()
|
||||||
txt = buf.decode("utf8")
|
txt = buf.decode("utf8")
|
||||||
assert (
|
assert (
|
||||||
@ -160,7 +168,7 @@
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -1089,15 +1090,13 @@ async def test_render_with_body(buf, wri
|
@@ -1156,15 +1157,13 @@ async def test_render_with_body(buf, wri
|
||||||
|
|
||||||
txt = buf.decode("utf8")
|
txt = buf.decode("utf8")
|
||||||
assert (
|
assert (
|
||||||
@ -178,7 +186,7 @@
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -1111,15 +1110,13 @@ async def test_send_set_cookie_header(bu
|
@@ -1178,15 +1177,13 @@ async def test_send_set_cookie_header(bu
|
||||||
|
|
||||||
txt = buf.decode("utf8")
|
txt = buf.decode("utf8")
|
||||||
assert (
|
assert (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user