Module: Mesa Branch: main Commit: a5e20a5c31b1af9b2b9ea42acc02d6da32ee46f4 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=a5e20a5c31b1af9b2b9ea42acc02d6da32ee46f4
Author: Eric Engestrom <e...@igalia.com> Date: Mon Nov 6 12:46:47 2023 +0000 ci_run_n_monitor: require user to add an explicit `.*` at the end if jobs like `*-full` are wanted Most of the time, these jobs are not wanted, so let's make this a full match instead of prefix match so that users only get what they ask for. Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/26066> --- bin/ci/ci_run_n_monitor.py | 2 +- bin/ci/gitlab_gql.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/ci/ci_run_n_monitor.py b/bin/ci/ci_run_n_monitor.py index 46a627a4dad..4c14d1d5a7a 100755 --- a/bin/ci/ci_run_n_monitor.py +++ b/bin/ci/ci_run_n_monitor.py @@ -105,7 +105,7 @@ def monitor_pipeline( to_cancel = [] for job in pipeline.jobs.list(all=True, sort="desc"): # target jobs - if target_jobs_regex.match(job.name): + if target_jobs_regex.fullmatch(job.name): target_id = job.id if stress and job.status in ["success", "failed"]: diff --git a/bin/ci/gitlab_gql.py b/bin/ci/gitlab_gql.py index b78c8a70c7b..3f422d5d10a 100755 --- a/bin/ci/gitlab_gql.py +++ b/bin/ci/gitlab_gql.py @@ -337,7 +337,7 @@ def create_job_needs_dag(gl_gql: GitlabGQL, params, disable_cache: bool = True) def filter_dag(dag: Dag, regex: Pattern) -> Dag: - jobs_with_regex: set[str] = {job for job in dag if regex.match(job)} + jobs_with_regex: set[str] = {job for job in dag if regex.fullmatch(job)} return Dag({job: data for job, data in dag.items() if job in sorted(jobs_with_regex)})