from_coroutine
Fonction
Autocomplétion à partir d'une fonction async, avec cache optionnel.
from discord_interactions.slash import from_coroutineSignature
def from_coroutine( coro_func: Callable[..., Awaitable[List[str]]], *, cache_ttl: float = 0,) -> Callable[..., Awaitable[List[Tuple[str, Any]]]]Paramètres
| Nom | Type | Défaut | Description |
|---|---|---|---|
coro_func | Callable[..., Awaitable[List[str]]] | requis | |
cache_ttl | float | 0 |
Retour
Callable[..., Awaitable[List[Tuple[str, Any]]]]