Skip to content

24.3.12 test crossout, automated report and grype scans #670

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 26 commits into from
Apr 24, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
91ce688
a universal approach to crossing out failed tests
strtgbb Oct 30, 2024
8405250
handle known broken tests in process_functional_tests_result.py
strtgbb Oct 31, 2024
08463a4
remove broken test handling from report.py
strtgbb Oct 31, 2024
e0738a5
add broken test handling back to integration_tests_runner.py
strtgbb Oct 31, 2024
d4de139
update broken_tests.json
strtgbb Oct 31, 2024
293ea8b
update broken_tests.json
strtgbb Nov 8, 2024
7ed2719
update hdfs image
strtgbb Nov 14, 2024
7fa57c3
fix stateless test crossout
strtgbb Nov 20, 2024
ee493a9
update broken tests list with upstream fails
strtgbb Mar 3, 2025
3b136bc
Adding automated report
strtgbb Mar 3, 2025
23e1874
fix workflow error
strtgbb Mar 3, 2025
eb4a332
Always run finishcheck
strtgbb Mar 4, 2025
336b35b
fix extra space in broken test name
strtgbb Mar 4, 2025
16f0806
fix find and replace
strtgbb Mar 5, 2025
e0b41af
update regression hash
strtgbb Mar 14, 2025
5e51ba2
Merge branch 'customizations/24.3.12' into 24.3.12_test_crossout_and_…
strtgbb Apr 16, 2025
c682858
add grype scan
strtgbb Apr 16, 2025
4577900
update report to new format
strtgbb Apr 16, 2025
c12ca0e
fix 'cannot specify version when calling local workflows'
strtgbb Apr 16, 2025
00c6311
Merge branch 'customizations/24.3.12' into 24.3.12_test_crossout_and_…
strtgbb Apr 17, 2025
9f27dca
add missing GITHUB_TOKEN
strtgbb Apr 17, 2025
3775562
Add matrix values to job name attr in regression
strtgbb Apr 18, 2025
cd66e5e
Don't halt on suspicious, but not sensitive, strings. Too many false …
strtgbb Apr 18, 2025
473961a
support pagination to fix missing CI jobs status
strtgbb Apr 19, 2025
70d617a
try to fix branch filter
strtgbb Apr 22, 2025
e391aa9
fix usage of GITHUB_REPO in report generation
strtgbb Apr 24, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
653 changes: 653 additions & 0 deletions .github/create_workflow_report.py

Large diffs are not rendered by default.

32 changes: 32 additions & 0 deletions .github/grype/parse_vulnerabilities_grype.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
#!/usr/bin/env python3
import json

from testflows.core import *

xfails = {}


@Name("docker vulnerabilities")
@XFails(xfails)
@TestModule
def docker_vulnerabilities(self):
with Given("I gather grype scan results"):
with open("./result.json", "r") as f:
results = json.load(f)

for vulnerability in results["matches"]:
with Test(
f"{vulnerability['vulnerability']['id']}@{vulnerability['vulnerability']['namespace']},{vulnerability['vulnerability']['severity']}",
flags=TE,
):
note(vulnerability)
critical_levels = set(["HIGH", "CRITICAL"])
if vulnerability['vulnerability']["severity"].upper() in critical_levels:
with Then(
f"Found vulnerability of {vulnerability['vulnerability']['severity']} severity"
):
result(Fail)


if main():
docker_vulnerabilities()
18 changes: 18 additions & 0 deletions .github/grype/run_grype_scan.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
set -x
set -e

IMAGE=$1

GRYPE_VERSION="v0.80.1"

docker pull $IMAGE
docker pull anchore/grype:${GRYPE_VERSION}

docker run \
--rm --volume /var/run/docker.sock:/var/run/docker.sock \
--name Grype anchore/grype:${GRYPE_VERSION} \
--scope all-layers \
-o json \
$IMAGE > result.json

ls -sh
13 changes: 13 additions & 0 deletions .github/grype/transform_and_upload_results_s3.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
DOCKER_IMAGE=$(echo "$DOCKER_IMAGE" | sed 's/[\/:]/_/g')

S3_PATH="s3://$S3_BUCKET/$PR_NUMBER/$COMMIT_SHA/grype/$DOCKER_IMAGE"
HTTPS_S3_PATH="https://s3.amazonaws.com/$S3_BUCKET/$PR_NUMBER/$COMMIT_SHA/grype/$DOCKER_IMAGE"
echo "https_s3_path=$HTTPS_S3_PATH" >> $GITHUB_OUTPUT

tfs --no-colors transform nice raw.log nice.log.txt
tfs --no-colors report results -a $HTTPS_S3_PATH raw.log - --copyright "Altinity LTD" | tfs --no-colors document convert > results.html

aws s3 cp --no-progress nice.log.txt $S3_PATH/nice.log.txt --content-type "text/plain; charset=utf-8" || echo "nice log file not found".
aws s3 cp --no-progress results.html $S3_PATH/results.html || echo "results file not found".
aws s3 cp --no-progress raw.log $S3_PATH/raw.log || echo "raw.log file not found".
aws s3 cp --no-progress result.json $S3_PATH/result.json --content-type "text/plain; charset=utf-8" || echo "result.json not found".
131 changes: 131 additions & 0 deletions .github/workflows/grype_scan.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,131 @@
name: Grype Scan
run-name: Grype Scan ${{ inputs.docker_image }}

on:
workflow_dispatch:
# Inputs for manual run
inputs:
docker_image:
description: 'Docker image. If no tag, it will be determined by version_helper.py'
required: true
workflow_call:
# Inputs for workflow call
inputs:
docker_image:
description: 'Docker image. If no tag, it will be determined by version_helper.py'
required: true
type: string
env:
PYTHONUNBUFFERED: 1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}

jobs:
grype_scan:
name: Grype Scan
runs-on: [self-hosted, altinity-on-demand, altinity-func-tester-aarch64]
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Set up Docker
uses: docker/setup-buildx-action@v3

- name: Set up Python
run: |
export TESTFLOWS_VERSION="2.4.19"
sudo apt-get update
sudo apt-get install -y python3-pip python3-venv
python3 -m venv venv
source venv/bin/activate
pip install --upgrade requests chardet urllib3
pip install testflows==$TESTFLOWS_VERSION awscli==1.33.28
echo PATH=$PATH >>$GITHUB_ENV

- name: Set image tag if not given
if: ${{ !contains(inputs.docker_image, ':') }}
id: set_version
run: |
python3 ./tests/ci/version_helper.py | tee /tmp/version_info
source /tmp/version_info
echo "docker_image=${{ inputs.docker_image }}:${{ github.event.pull_request.number || 0 }}-$CLICKHOUSE_VERSION_STRING" >> $GITHUB_OUTPUT
echo "commit_sha=$CLICKHOUSE_VERSION_GITHASH" >> $GITHUB_OUTPUT

- name: Run Grype Scan
run: |
DOCKER_IMAGE=${{ steps.set_version.outputs.docker_image || inputs.docker_image }}
./.github/grype/run_grype_scan.sh $DOCKER_IMAGE

- name: Parse grype results
run: |
python3 -u ./.github/grype/parse_vulnerabilities_grype.py -o nice --no-colors --log raw.log --test-to-end

- name: Transform and Upload Grype Results
if: always()
id: upload_results
env:
S3_BUCKET: "altinity-build-artifacts"
COMMIT_SHA: ${{ steps.set_version.outputs.commit_sha || github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
PR_NUMBER: ${{ github.event.pull_request.number || 0 }}
DOCKER_IMAGE: ${{ steps.set_version.outputs.docker_image || inputs.docker_image }}
run: |
./.github/grype/transform_and_upload_results_s3.sh

- name: Create step summary
if: always()
id: create_summary
run: |
jq -r '.distro | "**Distro**: \(.name):\(.version)"' result.json >> $GITHUB_STEP_SUMMARY
if jq -e '.matches | length == 0' result.json > /dev/null; then
echo "No CVEs" >> $GITHUB_STEP_SUMMARY
else
echo "| Severity | Count |" >> $GITHUB_STEP_SUMMARY
echo "|------------|-------|" >> $GITHUB_STEP_SUMMARY
jq -r '
.matches |
map(.vulnerability.severity) |
group_by(.) |
map({severity: .[0], count: length}) |
sort_by(.severity) |
map("| \(.severity) | \(.count) |") |
.[]
' result.json >> $GITHUB_STEP_SUMMARY
fi

HIGH_COUNT=$(jq -r '.matches | map(.vulnerability.severity) | map(select(. == "High")) | length' result.json)
CRITICAL_COUNT=$(jq -r '.matches | map(.vulnerability.severity) | map(select(. == "Critical")) | length' result.json)
TOTAL_HIGH_CRITICAL=$((HIGH_COUNT + CRITICAL_COUNT))
echo "total_high_critical=$TOTAL_HIGH_CRITICAL" >> $GITHUB_OUTPUT

if [ $TOTAL_HIGH_CRITICAL -gt 0 ]; then
echo '## High and Critical vulnerabilities found' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
cat raw.log | tfs --no-colors show tests | grep -Pi 'High|Critical' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
fi

- name: Set commit status
if: always()
uses: actions/github-script@v7
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
github.rest.repos.createCommitStatus({
owner: context.repo.owner,
repo: context.repo.repo,
sha: '${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}',
state: '${{ steps.create_summary.outputs.total_high_critical > 0 && 'failure' || 'success' }}',
target_url: '${{ steps.upload_results.outputs.https_s3_path }}/results.html',
description: 'Grype Scan Completed with ${{ steps.create_summary.outputs.total_high_critical }} high/critical vulnerabilities',
context: 'Grype Scan ${{ steps.set_version.outputs.docker_image || inputs.docker_image }}'
})

- name: Upload artifacts
if: always()
uses: actions/upload-artifact@v4
with:
name: grype-results-${{ hashFiles('raw.log') }}
path: |
result.json
nice.log.txt
14 changes: 7 additions & 7 deletions .github/workflows/regression.yml
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ jobs:
python3
-u ${{ env.SUITE }}/regression.py
--clickhouse-binary-path ${{ env.clickhouse_path }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.SUITE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -243,7 +243,7 @@ jobs:
-u alter/regression.py
--clickhouse-binary-path ${{ env.clickhouse_path }}
--only "/alter/${{ matrix.ONLY }} partition/*"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.ONLY }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -314,7 +314,7 @@ jobs:
--aws-s3-region ${{ secrets.REGRESSION_AWS_S3_REGION }}
--aws-s3-key-id ${{ secrets.REGRESSION_AWS_S3_KEY_ID }}
--aws-s3-access-key ${{ secrets.REGRESSION_AWS_S3_SECRET_ACCESS_KEY }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.STORAGE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -436,7 +436,7 @@ jobs:
python3
-u ${{ env.SUITE }}/regression.py
--clickhouse-binary-path ${{ env.clickhouse_path }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.SUITE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -562,7 +562,7 @@ jobs:
--aws-s3-region ${{ secrets.REGRESSION_AWS_S3_REGION }}
--aws-s3-key-id ${{ secrets.REGRESSION_AWS_S3_KEY_ID }}
--aws-s3-access-key ${{ secrets.REGRESSION_AWS_S3_SECRET_ACCESS_KEY }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.STORAGE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -633,7 +633,7 @@ jobs:
--aws-s3-region ${{ secrets.REGRESSION_AWS_S3_REGION }}
--aws-s3-key-id ${{ secrets.REGRESSION_AWS_S3_KEY_ID }}
--aws-s3-access-key ${{ secrets.REGRESSION_AWS_S3_SECRET_ACCESS_KEY }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.STORAGE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down Expand Up @@ -703,7 +703,7 @@ jobs:
--gcs-key-secret ${{ secrets.REGRESSION_GCS_KEY_SECRET }}
--gcs-uri ${{ secrets.REGRESSION_GCS_URI }}
--with-${{ matrix.STORAGE }}
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name=$GITHUB_JOB job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
--attr project="$GITHUB_REPOSITORY" project.id="$GITHUB_REPOSITORY_ID" package="${{ env.clickhouse_path }}" version="${{ env.version }}" user.name="$GITHUB_ACTOR" repository="https://github.com/Altinity/clickhouse-regression" commit.hash="$(git rev-parse HEAD)" job.name="$GITHUB_JOB (${{ matrix.STORAGE }})" job.retry=$GITHUB_RUN_ATTEMPT job.url="$GITHUB_SERVER_URL/$GITHUB_REPOSITORY/actions/runs/$GITHUB_RUN_ID" arch="$(uname -i)"
${{ env.args }} || EXITCODE=$?;
.github/add_link_to_logs.sh;
exit $EXITCODE
Expand Down
48 changes: 44 additions & 4 deletions .github/workflows/release_branches.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ on: # yamllint disable-line rule:truthy
- prereleased
push:
branches:
- '**/24.3*'
- 'releases/24.3*'
- 'customizations/24.3*'
tags:
- '*'
workflow_dispatch:
Expand Down Expand Up @@ -170,6 +171,23 @@ jobs:
test_name: Docker keeper image
runner_type: altinity-func-tester
data: ${{ needs.RunConfig.outputs.data }}
GrypeScan:
needs: [RunConfig, DockerServerImage, DockerKeeperImage]
if: ${{ !failure() && !cancelled() }}
strategy:
fail-fast: false
matrix:
include:
- image: server
suffix: ''
- image: server
suffix: '-alpine'
- image: keeper
suffix: ''
uses: ./.github/workflows/grype_scan.yml
secrets: inherit
with:
docker_image: altinityinfra/clickhouse-${{ matrix.image }}:${{ github.event.pull_request.number || 0 }}-${{ fromJson(needs.RunConfig.outputs.data).version }}${{ matrix.suffix }}
############################################################################################
##################################### BUILD REPORTER #######################################
############################################################################################
Expand Down Expand Up @@ -474,7 +492,7 @@ jobs:
secrets: inherit
with:
runner_type: altinity-type-cpx51, altinity-image-x86-app-docker-ce, altinity-setup-regression
commit: a170f32119a5c872e5ff209b8f39e13acc2d6626
commit: 0fdb555b36d0ea6a6affc5cf87e593b5d8944c0a
arch: release
build_sha: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
timeout_minutes: 300
Expand All @@ -485,7 +503,7 @@ jobs:
secrets: inherit
with:
runner_type: altinity-type-cax41, altinity-image-arm-app-docker-ce, altinity-setup-regression
commit: a170f32119a5c872e5ff209b8f39e13acc2d6626
commit: 0fdb555b36d0ea6a6affc5cf87e593b5d8944c0a
arch: aarch64
build_sha: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
timeout_minutes: 300
Expand All @@ -508,7 +526,7 @@ jobs:
runner_type: altinity-style-checker-aarch64
data: ${{ needs.RunConfig.outputs.data }}
FinishCheck:
if: ${{ !failure() && !cancelled() }}
if: ${{ !cancelled() }}
needs:
- DockerServerImage
- DockerKeeperImage
Expand Down Expand Up @@ -551,3 +569,25 @@ jobs:
run: |
cd "$GITHUB_WORKSPACE/tests/ci"
python3 finish_check.py
- name: Create and upload combined report
env:
CHECKS_DATABASE_HOST: ${{ secrets.CHECKS_DATABASE_HOST }}
CHECKS_DATABASE_USER: ${{ secrets.CHECKS_DATABASE_USER }}
CHECKS_DATABASE_PASSWORD: ${{ secrets.CHECKS_DATABASE_PASSWORD }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMMIT_SHA: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
PR_NUMBER: ${{ github.event.pull_request.number || 0 }}
ACTIONS_RUN_URL: ${{ github.event.repository.html_url }}/actions/runs/${{ github.run_id }}
shell: bash
run: |
pip install clickhouse-driver==0.2.8 numpy==1.26.4 pandas==2.0.3

REPORT_LINK=$(python3 .github/create_workflow_report.py --pr-number $PR_NUMBER --commit-sha $COMMIT_SHA --actions-run-url $ACTIONS_RUN_URL --known-fails tests/broken_tests.json --cves)

IS_VALID_URL=$(echo $REPORT_LINK | grep -E '^https?://')
if [[ -n $IS_VALID_URL ]]; then
echo "Combined CI Report: [View Report]($REPORT_LINK)" >> $GITHUB_STEP_SUMMARY
else
echo "Error: $REPORT_LINK" >> $GITHUB_STEP_SUMMARY
exit 1
fi
Loading
Loading