20
20
from ads .common import logger
21
21
from ads .common .decorator .deprecate import deprecated
22
22
from ads .common .extended_enum import ExtendedEnum
23
- from ads .config import OCI_ODSC_SERVICE_ENDPOINT
24
23
25
24
SECURITY_TOKEN_LEFT_TIME = 600
26
25
@@ -199,14 +198,7 @@ def set_auth(
199
198
>>> ads.set_auth(signer_callable=signer_callable, signer_kwargs=signer_kwargs)
200
199
"""
201
200
signer_kwargs = signer_kwargs or {}
202
- client_kwargs = {
203
- ** (
204
- {"service_endpoint" : OCI_ODSC_SERVICE_ENDPOINT }
205
- if OCI_ODSC_SERVICE_ENDPOINT
206
- else {}
207
- ),
208
- ** (client_kwargs or {}),
209
- }
201
+ client_kwargs = client_kwargs or {}
210
202
211
203
auth_state = AuthState ()
212
204
@@ -502,12 +494,6 @@ def default_signer(client_kwargs: Optional[Dict] = None) -> Dict:
502
494
>>> auth = ads.auth.default_signer() # signer_callable instantiated
503
495
>>> oc.OCIClientFactory(**auth).object_storage # Creates Object storage client using instance principal authentication
504
496
"""
505
- default_client_kwargs = (
506
- {"service_endpoint" : OCI_ODSC_SERVICE_ENDPOINT }
507
- if OCI_ODSC_SERVICE_ENDPOINT
508
- else {}
509
- )
510
-
511
497
auth_state = AuthState ()
512
498
if auth_state .oci_signer or auth_state .oci_signer_callable :
513
499
configuration = ads .telemetry .update_oci_client_config (auth_state .oci_config )
@@ -519,7 +505,6 @@ def default_signer(client_kwargs: Optional[Dict] = None) -> Dict:
519
505
"config" : configuration ,
520
506
"signer" : signer ,
521
507
"client_kwargs" : {
522
- ** default_client_kwargs ,
523
508
** (auth_state .oci_client_kwargs or {}),
524
509
** (client_kwargs or {}),
525
510
},
@@ -532,7 +517,6 @@ def default_signer(client_kwargs: Optional[Dict] = None) -> Dict:
532
517
oci_key_profile = auth_state .oci_key_profile ,
533
518
oci_config = auth_state .oci_config ,
534
519
client_kwargs = {
535
- ** default_client_kwargs ,
536
520
** (auth_state .oci_client_kwargs or {}),
537
521
** (client_kwargs or {}),
538
522
},
0 commit comments