prefect.client.utilities
¶
Utilities for working with clients.
inject_client
¶
Simple helper to provide a context managed client to a asynchronous function.
The decorated function must take a client
kwarg and if a client is passed when
called it will be used instead of creating a new one, but it will not be context
managed as it is assumed that the caller is managing the context.
Source code in /home/runner/work/docs/docs/prefect_source/src/prefect/client/utilities.py
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
|