Closed
Description
Describe the bug
The current python client in the main is unusable due to a dependency conflict. Specifically, when generating the client using open-api-generator==7.12.0
, the client code requires urllib3 >= 2.1.0, < 3.0.0
, (ref). However, our client also needs boto3, which is only compatible with urllib3 2.x
for Python 3.10+
This leads to 2 ways of solving this
- Generate the client using open-api-generator==7.11.0 to remove the requirement of urllib 2.x: [BUG][Python] Generator produces unusable clients OpenAPITools/openapi-generator#20826 (comment)
- Drop support for python 3.9
Since python 3.9's supports ends in October 2025, which means it is still active now, I think we should go with approach 1 to downgrade the generator version used
To Reproduce
For reference, you can reproduce the client error by running spark getting-started example. You will get
File /opt/conda/lib/python3.11/site-packages/urllib3/poolmanager.py:303, in PoolManager.connection_from_host(self, host, port, scheme, pool_kwargs)
300 request_context["port"] = port
301 request_context["host"] = host
--> 303 return self.connection_from_context(request_context)
File /opt/conda/lib/python3.11/site-packages/urllib3/poolmanager.py:326, in PoolManager.connection_from_context(self, request_context)
324 if not pool_key_constructor:
325 raise URLSchemeUnknown(scheme)
--> 326 pool_key = pool_key_constructor(request_context)
328 return self.connection_from_pool_key(pool_key, request_context=request_context)
File /opt/conda/lib/python3.11/site-packages/urllib3/poolmanager.py:147, in _default_key_normalizer(key_class, request_context)
144 if context.get("key_blocksize") is None:
145 context["key_blocksize"] = _DEFAULT_BLOCKSIZE
--> 147 return key_class(**context)
TypeError: PoolKey.__new__() got an unexpected keyword argument 'key_ca_cert_data'