Commit ff4239d
committed
fix: suppress DeprecationWarning in threaded uvicorn server
Python 3.14 deprecates asyncio.iscoroutinefunction(), which uvicorn
calls internally. With pytest's filterwarnings=['error'], this
DeprecationWarning becomes an exception that kills the server thread
before it can start listening.
In multiprocessing mode this was hidden because child processes don't
inherit pytest's warning filters. Threading shares the same process,
so we need to explicitly suppress DeprecationWarnings in the server
thread.1 parent 375e862 commit ff4239d
File tree
1 file changed
+8
-1
lines changed1 file changed
+8
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
1553 | 1554 | | |
1554 | 1555 | | |
1555 | 1556 | | |
1556 | | - | |
| 1557 | + | |
| 1558 | + | |
| 1559 | + | |
| 1560 | + | |
| 1561 | + | |
| 1562 | + | |
| 1563 | + | |
1557 | 1564 | | |
1558 | 1565 | | |
1559 | 1566 | | |
| |||
0 commit comments