diff --git a/airflow/providers/amazon/aws/hooks/s3.py b/airflow/providers/amazon/aws/hooks/s3.py index 1a961e583cd52..28b9adf7c658f 100644 --- a/airflow/providers/amazon/aws/hooks/s3.py +++ b/airflow/providers/amazon/aws/hooks/s3.py @@ -1369,6 +1369,10 @@ def download_file( """ Download a file from the S3 location to the local file system. + Note: + This function shadows the 'download_file' method of S3 API, but it is not the same. + If you want to use the original method from S3 API, please use 'S3Hook.get_conn().download_file()' + .. seealso:: - :external+boto3:py:meth:`S3.Object.download_fileobj` @@ -1386,12 +1390,6 @@ def download_file( Default: True. :return: the file name. """ - self.log.info( - "This function shadows the 'download_file' method of S3 API, but it is not the same. If you " - "want to use the original method from S3 API, please call " - "'S3Hook.get_conn().download_file()'" - ) - self.log.info("Downloading source S3 file from Bucket %s with path %s", bucket_name, key) try: