diff --git a/airflow/configuration.py b/airflow/configuration.py index cd218657133a2..bc808d6bfc28e 100644 --- a/airflow/configuration.py +++ b/airflow/configuration.py @@ -777,7 +777,8 @@ def mask_secrets(self): for section, key in self.sensitive_config_values: try: - value = self.get(section, key, suppress_warnings=True) + with self.suppress_future_warnings(): + value = self.get(section, key, suppress_warnings=True) except AirflowConfigException: log.debug( "Could not retrieve value from section %s, for key %s. Skipping redaction of this conf.",