Skip to content

Commit 27b28e5

Browse files
stephencpopeDescartes Labs Build
authored andcommitted
[Core-317] Fix oauth2 refresh token flow (#12494)
GitOrigin-RevId: 095cdeb2b1f7afd858cf2f544a6ad82e673a80bf
1 parent a8241a2 commit 27b28e5

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

descarteslabs/auth/auth.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -594,7 +594,11 @@ def session(self):
594594
return self._session.get()
595595

596596
def build_session(self):
597-
return Session(self.domain, retries=self._retry_config)
597+
session = Session(self.domain, retries=self._retry_config)
598+
# local testing will not have necessary certs
599+
if self.domain.startswith("https://dev.localhost"):
600+
session.verify = False
601+
return session
598602

599603
@staticmethod
600604
def get_default_auth():
@@ -700,8 +704,6 @@ def _get_token(self, timeout=100):
700704
if self.client_id in [
701705
# production tenant
702706
"ZOBAi4UROl5gKZIpxxlwOEfx8KpqXf2c",
703-
# descarteslabs-dev tenant
704-
"DK0fmkWyfgBaLzhvhhKXUeu3BkwROIkX",
705707
]: # TODO(justin) remove legacy handling
706708
# TODO (justin) insert deprecation warning
707709
if self.scope is None:

0 commit comments

Comments
 (0)