• Bug#1066793: python-uvicorn: FTBFS: RuntimeError: Unexpected ASGI messa

    From Lucas Nussbaum@21:1/5 to All on Wed Mar 13 16:20:03 2024
    Source: python-uvicorn
    Version: 0.27.1-1
    Severity: serious
    Justification: FTBFS
    Tags: trixie sid ftbfs
    User: lucas@debian.org
    Usertags: ftbfs-20240313 ftbfs-trixie

    Hi,

    During a rebuild of all packages in sid, your package failed to build
    on amd64.


    Relevant part (hopefully):
    make[1]: Entering directory '/<<PKGBUILDDIR>>'
    http_proxy= https_proxy= dh_auto_test
    I: pybuild base:305: cd /<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build; python3.12 -m pytest -s --verbose -k 'not test_run and not test_invalid_upgrade and not test_default_headers and not test_trace_logging and not test_websocket_auto' --ignore=tests/
    protocols/test_websocket.py
    ============================= test session starts ==============================
    platform linux -- Python 3.12.2, pytest-8.0.2, pluggy-1.4.0 -- /usr/bin/python3.12
    cachedir: .pytest_cache
    rootdir: /<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build
    configfile: pyproject.toml
    plugins: anyio-4.2.0, asyncio-0.20.3, mock-3.12.0
    asyncio: mode=Mode.STRICT
    collecting ... collected 365 items / 26 deselected / 339 selected

    tests/importer/test_importer.py::test_invalid_format PASSED tests/importer/test_importer.py::test_invalid_module PASSED tests/importer/test_importer.py::test_invalid_attr PASSED tests/importer/test_importer.py::test_internal_import_error PASSED tests/importer/test_importer.py::test_valid_import PASSED tests/importer/test_importer.py::test_no_import_needed PASSED tests/importer/test_importer.py::test_circular_import_error PASSED tests/middleware/test_logging.py::test_access_logging[True] INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:36849 (Press CTRL+C to quit) INFO: 127.0.0.1:46680 - "GET / HTTP/1.1" 204 No Content
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_access_logging[False] INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:41817 (Press CTRL+C to quit) INFO: 127.0.0.1:42292 - "GET / HTTP/1.1" 204 No Content
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_access_logging[None] INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:35635 (Press CTRL+C to quit) INFO: 127.0.0.1:37284 - "GET / HTTP/1.1" 204 No Content
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_default_logging[True] INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:39885 (Press CTRL+C to quit) INFO: 127.0.0.1:43200 - "GET / HTTP/1.1" 204 No Content
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_default_logging[False] INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:34439 (Press CTRL+C to quit) INFO: 127.0.0.1:58360 - "GET / HTTP/1.1" 204 No Content
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_unknown_status_code INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:54049 (Press CTRL+C to quit) INFO: 127.0.0.1:38942 - "GET / HTTP/1.1" 599
    INFO: Shutting down
    PASSED
    tests/middleware/test_logging.py::test_server_start_with_port_zero INFO: Started server process [1999710]
    INFO: Waiting for application startup.
    INFO: ASGI 'lifespan' protocol appears unsupported.
    INFO: Application startup complete.
    INFO: Uvicorn running on http://127.0.0.1:36695 (Press CTRL+C to quit) INFO: Shutting down
    PASSED
    tests/middleware/test_message_logger.py::test_message_logger FAILED tests/middleware/test_message_logger.py::test_message_logger_exc FAILED tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[*-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[127.0.0.1-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[trusted_hosts2-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[trusted_hosts3-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[127.0.0.1, 10.0.0.1-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_trusted_hosts[192.168.0.1-Remote: http://127.0.0.1:123] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_multiple_proxies[*-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_multiple_proxies[trusted_hosts1-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_multiple_proxies[trusted_hosts2-Remote: https://1.2.3.4:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_multiple_proxies[trusted_hosts3-Remote: https://10.0.2.1:0] FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_invalid_x_forwarded_for FAILED
    tests/middleware/test_proxy_headers.py::test_proxy_headers_websocket_x_forwarded_proto[wsproto-httptools] INFO: Started server process [1999710]
    INFO: Uvicorn running on http://127.0.0.1:52117 (Press CTRL+C to quit) INFO: ('1.2.3.4', 0) - "WebSocket /" [accepted]
    INFO: Shutting down
    PASSED tests/middleware/test_proxy_headers.py::test_proxy_headers_websocket_x_forwarded_proto[wsproto-h11] INFO: Started server process [1999710]
    INFO: Uvicorn running on http://127.0.0.1:57083 (Press CTRL+C to quit) INFO: ('1.2.3.4', 0) - "WebSocket /" [accepted]
    INFO: Shutting down
    PASSED tests/middleware/test_proxy_headers.py::test_proxy_headers_websocket_x_forwarded_proto[websockets-httptools] INFO: Started server process [1999710]
    INFO: Uvicorn running on http://127.0.0.1:58733 (Press CTRL+C to quit) INFO: ('1.2.3.4', 0) - "WebSocket /" [accepted]
    INFO: connection open
    INFO: Shutting down
    INFO: connection closed
    PASSED tests/middleware/test_proxy_headers.py::test_proxy_headers_websocket_x_forwarded_proto[websockets-h11] INFO: Started server process [1999710]
    INFO: Uvicorn running on http://127.0.0.1:45533 (Press CTRL+C to quit) INFO: ('1.2.3.4', 0) - "WebSocket /" [accepted]
    INFO: connection open
    INFO: Shutting down
    INFO: connection closed
    PASSED
    tests/middleware/test_wsgi.py::test_wsgi_get[_WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_get[WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_post[_WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_post[WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_put_more_body[_WSGIMiddleware] FAILED
    tests/middleware/test_wsgi.py::test_wsgi_put_more_body[WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_exception[_WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_exception[WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_exc_info[_WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_wsgi_exc_info[WSGIMiddleware] FAILED tests/middleware/test_wsgi.py::test_build_environ_encoding PASSED tests/protocols/test_http.py::test_get_request[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_get_request[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_request_logging[httptools-/] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200
    PASSED
    tests/protocols/test_http.py::test_request_logging[httptools-/?foo] INFO: 127.0.0.1:8001 - "GET /?foo HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo HTTP/1.1" 200
    PASSED tests/protocols/test_http.py::test_request_logging[httptools-/?foo=bar] INFO: 127.0.0.1:8001 - "GET /?foo=bar HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo=bar HTTP/1.1" 200
    PASSED tests/protocols/test_http.py::test_request_logging[httptools-/?foo=bar&baz=1] INFO: 127.0.0.1:8001 - "GET /?foo=bar&baz=1 HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo=bar&baz=1 HTTP/1.1" 200
    PASSED
    tests/protocols/test_http.py::test_request_logging[h11-/] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200
    PASSED
    tests/protocols/test_http.py::test_request_logging[h11-/?foo] INFO: 127.0.0.1:8001 - "GET /?foo HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo HTTP/1.1" 200
    PASSED
    tests/protocols/test_http.py::test_request_logging[h11-/?foo=bar] INFO: 127.0.0.1:8001 - "GET /?foo=bar HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo=bar HTTP/1.1" 200
    PASSED tests/protocols/test_http.py::test_request_logging[h11-/?foo=bar&baz=1] INFO: 127.0.0.1:8001 - "GET /?foo=bar&baz=1 HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET /?foo=bar&baz=1 HTTP/1.1" 200
    PASSED
    tests/protocols/test_http.py::test_head_request[httptools] INFO: 127.0.0.1:8001 - "HEAD / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_head_request[h11] INFO: 127.0.0.1:8001 - "HEAD / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_post_request[httptools] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_post_request[h11] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_keepalive[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_keepalive[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_keepalive_timeout[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_keepalive_timeout[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED tests/protocols/test_http.py::test_keepalive_timeout_with_pipelined_requests[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED tests/protocols/test_http.py::test_keepalive_timeout_with_pipelined_requests[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_close[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_close[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_chunked_encoding[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_chunked_encoding[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED tests/protocols/test_http.py::test_chunked_encoding_empty_body[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_chunked_encoding_empty_body[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED tests/protocols/test_http.py::test_chunked_encoding_head_request[httptools] INFO: 127.0.0.1:8001 - "HEAD / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_chunked_encoding_head_request[h11] INFO: 127.0.0.1:8001 - "HEAD / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_pipelined_requests[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_pipelined_requests[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_undersized_request[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/response.py", line 24, in __call__
    await send({"type": prefix + "http.response.body", "body": self.body})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 561, in send
    raise RuntimeError("Response content shorter than Content-Length") RuntimeError: Response content shorter than Content-Length
    PASSED
    tests/protocols/test_http.py::test_undersized_request[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/response.py", line 24, in __call__
    await send({"type": prefix + "http.response.body", "body": self.body})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 516, in send
    output = self.conn.send(event=h11.EndOfMessage())
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/usr/lib/python3/dist-packages/h11/_connection.py", line 512, in send
    data_list = self.send_with_data_passthrough(event)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/usr/lib/python3/dist-packages/h11/_connection.py", line 545, in send_with_data_passthrough
    writer(event, data_list.append)
    File "/usr/lib/python3/dist-packages/h11/_writers.py", line 67, in __call__
    self.send_eom(event.headers, write)
    File "/usr/lib/python3/dist-packages/h11/_writers.py", line 96, in send_eom
    raise LocalProtocolError("Too little data for declared Content-Length") h11._util.LocalProtocolError: Too little data for declared Content-Length PASSED
    tests/protocols/test_http.py::test_oversized_request[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/response.py", line 24, in __call__
    await send({"type": prefix + "http.response.body", "body": self.body})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 553, in send
    raise RuntimeError("Response content longer than Content-Length") RuntimeError: Response content longer than Content-Length
    PASSED
    tests/protocols/test_http.py::test_oversized_request[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/response.py", line 24, in __call__
    await send({"type": prefix + "http.response.body", "body": self.body})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 509, in send
    output = self.conn.send(event=h11.Data(data=data))
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/usr/lib/python3/dist-packages/h11/_connection.py", line 512, in send
    data_list = self.send_with_data_passthrough(event)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/usr/lib/python3/dist-packages/h11/_connection.py", line 545, in send_with_data_passthrough
    writer(event, data_list.append)
    File "/usr/lib/python3/dist-packages/h11/_writers.py", line 65, in __call__
    self.send_data(event.data, write)
    File "/usr/lib/python3/dist-packages/h11/_writers.py", line 91, in send_data
    raise LocalProtocolError("Too much data for declared Content-Length") h11._util.LocalProtocolError: Too much data for declared Content-Length PASSED
    tests/protocols/test_http.py::test_large_post_request[httptools] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_large_post_request[h11] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_invalid_http[httptools] WARNING: Invalid HTTP request received.
    PASSED
    tests/protocols/test_http.py::test_invalid_http[h11] WARNING: Invalid HTTP request received.
    PASSED
    tests/protocols/test_http.py::test_app_exception[httptools] ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 493, in app
    raise Exception()
    Exception
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED
    tests/protocols/test_http.py::test_app_exception[h11] ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 493, in app
    raise Exception()
    Exception
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED tests/protocols/test_http.py::test_exception_during_response[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 509, in app
    raise Exception()
    Exception
    PASSED
    tests/protocols/test_http.py::test_exception_during_response[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 509, in app
    raise Exception()
    Exception
    PASSED
    tests/protocols/test_http.py::test_no_response_returned[httptools] ERROR: ASGI callable returned without starting response.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED
    tests/protocols/test_http.py::test_no_response_returned[h11] ERROR: ASGI callable returned without starting response.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED tests/protocols/test_http.py::test_partial_response_returned[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: ASGI callable returned without completing response.
    PASSED
    tests/protocols/test_http.py::test_partial_response_returned[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: ASGI callable returned without completing response.
    PASSED
    tests/protocols/test_http.py::test_duplicate_start_message[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 552, in app
    await send({"type": "http.response.start", "status": 200})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 534, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Expected ASGI message 'http.response.body', but got 'http.response.start'.
    PASSED
    tests/protocols/test_http.py::test_duplicate_start_message[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 552, in app
    await send({"type": "http.response.start", "status": 200})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 501, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Expected ASGI message 'http.response.body', but got 'http.response.start'.
    PASSED
    tests/protocols/test_http.py::test_missing_start_message[httptools] ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 566, in app
    await send({"type": "http.response.body", "body": b""})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 476, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Expected ASGI message 'http.response.start', but got 'http.response.body'.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED
    tests/protocols/test_http.py::test_missing_start_message[h11] ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 566, in app
    await send({"type": "http.response.body", "body": b""})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 469, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Expected ASGI message 'http.response.start', but got 'http.response.body'.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 500 Internal Server Error
    PASSED tests/protocols/test_http.py::test_message_after_body_complete[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 419, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 582, in app
    await send({"type": "http.response.body", "body": b""})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/httptools_impl.py", line 571, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Unexpected ASGI message 'http.response.body' sent, after response already completed.
    PASSED
    tests/protocols/test_http.py::test_message_after_body_complete[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: Exception in ASGI application
    Traceback (most recent call last):
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 412, in run_asgi
    result = await app( # type: ignore[func-returns-value]
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/middleware/proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/tests/protocols/test_http.py", line 582, in app
    await send({"type": "http.response.body", "body": b""})
    File "/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12/build/uvicorn/protocols/http/h11_impl.py", line 522, in send
    raise RuntimeError(msg % message_type)
    RuntimeError: Unexpected ASGI message 'http.response.body' sent, after response already completed.
    PASSED
    tests/protocols/test_http.py::test_value_returned[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: ASGI callable should return None, but returned '123'.
    PASSED
    tests/protocols/test_http.py::test_value_returned[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 200 OK
    ERROR: ASGI callable should return None, but returned '123'.
    PASSED
    tests/protocols/test_http.py::test_early_disconnect[httptools] PASSED tests/protocols/test_http.py::test_early_disconnect[h11] PASSED tests/protocols/test_http.py::test_early_response[httptools] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_early_response[h11] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_read_after_response[httptools] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_read_after_response[h11] INFO: 127.0.0.1:8001 - "POST / HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_http10_request[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.0" 200 OK
    PASSED
    tests/protocols/test_http.py::test_http10_request[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.0" 200 OK
    PASSED
    tests/protocols/test_http.py::test_root_path[httptools] INFO: 127.0.0.1:8001 - "GET /app/ HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_root_path[h11] INFO: 127.0.0.1:8001 - "GET /app/ HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_raw_path[httptools] INFO: 127.0.0.1:8001 - "GET /app/one/two HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_raw_path[h11] INFO: 127.0.0.1:8001 - "GET /app/one/two HTTP/1.1" 200 OK
    PASSED
    tests/protocols/test_http.py::test_max_concurrency[httptools] WARNING: Exceeded concurrency limit.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 503 Service Unavailable
    PASSED
    tests/protocols/test_http.py::test_max_concurrency[h11] WARNING: Exceeded concurrency limit.
    INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 503 Service Unavailable
    PASSED
    tests/protocols/test_http.py::test_shutdown_during_request[httptools] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content
    PASSED
    tests/protocols/test_http.py::test_shutdown_during_request[h11] INFO: 127.0.0.1:8001 - "GET / HTTP/1.1" 204 No Content

    [continued in next message]

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Debian Bug Tracking System@21:1/5 to All on Sun Mar 17 00:50:02 2024
    Processing control commands:

    tag -1 pending
    Bug #1066793 [src:python-uvicorn] python-uvicorn: FTBFS: RuntimeError: Unexpected ASGI message 'http.response.body' sent, after response already completed.
    Added tag(s) pending.

    --
    1066793: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1066793
    Debian Bug Tracking System
    Contact owner@bugs.debian.org with problems

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Michael Fladischer@21:1/5 to All on Sun Mar 17 00:50:02 2024
    Control: tag -1 pending

    Hello,

    Bug #1066793 in python-uvicorn reported by you has been fixed in the
    Git repository and is awaiting an upload. You can see the commit
    message below and you can check the diff of the fix at:

    https://salsa.debian.org/python-team/packages/python-uvicorn/-/commit/55718a39d81de739b09d6ac573241de5c65e1537

    ------------------------------------------------------------------------
    Add patch for compatibility with httpx 0.27.0 (Closes: #1066793). ------------------------------------------------------------------------

    (this message was generated automatically)
    --
    Greetings

    https://bugs.debian.org/1066793

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Debian Bug Tracking System@21:1/5 to All on Sun Mar 17 01:50:01 2024
    This is a multi-part message in MIME format...

    Your message dated Sun, 17 Mar 2024 00:39:55 +0000
    with message-id <E1rleZ9-007FE0-Ie@fasolo.debian.org>
    and subject line Bug#1066793: fixed in python-uvicorn 0.28.0-1
    has caused the Debian Bug report #1066793,
    regarding python-uvicorn: FTBFS: RuntimeError: Unexpected ASGI message 'http.response.body' sent, after response already completed.
    to be marked as done.

    This means that you claim that the problem has been dealt with.
    If this is not the case it is now your responsibility to reopen the
    Bug report if necessary, and/or fix the problem forthwith.

    (NB: If you are a system administrator and have no idea what this
    message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org
    immediately.)


    --
    1066793: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1066793
    Debian Bug Tracking System
    Contact owner@bugs.debian.org with problems

    Received: (at submit) by bugs.debian.org; 13 Mar 2024 15:11:39 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.6-bugs.debian.org_2005_01_02
    (2021-04-09) on buxtehude.debian.org
    X-Spam-Level:
    X-Spam-Status: No, score=-101.9 required=4.0 tests=BAYES_00,DKIMWL_WL_HIGH,
    DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FOURLA,
    FROMDEVELOPER,NORMAL_HTTP_TO_IP,NUMERIC_HTTP_ADDR,SPF_HELO_NONE,
    SPF_NONE,T_SCC_BODY_TEXT_LINE,UNPARSEABLE_RELAY,
    USER_IN_DKIM_WELCOMELIST,USER_IN_DKIM_WHITELIST,WEIRD_PORT,
    WORD_WITHOUT_VOWELS autolearn=ham autolearn_force=no
    version=3.4.6-bugs.debian.org_2005_01_02
    X-Spam-Bayes: score:0.0000 Tokens: new, 153; hammy, 150; neutral, 376; spammy,
    0. spammytokens: hammytokens:0.000-+--python3,
    0.000-+--Hx-spam-relays-external:sk:stravin, 0.000-+--H*RT:sk:stravin,
    0.000-+--Hx-spam-relays-external:311, 0.000-+--H*RT:108
    Retur