[issue39758] StreamWriter.wait_closed() can hang indefinitely.

Kumar Aditya report at bugs.python.org
Thu Mar 3 06:14:26 EST 2022


Kumar Aditya <rahuladitya303 at gmail.com> added the comment:

On main branch with rewritten SSL implementation GH-31275 bpo-44011, this raises TimeoutError:

--------------------------------------------------------------------------------
opened
close started

Traceback (most recent call last):
  File "/workspaces/cpython/main.py", line 18, in <module>
    asyncio.run(main())
    ^^^^^^^^^^^^^^^^^^^
  File "/workspaces/cpython/Lib/asyncio/runners.py", line 44, in run
    return loop.run_until_complete(main)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspaces/cpython/Lib/asyncio/base_events.py", line 645, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "/workspaces/cpython/main.py", line 14, in main
    await writer.wait_closed()
    ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/workspaces/cpython/Lib/asyncio/streams.py", line 344, in wait_closed
    await self._protocol._get_close_waiter(self)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TimeoutError: SSL shutdown timed out
--------------------------------------------------------------------------------

This issue has been fixed, it can be closed @asvetlov.

----------
nosy: +kumaraditya303
type: performance -> behavior
versions:  -Python 3.10, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39758>
_______________________________________


More information about the Python-bugs-list mailing list