Open mjpieters opened 1 year ago
This change makes it possible to use new_client_from_enviroment() and still select between async and sync clients based on the current codebase.
new_client_from_enviroment()
The change includes the type hints needed for type checkers to know what kind of object is returned in what circumstances; e.g.
# client: onepasswordconnectsdk.client.Client client = new_client_from_environment(is_async=False) # client: onepasswordconnectsdk.async_client.AsyncClient async_client = new_client_from_environment(is_async=True)
This makes working with the library a lot easier in IDEs with type checker support as they now know what exact methods a client supports.
This fixes #84
Happy to drop this PR if / when #92 is merged.
This change makes it possible to use
new_client_from_enviroment()
and still select between async and sync clients based on the current codebase.The change includes the type hints needed for type checkers to know what kind of object is returned in what circumstances; e.g.
This makes working with the library a lot easier in IDEs with type checker support as they now know what exact methods a client supports.
This fixes #84