@@ -5,6 +5,51 @@ Release history
5
5
6
6
.. towncrier release notes start
7
7
8
+ trio-asyncio 0.13.0 (2023-12-01)
9
+ --------------------------------
10
+
11
+ Features
12
+ ~~~~~~~~
13
+
14
+ - Exiting an ``async with trio_asyncio.open_loop(): `` block now cancels
15
+ any asyncio tasks that are still running in the background, like
16
+ :func: `asyncio.run ` does, so that they have a chance to clean up
17
+ resources by running async context managers and ``finally ``
18
+ blocks. Previously such tasks would simply be abandoned to the garbage
19
+ collector, resulting in potential deadlocks and stderr spew. Note that,
20
+ like :func: `asyncio.run `, we *do * still abandon any tasks that are
21
+ started during this finalization phase and outlive the existing tasks.
22
+ (`#91 <https://github.com/python-trio/trio-asyncio/issues/91 >`__)
23
+
24
+ Bugfixes
25
+ ~~~~~~~~
26
+
27
+ - A deadlock will no longer occur if :func: `trio_asyncio.open_loop `
28
+ is cancelled before its first checkpoint. We also now cancel and wait on
29
+ all asyncio tasks even if :func: `~trio_asyncio.open_loop ` terminates due
30
+ to an exception that was raised within the ``async with `` block. (`#115 <https://github.com/python-trio/trio-asyncio/issues/115 >`__)
31
+ - Uncaught exceptions from asyncio tasks will now propagate out of the
32
+ :func: `trio_asyncio.open_loop ` call. This has always been the
33
+ documented behavior, but didn't actually work before.
34
+ (`#121 <https://github.com/python-trio/trio-asyncio/issues/121 >`__)
35
+ - Use of ``loop.add_reader() `` or ``loop.add_writer() `` with a socket object
36
+ (rather than a file descriptor) will no longer potentially produce spurious
37
+ uncaught exceptions if the socket is closed in the reader/writer callback.
38
+ (`#121 <https://github.com/python-trio/trio-asyncio/issues/121 >`__)
39
+
40
+ Miscellaneous
41
+ ~~~~~~~~~~~~~
42
+
43
+ - ``trio-asyncio `` now requires Trio 0.22 and does not produce deprecation warnings.
44
+ Python 3.12 is now supported. Python 3.6 and 3.7 are no longer supported. (`#121 <https://github.com/python-trio/trio-asyncio/issues/121 >`__)
45
+ - trio-asyncio now indicates its presence to `sniffio ` using the
46
+ ``sniffio.thread_local `` interface that is preferred since sniffio
47
+ v1.3.0. This should be less likely than the previous approach to cause
48
+ :func: `sniffio.current_async_library ` to return incorrect results due
49
+ to unintended inheritance of contextvars.
50
+ (`#123 <https://github.com/python-trio/trio-asyncio/issues/123 >`__)
51
+
52
+
8
53
trio-asyncio 0.12.0 (2021-01-07)
9
54
--------------------------------
10
55
0 commit comments