viiccwen commented on code in PR #54582:
URL: https://github.com/apache/airflow/pull/54582#discussion_r2280915969


##########
providers/amazon/src/airflow/providers/amazon/aws/hooks/base_aws.py:
##########
@@ -688,9 +688,10 @@ def account_id(self) -> str:
 
     def get_session(self, region_name: str | None = None, deferrable: bool = 
False) -> boto3.session.Session:
         """Get the underlying 
boto3.session.Session(region_name=region_name)."""
-        return SessionFactory(
-            conn=self.conn_config, region_name=region_name, config=self.config
-        ).create_session(deferrable=deferrable)
+        config = self._config or botocore.config.Config()
+        return SessionFactory(conn=self.conn_config, region_name=region_name, 
config=config).create_session(

Review Comment:
   Oh...My mistake. I missed that config already ensures a valid config. I’ve 
removed the redundant fallback. Thanks for pointing it out! 🙏



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to