diff --git a/jupyter_server/gateway/gateway_client.py b/jupyter_server/gateway/gateway_client.py index a96a339d3f..bdc2ab9456 100644 --- a/jupyter_server/gateway/gateway_client.py +++ b/jupyter_server/gateway/gateway_client.py @@ -556,6 +556,10 @@ def load_connection_args(self, **kwargs): have yet to be initialized, we'll do that here. """ + self.log.warning("now in load_connection_args") + + print("print now in load_connection_args") + if len(self._connection_args) == 0: self.init_connection_args() @@ -563,7 +567,7 @@ def load_connection_args(self, **kwargs): prev_auth_token = self.auth_token try: self.auth_token = self.gateway_token_renewer.get_token( - self.auth_header_key, self.auth_scheme, self.auth_token, **kwargs + self.auth_header_key, self.auth_scheme, self.auth_token ) except Exception as ex: self.log.error( @@ -719,6 +723,8 @@ async def _is_retryable(self, method: str, exception: Exception) -> bool: async def gateway_request(endpoint: str, **kwargs: ty.Any) -> HTTPResponse: """Make an async request to kernel gateway endpoint, returns a response""" + print("now in gateway requeest") + kwargs = GatewayClient.instance().load_connection_args(**kwargs) rhc = RetryableHTTPClient() try: