asyncx.just

async asyncx.just(ret)[source]

Creates a coroutine that returns a specified result.

Example

>>> await asyncx.just(42)
42
Parameters

ret (asyncx.coroutine.TReturn) – The result to return from a coroutine

Returns

A Coroutine[Any, Any, T] object that returns ret.

Return type

asyncx.coroutine.TReturn