Return True if the given function seems to be an async function or an async generator.
(func: object)
| 60 | |
| 61 | |
| 62 | def is_async_function(func: object) -> bool: |
| 63 | class="st">"""Return True if the given function seems to be an async function or |
| 64 | an async generator.class="st">""" |
| 65 | return iscoroutinefunction(func) or inspect.isasyncgenfunction(func) |
| 66 | |
| 67 | |
| 68 | def signature(obj: Callable[..., Any]) -> Signature: |