From 5b90789fb804eeab21b1bd0b16630de4c7c2efa5 Mon Sep 17 00:00:00 2001 From: Marshall Ward Date: Fri, 12 Aug 2022 14:41:24 -0400 Subject: [PATCH] Report error logs from codecov upload fail This patch extends the REPORT_ERROR_LOGS flag behavior to also report the error log of failed codecov uploads. I expect there's little we can do on our end, but more information will at least help to understand the problem. --- .testing/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.testing/Makefile b/.testing/Makefile index 917feb311b..257992e14d 100644 --- a/.testing/Makefile +++ b/.testing/Makefile @@ -602,6 +602,9 @@ report.cov: run.cov codecov 2> build/cov/codecov.err \ && echo -e "${MAGENTA}Report uploaded to codecov.${RESET}" \ || { \ + if [ "$(REPORT_ERROR_LOGS)" = true ]; then \ + cat build/cov/codecov.err ; \ + fi ; \ echo -e "${RED}Failed to upload report.${RESET}" ; \ if [ "$(REQUIRE_COVERAGE_UPLOAD)" = true ] ; then false ; fi ; \ } @@ -740,6 +743,9 @@ report.cov.unit: build/unit/MOM_file_parser_tests.F90.gcov codecov 2> build/unit/codecov.err \ && echo -e "${MAGENTA}Report uploaded to codecov.${RESET}" \ || { \ + if [ "$(REPORT_ERROR_LOGS)" = true ]; then \ + cat build/unit/codecov.err ; \ + fi ; \ echo -e "${RED}Failed to upload report.${RESET}" ; \ if [ "$(REQUIRE_COVERAGE_UPLOAD)" = true ] ; then false ; fi ; \ }