alexkruc commented on code in PR #26886:
URL: https://github.com/apache/airflow/pull/26886#discussion_r988825458


##########
airflow/providers/amazon/aws/hooks/s3.py:
##########
@@ -909,7 +919,17 @@ def download_file(self, key: str, bucket_name: str | None 
= None, local_path: st
                 Config=self.transfer_config,
             )
 
-        return local_tmp_file.name
+        if preserve_file_name:

Review Comment:
   This is a good point, I've refactored the code accordingly, and now we are 
not renaming but writing to the proper file.
   I'll appreciate another review if possible on the new implementation :) 🙏 



-- 
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