diff options
author | kwryankrattiger <80296582+kwryankrattiger@users.noreply.github.com> | 2024-04-05 14:00:27 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-04-05 14:00:27 -0500 |
commit | c68d739825c63f50f691b11c4a824e0dbaf59b6d (patch) | |
tree | 93378e17b22f6d9a8f590aa059b4ec72b0a58f47 | |
parent | c468697b354a47af3dfa855ee1746445f7cdedf0 (diff) | |
download | spack-c68d739825c63f50f691b11c4a824e0dbaf59b6d.tar.gz spack-c68d739825c63f50f691b11c4a824e0dbaf59b6d.tar.bz2 spack-c68d739825c63f50f691b11c4a824e0dbaf59b6d.tar.xz spack-c68d739825c63f50f691b11c4a824e0dbaf59b6d.zip |
CI: Add debug to the log aggregation script (#42562)
* CI: Add debug to the log aggregation script
-rw-r--r-- | share/spack/gitlab/cloud_pipelines/configs/ci.yaml | 8 | ||||
-rw-r--r-- | share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py | 6 |
2 files changed, 9 insertions, 5 deletions
diff --git a/share/spack/gitlab/cloud_pipelines/configs/ci.yaml b/share/spack/gitlab/cloud_pipelines/configs/ci.yaml index 2d1e18836d..715992ea0c 100644 --- a/share/spack/gitlab/cloud_pipelines/configs/ci.yaml +++ b/share/spack/gitlab/cloud_pipelines/configs/ci.yaml @@ -27,12 +27,12 @@ ci: - - spack config blame mirrors - spack --color=always --backtrace ci rebuild --tests > >(tee ${SPACK_ARTIFACTS_ROOT}/user_data/pipeline_out.txt) 2> >(tee ${SPACK_ARTIFACTS_ROOT}/user_data/pipeline_err.txt >&2) after_script: - - - ./bin/spack python ${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py - --prefix /home/software/spack:${CI_PROJECT_DIR}/opt/spack - --log install_times.json - ${SPACK_ARTIFACTS_ROOT}/user_data/install_times.json - - cat /proc/loadavg || true - cat /proc/meminfo | grep 'MemTotal\|MemFree' || true + - - time python ${CI_PROJECT_DIR}/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py + --prefix /home/software/spack:${CI_PROJECT_DIR}/opt/spack + --log install_times.json + ${SPACK_ARTIFACTS_ROOT}/user_data/install_times.json || true variables: CI_JOB_SIZE: "default" CI_GPG_KEY_ROOT: /mnt/key diff --git a/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py b/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py index ec40c4c230..d27d1656ba 100644 --- a/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py +++ b/share/spack/gitlab/cloud_pipelines/scripts/common/aggregate_package_logs.spack.py @@ -37,10 +37,14 @@ if __name__ == "__main__": # Look in the list of prefixes for logs for prefix in prefixes: - logs = find_logs(prefix, args.log) + print(f"Walking {prefix}") + logs = [log for log in find_logs(prefix, args.log)] + print(f" * found {len(logs)} logs") for log in logs: + print(f" * appending data for {log}") with open(log) as fd: data.append(json.load(fd)) + print(f"Writing {args.output_file}") with open(args.output_file, "w") as fd: json.dump(data, fd) |