Cat the failed tox-envs 53/7153/3
authorThanh Ha <thanh.ha@linuxfoundation.org>
Mon, 30 Oct 2017 15:50:18 +0000 (11:50 -0400)
committerThanh Ha <thanh.ha@linuxfoundation.org>
Mon, 30 Oct 2017 16:02:46 +0000 (12:02 -0400)
Before failing the build we should print the problematic tox
environments into the console to make it easier for folks to
troubleshoot. We are still archiving the individual tox runs but the
console logs will now also contain the errors.

Issue: RELENG-611
Change-Id: Ie6fd132c0de69e8448d320d23daaed811a0d47a1
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
.jjb-test/expected-xml/gerrit-python-tox-verify-master
.jjb-test/expected-xml/github-python-tox-verify-master
shell/tox-run.sh

index 508a4f9..7fe44e7 100644 (file)
@@ -352,6 +352,10 @@ fi
 
 if [ -f &quot;$ARCHIVE_TOX_DIR/failed-envs.log&quot; ]; then
     failed_envs=($(cat &quot;$ARCHIVE_TOX_DIR/failed-envs.log&quot;))
+    for e in &quot;${failed_envs[@]}&quot;; do
+        echo &quot;cat $ARCHIVE_TOX_DIR/tox-$e.log&quot;
+        cat &quot;$ARCHIVE_TOX_DIR/tox-$e.log&quot;
+    done
     echo &quot;ERROR: Failed the following builds: ${failed_envs[*]}&quot;
     exit 1
 fi
index b701917..a60bb79 100644 (file)
@@ -314,6 +314,10 @@ fi
 
 if [ -f &quot;$ARCHIVE_TOX_DIR/failed-envs.log&quot; ]; then
     failed_envs=($(cat &quot;$ARCHIVE_TOX_DIR/failed-envs.log&quot;))
+    for e in &quot;${failed_envs[@]}&quot;; do
+        echo &quot;cat $ARCHIVE_TOX_DIR/tox-$e.log&quot;
+        cat &quot;$ARCHIVE_TOX_DIR/tox-$e.log&quot;
+    done
     echo &quot;ERROR: Failed the following builds: ${failed_envs[*]}&quot;
     exit 1
 fi
index 3bf1576..45cb1f2 100644 (file)
@@ -49,6 +49,10 @@ fi
 
 if [ -f "$ARCHIVE_TOX_DIR/failed-envs.log" ]; then
     failed_envs=($(cat "$ARCHIVE_TOX_DIR/failed-envs.log"))
+    for e in "${failed_envs[@]}"; do
+        echo "cat $ARCHIVE_TOX_DIR/tox-$e.log"
+        cat "$ARCHIVE_TOX_DIR/tox-$e.log"
+    done
     echo "ERROR: Failed the following builds: ${failed_envs[*]}"
     exit 1
 fi