You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by po...@apache.org on 2023/12/19 14:22:53 UTC
(airflow) branch main updated: Less verbose information about changed provider.yaml files (#36307)
This is an automated email from the ASF dual-hosted git repository.
potiuk pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git
The following commit(s) were added to refs/heads/main by this push:
new 7212301b22 Less verbose information about changed provider.yaml files (#36307)
7212301b22 is described below
commit 7212301b2200cb968cd38cdaddb30d7ed7360bda
Author: Jarek Potiuk <ja...@potiuk.com>
AuthorDate: Tue Dec 19 15:22:44 2023 +0100
Less verbose information about changed provider.yaml files (#36307)
When we attempt to see if provider.yaml files make changes in
dependencies, we print verbose information on what provider.yaml
files changeed, but this is not necessary or needed. This change
makes the output less verbose by detail - just a number of changed
files rather than full list of them - the full list is only printed
when `--verbose` flag is used.
---
dev/breeze/src/airflow_breeze/utils/md5_build_check.py | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/dev/breeze/src/airflow_breeze/utils/md5_build_check.py b/dev/breeze/src/airflow_breeze/utils/md5_build_check.py
index 9a43f6ea38..9901d6b1da 100644
--- a/dev/breeze/src/airflow_breeze/utils/md5_build_check.py
+++ b/dev/breeze/src/airflow_breeze/utils/md5_build_check.py
@@ -29,6 +29,7 @@ from airflow_breeze.global_constants import ALL_PROVIDER_YAML_FILES, FILES_FOR_R
from airflow_breeze.utils.console import get_console
from airflow_breeze.utils.path_utils import AIRFLOW_SOURCES_ROOT
from airflow_breeze.utils.run_utils import run_command
+from airflow_breeze.utils.shared_options import get_verbose
if TYPE_CHECKING:
from airflow_breeze.params.build_ci_params import BuildCiParams
@@ -102,11 +103,15 @@ def calculate_md5_checksum_for_files(
if modified_provider_yaml_files:
get_console().print(
"[info]Attempting to generate provider dependencies. "
- "Provider yaml files changed since last check:[/]"
- )
- get_console().print(
- [os.fspath(file.relative_to(AIRFLOW_SOURCES_ROOT)) for file in modified_provider_yaml_files]
+ f"{len(modified_provider_yaml_files)} provider.yaml file(s) changed since last check."
)
+ if get_verbose():
+ get_console().print(
+ [
+ os.fspath(file.relative_to(AIRFLOW_SOURCES_ROOT))
+ for file in modified_provider_yaml_files
+ ]
+ )
# Regenerate provider_dependencies.json
run_command(
[