]> granicus.if.org Git - python/commitdiff
Split the refleak mail body into two parts, the first being those failing
authorSkip Montanaro <skip@pobox.com>
Sat, 2 Feb 2008 19:11:57 +0000 (19:11 +0000)
committerSkip Montanaro <skip@pobox.com>
Sat, 2 Feb 2008 19:11:57 +0000 (19:11 +0000)
tests which are deemed more important issues, the second those which are
known to have difficult to solve problems and are generally expected to
leak.  Hopefully this doesn't break the script...

Misc/build.sh

index d6b18f0e0f3470ffa9b30fbd01d9c65bdc2d162d..bbce0723e613be94c473e59059a11bc54ac43e3b 100755 (executable)
@@ -97,7 +97,17 @@ mail_on_failure() {
         if [ "$FAILURE_CC" != "" ]; then
             dest="$dest -c $FAILURE_CC"
         fi
-        mutt -s "$FAILURE_SUBJECT $1 ($NUM_FAILURES)" $dest < $2
+       if [ "x$3" != "x" ] ; then
+           (echo "More important issues:"
+            echo "----------------------"
+            egrep -v "$3" < $2
+            echo ""
+            echo "Less important issues:"
+            echo "----------------------"
+            egrep "$3" < $2)
+        else
+           cat $2
+       fi | mutt -s "$FAILURE_SUBJECT $1 ($NUM_FAILURES)" $dest
     fi
 }
 
@@ -192,9 +202,10 @@ if [ $err = 0 -a "$BUILD_DISABLED" != "yes" ]; then
             ## ensure that the reflog exists so the grep doesn't fail
             touch $REFLOG
             $PYTHON $REGRTEST_ARGS -R 4:3:$REFLOG -u network $LEAKY_SKIPS >& build/$F
-            NUM_FAILURES=`egrep -vc "($LEAKY_TESTS|sum=0)" $REFLOG`
+           LEAK_PAT="($LEAKY_TESTS|sum=0)"
+            NUM_FAILURES=`egrep -vc "$LEAK_PAT" $REFLOG`
             update_status "Testing refleaks ($NUM_FAILURES failures)" "$F" $start
-            mail_on_failure "refleak" $REFLOG
+            mail_on_failure "refleak" $REFLOG "$LEAK_PAT"
 
             ## now try to run all the tests
             F=make-testall.out