uvloop
uvloop copied to clipboard
Set thread name prefix for default event loop thread pool
- uvloop version: 0.17.0
- Python version: 3.11
- Platform: any
-
Can you reproduce the bug with
PYTHONASYNCIODEBUGin env?: -
Does uvloop behave differently from vanilla asyncio? How?: When creating a default thread pool
uvloopdoes not set thread name prefix
It would be great to set thread name prefix for a default thread pool used by uvloop. For example the default asyncio loop sets it to asyncio, so for uvloop it could be set to uvloop. It's useful for debugging and for example in DataDog flame graph it makes it easier to identify uvloop threads in this case. Right now it looks like this:
As I understand it should be pretty straightforward change and I could make a PR if there are no objections.