diff --git a/.gitlab-ci/cva6.yml b/.gitlab-ci/cva6.yml index 93dcf82ca5..fc44c8513f 100644 --- a/.gitlab-ci/cva6.yml +++ b/.gitlab-ci/cva6.yml @@ -71,6 +71,7 @@ stages: - smoke tests - verif tests - backend tests + - find failures - report .verif_test: @@ -603,6 +604,24 @@ code_coverage-report: artifacts: expire_in: 3 week +check gitlab jobs status: + stage: find failures + tags: [$TAGS_RUNNER] + rules: + - if: '$DASHBOARD_URL' + when: on_failure + - when: never + variables: + DASHBOARD_JOB_TITLE: "Environment check" + DASHBOARD_JOB_DESCRIPTION: "Detect environment issues" + DASHBOARD_SORT_INDEX: 0 + DASHBOARD_JOB_CATEGORY: "Environment" + script: + - rm -rf artifacts/ + - mkdir -p artifacts/reports + - python3 .gitlab-ci/scripts/report_envfail.py + artifacts: *artifacts + merge reports: stage: report tags: [$TAGS_RUNNER] diff --git a/.gitlab-ci/scripts/report_envfail.py b/.gitlab-ci/scripts/report_envfail.py new file mode 100644 index 0000000000..7049bcddc4 --- /dev/null +++ b/.gitlab-ci/scripts/report_envfail.py @@ -0,0 +1,17 @@ +# Copyright 2023 Thales Silicon Security +# +# Licensed under the Solderpad Hardware Licence, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# SPDX-License-Identifier: Apache-2.0 WITH SHL-2.0 +# You may obtain a copy of the License at https://solderpad.org/licenses/ +# +# Original Author: Côme ALLART - Thales + +import report_builder as rb + +metric = rb.TableStatusMetric('') +metric.add_fail('Environment failure detected. Some reports might be missing') + +report = rb.Report() +report.add_metric(metric) +report.dump()