adjust CI timeout, use TIMEOUT variable for setting fuzzers timeout

This commit is contained in:
Yakov Olkhovskiy 2024-11-04 03:13:42 +00:00
parent efd8ea7757
commit 5aba66e50a
4 changed files with 6 additions and 9 deletions

View File

@ -33,8 +33,6 @@ RUN apt-get update \
COPY requirements.txt /
RUN pip3 install --no-cache-dir -r /requirements.txt
ENV FUZZER_ARGS="-max_total_time=60"
SHELL ["/bin/bash", "-c"]
# docker run --network=host --volume <workspace>:/workspace -e PR_TO_TEST=<> -e SHA_TO_TEST=<> clickhouse/libfuzzer

View File

@ -530,7 +530,7 @@ class CI:
JobNames.LIBFUZZER_TEST: JobConfig(
required_builds=[BuildNames.FUZZERS],
run_by_labels=[Tags.libFuzzer],
timeout=10800,
timeout=5400,
run_command='libfuzzer_test_check.py "$CHECK_NAME"',
runner_type=Runners.FUNC_TESTER,
),

View File

@ -22,6 +22,7 @@ from stopwatch import Stopwatch
from tee_popen import TeePopen
NO_CHANGES_MSG = "Nothing to run"
TIMEOUT = 60
s3 = S3Helper()
@ -264,6 +265,8 @@ def main():
check_name, run_by_hash_num, run_by_hash_total
)
additional_envs.append(f"TIMEOUT={TIMEOUT}")
ci_logs_credentials = CiLogsCredentials(Path(temp_path) / "export-logs-config.sh")
ci_logs_args = ci_logs_credentials.get_docker_arguments(
pr_info, stopwatch.start_time_str, check_name

View File

@ -9,7 +9,7 @@ import subprocess
from pathlib import Path
DEBUGGER = os.getenv("DEBUGGER", "")
FUZZER_ARGS = os.getenv("FUZZER_ARGS", "")
TIMEOUT = int(os.getenv("TIMEOUT", "0"))
OUTPUT = "/test_output"
@ -150,11 +150,7 @@ def main():
subprocess.check_call("ls -al", shell=True)
timeout = 60
match = re.search(r"(^|\s+)-max_total_time=(\d+)($|\s)", FUZZER_ARGS)
if match:
timeout = int(match.group(2))
timeout = 30 if TIMEOUT == 0 else TIMEOUT
with Path() as current:
for fuzzer in current.iterdir():