[python] Add back __enter__ and __exit__ methods for non asyncio (#16979)

This commit is contained in:
Yohei Kitamura
2023-11-04 04:54:17 -04:00
committed by GitHub
parent c4b18f206d
commit 61629ae8ed
4 changed files with 22 additions and 0 deletions

View File

@@ -90,6 +90,11 @@ class ApiClient:
self.user_agent = 'OpenAPI-Generator/1.0.0/python'
self.client_side_validation = configuration.client_side_validation
def __enter__(self):
return self
def __exit__(self, exc_type, exc_value, traceback):
pass
@property
def user_agent(self):