Christopher Hunt added the comment:
For impl.1:
> (very breaking change)
should be
> (very breaking change, mitigated some by the fact that the implementation
> will warn about the unawaited future)
--
___
Python tracker
Christopher Hunt added the comment:
My use case is scheduling work against an executor but waiting on the results
later (on demand).
If converting `BaseEventLoop.run_in_executor(executor, func, *args)` to a
coroutine function, I believe there are two possible approaches (the discussion
Andrew Svetlov added the comment:
I would rather change the implementation by converting it into async function.
It can break some code, sure -- but in a very explicit way (coroutine
`run_in_executor is never awaited` error).
Making existing third-party code forward-compatible is trivial:
New submission from Christopher Hunt :
Currently AbstractEventLoop.run_in_executor is specified as a coroutine, while
BaseEventLoop.run_in_executor is actually a non-coroutine that returns a Future
object. The behavior of BaseEventLoop.run_in_executor would be significantly
different if