async_unsafe
Decorator to mark functions as async-unsafe. Someone trying to access the function while in an async context will get an error message.
def async_unsafe(
message: string|callable
) - > function
Decorator to mark functions as async-unsafe. Someone trying to access the function while in an async context will get an error message.
Parameters
| Name | Type | Description |
|---|---|---|
| message | `string | callable` |
Returns
| Type | Description |
|---|---|
function | A wrapped version of the function that performs an async-safety check before execution. |