This removes the __del__ function from the generated Python client, and replaces it with a cleanup function. When a ThreadPool is created, the cleanup function is registered with the atexit module. This PR also allows the client to be used as a context manager, which will automatically clean up after itself rather than having to wait til process exit. This fixes issue #1037, where the API client could hang indefinitely at garbage collection. |
||
|---|---|---|
| .. | ||
| api | ||
| apis | ||
| models | ||
| __init__.py | ||
| api_client.py | ||
| configuration.py | ||
| rest.py | ||