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 d6f473b31d Add better progress in CI for constraints generation.
(#26253)
d6f473b31d is described below
commit d6f473b31d9902290dc3a204657b4a7ed8d7843b
Author: Jarek Potiuk <[email protected]>
AuthorDate: Thu Sep 8 23:38:51 2022 +0200
Add better progress in CI for constraints generation. (#26253)
Currently constraints generation is not really showing good progress
while the packages are being removed/installed. This adds progress
that shows that something happens.
---
.../commands/release_management_commands.py | 15 +++++++++++++--
1 file changed, 13 insertions(+), 2 deletions(-)
diff --git
a/dev/breeze/src/airflow_breeze/commands/release_management_commands.py
b/dev/breeze/src/airflow_breeze/commands/release_management_commands.py
index e061bd345a..dad5161220 100644
--- a/dev/breeze/src/airflow_breeze/commands/release_management_commands.py
+++ b/dev/breeze/src/airflow_breeze/commands/release_management_commands.py
@@ -65,7 +65,7 @@ from airflow_breeze.utils.docker_command_utils import (
get_extra_docker_flags,
perform_environment_checks,
)
-from airflow_breeze.utils.parallel import check_async_run_results,
run_with_pool
+from airflow_breeze.utils.parallel import GenericRegexpProgressMatcher,
check_async_run_results, run_with_pool
from airflow_breeze.utils.python_versions import get_python_version_list
from airflow_breeze.utils.run_utils import (
RunCommandResult,
@@ -305,6 +305,11 @@ def run_generate_constraints(
)
+CONSTRAINT_PROGRESS_MATCHER = (
+
r'Found|Uninstalling|uninstalled|Collecting|Downloading|eta|Running|Installing|built|Attempting'
+)
+
+
def run_generate_constraints_in_parallel(
shell_params_list: List[ShellParams],
python_version_list: List[str],
@@ -320,7 +325,13 @@ def run_generate_constraints_in_parallel(
f"Constraints
{shell_params.airflow_constraints_mode}:{shell_params.python}"
for shell_params in shell_params_list
]
- with run_with_pool(parallelism=parallelism, all_params=all_params) as
(pool, outputs):
+ with run_with_pool(
+ parallelism=parallelism,
+ all_params=all_params,
+ progress_matcher=GenericRegexpProgressMatcher(
+ regexp=CONSTRAINT_PROGRESS_MATCHER, lines_to_search=6
+ ),
+ ) as (pool, outputs):
results = [
pool.apply_async(
run_generate_constraints,