o-nikolas commented on a change in pull request #20858:
URL: https://github.com/apache/airflow/pull/20858#discussion_r786231758
##########
File path: airflow/providers/amazon/aws/hooks/base_aws.py
##########
@@ -199,8 +199,6 @@ def _read_credentials_from_connection(self) ->
Tuple[Optional[str], Optional[str
self.extra_config.get("profile"),
)
self.log.info("Credentials retrieved from
extra_config['s3_config_file']")
- else:
- self.log.info("No credentials retrieved from Connection")
Review comment:
Hey,
There is perhaps a way to modify the logic and the way the conditions are
constructed to reduce the scope of the negative case but nothing jumps out at
me as being trivial. I really would rather not modify functional code in this
PR as it makes it much more risky to cause regressions for the simple goal of
log level clean up.
I really do think everything you need is already there: If you're trying to
use a connection (in any of the 3 ways above), you'll get a log line printed
telling you that you are doing so. If you're trying to use a connection and you
don't see such a log being printed, something has gone wrong and you should
re-asses. The else logging adds no additional data.
Does adding back the else condition at debug level as a compromise not
satisfy your particular use case?
--
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]