Merge pull request #67791 from azat/ci/stateless-v2

ci/stateless: fix artifacts post-processing and detect if something failed there
This commit is contained in:
Alexey Milovidov 2024-08-05 14:46:58 +00:00 committed by GitHub
commit a416d2bc4a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 7 additions and 4 deletions

View File

@ -397,6 +397,8 @@ do
| zstd --threads=0 > "/test_output/trace-log-$trace_type-flamegraph.tsv.zst" ||:
done
# Grep logs for sanitizer asserts, crashes and other critical errors
check_logs_for_critical_errors
# Compressed (FIXME: remove once only github actions will be left)
rm /var/log/clickhouse-server/clickhouse-server.log
@ -430,7 +432,4 @@ if [[ "$USE_SHARED_CATALOG" -eq 1 ]]; then
tar -chf /test_output/coordination1.tar /var/lib/clickhouse1/coordination ||:
fi
# Grep logs for sanitizer asserts, crashes and other critical errors
check_logs_for_critical_errors
collect_core_dumps

View File

@ -166,6 +166,7 @@ def _get_statless_tests_to_run(pr_info: PRInfo) -> List[str]:
def process_results(
ret_code: int,
result_directory: Path,
server_log_path: Path,
) -> Tuple[StatusType, str, TestResults, List[Path]]:
@ -192,6 +193,9 @@ def process_results(
logging.info("Files in result folder %s", os.listdir(result_directory))
return ERROR, "Invalid check_status.tsv", test_results, additional_files
state, description = status[0][0], status[0][1]
if ret_code != 0:
state = ERROR
description += " (but script exited with an error)"
try:
results_path = result_directory / "test_results.tsv"
@ -339,7 +343,7 @@ def main():
ci_logs_credentials.clean_ci_logs_from_credentials(run_log_path)
state, description, test_results, additional_logs = process_results(
result_path, server_log_path
retcode, result_path, server_log_path
)
else:
print(