Re: Await expressions (Posting On Python-List Prohibited)

2024-02-03 Thread Mild Shock via Python-list
Funny source code tells me IOCP is used; proactor is only implemented on Windows with IOCP. https://github.com/python/cpython/blob/3.12/Lib/asyncio/proactor_events.py But maybe the focus is more on networking than file system. But it has sock_sendfile() that might avoid copying data to

Re: Await expressions (Posting On Python-List Prohibited)

2024-02-03 Thread Mild Shock via Python-list
The docu tells me: Windows loop.add_reader() and loop.add_writer() only accept socket handles (e.g. pipe file descriptors are not supported). https://docs.python.org/3/library/asyncio-platforms.html Alternatives are aiofiles and anyio and maybe more, but not sure whether they span all

Re: Await expressions (Posting On Python-List Prohibited)

2024-02-03 Thread Mild Shock via Python-list
And whats the roadmap for an asyncified module loader, is this on the radar of Python? Mild Shock schrieb: I am still waiting for async files in the style of nodejs that works on windows and is bundled with the main python distribution. I am not very  fond on doing something like adding

Re: Await expressions (Posting On Python-List Prohibited)

2024-02-03 Thread Mild Shock via Python-list
I am still waiting for async files in the style of nodejs that works on windows and is bundled with the main python distribution. I am not very fond on doing something like adding listeners to a file descriptor, in nodejs async files are based on callbacks not on listeners. Whats the

Re: Await expressions

2024-01-27 Thread Mild Shock via Python-list
Maybe consult: PEP 492 – Coroutines with async and await syntax Created: 09-Apr-2015 Python-Version: 3.5 https://peps.python.org/pep-0492/ Mild Shock schrieb: We say that an object is an awaitable object if it can be used in an await expression. Many asyncio APIs are designed to accept

Re: Await expressions

2024-01-27 Thread Mild Shock via Python-list
We say that an object is an awaitable object if it can be used in an await expression. Many asyncio APIs are designed to accept awaitables. There are three main types of awaitable objects: coroutines, Tasks, and Futures. Stefan Ram schrieb: In "The Python Language Reference, Release