From 06f7515f3469cd0db48a568aa0c6c0d08fb3fba9 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Wed, 1 Oct 2025 09:14:48 +0200 Subject: [PATCH 1/4] Add pre-job for pytest-to-ref --- main-basop.yml | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/main-basop.yml b/main-basop.yml index ee898bb..8054d96 100644 --- a/main-basop.yml +++ b/main-basop.yml @@ -147,6 +147,18 @@ workflow: - if: $CI_PIPELINE_SOURCE == 'push' when: never +.rules-pytest-to-ref-pre: + rules: + - if: $PYTEST_MLD_SHORT + - if: $PYTEST_MLD_LONG + - if: $PYTEST_MLD_LONG_FX_FX + - if: $CI_PIPELINE_SOURCE == 'web' + - if: $CI_PIPELINE_SOURCE == 'schedule' + - if: $CI_PIPELINE_SOURCE == 'push' + when: never + - if: $CI_PIPELINE_SOURCE == 'merge_request_event' + when: never + .rules-pytest-to-ref-short: rules: - if: $PYTEST_MLD_SHORT # Set by scheduled pipeline @@ -242,7 +254,7 @@ workflow: .ivas-pytest-anchor: &ivas-pytest-anchor stage: test - needs: ["build-codec-linux-make"] + needs: ["build-codec-linux-make", "pytest-to-ref-pre"] timeout: "480 minutes" variables: # keep "mld" in artifact name for backwards compatibility reasons @@ -267,6 +279,7 @@ workflow: - else - testcase_timeout=$TESTCASE_TIMEOUT_STV - fi + - FLOAT_REF_COMMIT=$(cat "$FLOAT_REF_COMMIT_FILE") - python3 ci/remove_unsupported_testcases.py $PRM_FILES - if [ $LEVEL_SCALING != "1.0" ]; then @@ -913,6 +926,22 @@ clang-format-check: name: "$ARTIFACT_BASE_NAME" expose_as: "formatting patch" + +# This job runs in manual jobs and scheduled jobs that compares to the float reference. +# It fetches the latest commit of ivas-float-update and stores in FLOAT_COMMIT_REF +pytest-to-ref-pre: + extends: + - .job-linux + - .rules-pytest-to-ref-pre + script: + - git fetch origin ivas-float-update + - FLOAT_REF_COMMIT="$(git rev-parse "origin/ivas-float-update")" + - echo "$FLOAT_REF_COMMIT" > $FLOAT_REF_COMMIT_FILE + artifacts: + paths: + - $FLOAT_REF_COMMIT_FILE + reports: + dotenv: commits.env # --------------------------------------------------------------- # Build jobs # --------------------------------------------------------------- -- GitLab From ee51183f818554261e01d19d6bcf31466fd72f43 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Wed, 1 Oct 2025 09:19:38 +0200 Subject: [PATCH 2/4] Change stage of pre-job --- main-basop.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/main-basop.yml b/main-basop.yml index 8054d96..8de599b 100644 --- a/main-basop.yml +++ b/main-basop.yml @@ -933,6 +933,7 @@ pytest-to-ref-pre: extends: - .job-linux - .rules-pytest-to-ref-pre + stage: prevalidate script: - git fetch origin ivas-float-update - FLOAT_REF_COMMIT="$(git rev-parse "origin/ivas-float-update")" -- GitLab From 4762ecdb08660b0dd5a8cc7c00c419a567dfac59 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Wed, 1 Oct 2025 12:27:42 +0200 Subject: [PATCH 3/4] Simplify .rules-pytest-to-ref-pre, and printout of pinned FLOAT_REF_COMMIT, add comment to ivas-pytest-anchor --- main-basop.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/main-basop.yml b/main-basop.yml index 8de599b..de4124b 100644 --- a/main-basop.yml +++ b/main-basop.yml @@ -149,9 +149,6 @@ workflow: .rules-pytest-to-ref-pre: rules: - - if: $PYTEST_MLD_SHORT - - if: $PYTEST_MLD_LONG - - if: $PYTEST_MLD_LONG_FX_FX - if: $CI_PIPELINE_SOURCE == 'web' - if: $CI_PIPELINE_SOURCE == 'schedule' - if: $CI_PIPELINE_SOURCE == 'push' @@ -252,6 +249,7 @@ workflow: - if [ ! -d "$TESTV_DIR" ]; then mkdir -p $TESTV_DIR; fi - cp -r scripts/testv/* $TESTV_DIR/ +# This anchor is the basis for manual and scheduled tests .ivas-pytest-anchor: &ivas-pytest-anchor stage: test needs: ["build-codec-linux-make", "pytest-to-ref-pre"] @@ -280,6 +278,7 @@ workflow: - testcase_timeout=$TESTCASE_TIMEOUT_STV - fi - FLOAT_REF_COMMIT=$(cat "$FLOAT_REF_COMMIT_FILE") + - echo "FLOAT_REF_COMMIT=$FLOAT_REF_COMMIT" - python3 ci/remove_unsupported_testcases.py $PRM_FILES - if [ $LEVEL_SCALING != "1.0" ]; then -- GitLab From bc661ff2c041882c0f00b7254a5370d8cd4c1f42 Mon Sep 17 00:00:00 2001 From: Erik Norvell Date: Wed, 1 Oct 2025 12:29:37 +0200 Subject: [PATCH 4/4] Improve comment for ivas-pytest-anchor --- main-basop.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/main-basop.yml b/main-basop.yml index de4124b..fbdd085 100644 --- a/main-basop.yml +++ b/main-basop.yml @@ -249,7 +249,7 @@ workflow: - if [ ! -d "$TESTV_DIR" ]; then mkdir -p $TESTV_DIR; fi - cp -r scripts/testv/* $TESTV_DIR/ -# This anchor is the basis for manual and scheduled tests +# This anchor is the basis for manual and scheduled tests comparing to float ref (ivas-float-update) .ivas-pytest-anchor: &ivas-pytest-anchor stage: test needs: ["build-codec-linux-make", "pytest-to-ref-pre"] -- GitLab