We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ff22ddc commit 64160afCopy full SHA for 64160af
volcenginesdkarkruntime/_client.py
@@ -492,7 +492,14 @@ def _init_local_cert_cache(self):
492
self._cert_expiration_seconds = 14 * 24 * 60 * 60 # 14 days
493
494
if not os.path.exists(self._cert_storage_path):
495
- os.makedirs(self._cert_storage_path)
+ try:
496
+ os.makedirs(self._cert_storage_path)
497
+ except FileExistsError:
498
+ pass
499
+ except Exception as e:
500
+ raise ArkAPIError(
501
+ "failed to create certificate directory %s: %s\n" % (self._cert_storage_path, e)
502
+ )
503
504
def get(self, ep: str) -> key_agreement_client:
505
if ep not in self._certificate_manager:
0 commit comments