From 1499cd557b2759b234504676e4275f467da7ad1a Mon Sep 17 00:00:00 2001
From: Holger Levsen
"
+ local ARCH
+ write_page " "
- AGE_UNSTABLE=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='unstable' AND architecture='$ARCH' AND datum='$DATE'")
- AGE_EXPERIMENTAL=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='experimental' AND architecture='$ARCH' AND datum='$DATE'")
- if [ "$ARCH" != "armhf" ] ; then
- AGE_TESTING=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='testing' AND architecture='$ARCH' AND datum='$DATE'")
- write_page "Build statistics for $ARCH "
- else
- write_page "oldest $ARCH build result in testing / unstable / experimental $AGE_TESTING / $AGE_UNSTABLE / $AGE_EXPERIMENTAL days "
- fi
- RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(AVG(r.build_duration) AS INTEGER) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_duration!='' AND r.build_duration!='0' AND r.build_date LIKE '%$DATE%' AND s.architecture='$ARCH'")
- MIN=$(echo $RESULT/60|bc)
- SEC=$(echo "$RESULT-($MIN*60)"|bc)
- write_page "oldest $ARCH build result in unstable / experimental $AGE_UNSTABLE / $AGE_EXPERIMENTAL days "
- RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(AVG(r.build_duration) AS INTEGER) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_duration!='' AND r.build_duration!='0' AND r.build_date > datetime('$DATE', '-$TIMESPAN_RAW days') AND s.architecture='$ARCH'")
- MIN=$(echo $RESULT/60|bc)
- SEC=$(echo "$RESULT-($MIN*60)"|bc)
- write_page "average test duration (on $DATE) $MIN minutes, $SEC seconds "
- RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT COUNT(r.build_date) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_date LIKE '%$DATE%' AND s.architecture='$ARCH'")
- write_page "average test duration (in the last $TIMESPAN_VERBOSE) $MIN minutes, $SEC seconds "
- RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT COUNT(r.build_date) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_date > datetime('$DATE', '-$TIMESPAN_RAW days') AND s.architecture='$ARCH'")
- RESULT="$(echo $RESULT/$TIMESPAN_RAW|bc)"
- write_page "packages tested on $DATE $RESULT "
- write_page "packages tested on average per day in the last $TIMESPAN_VERBOSE $RESULT
"
}
#
@@ -472,9 +487,6 @@ create_dashboard_page() {
write_page "Architecture statistics "
+ for ARCH in ${ARCHS} ; do
+ write_page " $ARCH "
+ done
+ write_page "oldest build result in testing / unstable / experimental "
+ for ARCH in ${ARCHS} ; do
+ PERF_STATS[$ARCH]=$(mktemp -t reproducible-dashboard-perf-XXXXXXXX)
+ AGE_UNSTABLE=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='unstable' AND architecture='$ARCH' AND datum='$DATE'")
+ AGE_EXPERIMENTAL=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='experimental' AND architecture='$ARCH' AND datum='$DATE'")
+ if [ "$ARCH" != "armhf" ] ; then
+ AGE_TESTING=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(max(oldest_reproducible, oldest_unreproducible, oldest_FTBFS) AS INTEGER) FROM ${TABLE[2]} WHERE suite='testing' AND architecture='$ARCH' AND datum='$DATE'")
+ else
+ AGE_TESTING="-"
+ fi
+ write_page "$AGE_TESTING / $AGE_UNSTABLE / $AGE_EXPERIMENTAL days "
+ done
+ write_page "average test duration (on $DATE) "
+ for ARCH in ${ARCHS} ; do
+ RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(AVG(r.build_duration) AS INTEGER) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_duration!='' AND r.build_duration!='0' AND r.build_date LIKE '%$DATE%' AND s.architecture='$ARCH'")
+ MIN=$(echo $RESULT/60|bc)
+ SEC=$(echo "$RESULT-($MIN*60)"|bc)
+ write_page "$MIN minutes, $SEC seconds "
+ done
+ local TIMESPAN_VERBOSE="4 weeks"
+ local TIMESPAN_RAW="28"
+ write_page "average test duration (in the last $TIMESPAN_VERBOSE) "
+ for ARCH in ${ARCHS} ; do
+ RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT CAST(AVG(r.build_duration) AS INTEGER) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_duration!='' AND r.build_duration!='0' AND r.build_date > datetime('$DATE', '-$TIMESPAN_RAW days') AND s.architecture='$ARCH'")
+ MIN=$(echo $RESULT/60|bc)
+ SEC=$(echo "$RESULT-($MIN*60)"|bc)
+ write_page "$MIN minutes, $SEC seconds "
+ done
+ write_page "packages tested on $DATE "
+ for ARCH in ${ARCHS} ; do
+ RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT COUNT(r.build_date) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_date LIKE '%$DATE%' AND s.architecture='$ARCH'")
+ write_page "$RESULT "
+ done
+ write_page "packages tested on average per day in the last $TIMESPAN_VERBOSE "
+ for ARCH in ${ARCHS} ; do
+ RESULT=$(sqlite3 -init ${INIT} ${PACKAGES_DB} "SELECT COUNT(r.build_date) FROM results AS r JOIN sources AS s ON r.package_id=s.id WHERE r.build_date > datetime('$DATE', '-$TIMESPAN_RAW days') AND s.architecture='$ARCH'")
+ RESULT="$(echo $RESULT/$TIMESPAN_RAW|bc)"
+ write_page "$RESULT "
+ done
+write_page "
" - write_page " " # redo arch specific pngs once a day for ARCH in ${ARCHS} ; do if [ ! -f $BASE/${TABLE[1]}_$ARCH.png ] || [ $DUMMY_FILE -nt $BASE/${TABLE[1]}_$ARCH.png ] ; then @@ -482,32 +494,33 @@ create_dashboard_page() { create_png_from_table 1 ${TABLE[1]}_$ARCH.png fi done - ARCH="amd64" - # write suite builds age graphs - write_page "
" - for SUITE in $SUITES ; do - write_page " " - done - write_build_performance_stats # other archs: armhf ARCH="armhf" write_page "
" - write_page "
" + # write performance stats and build per day graphs + write_page "
" write_build_performance_stats - write_page "
" - for SUITE in unstable experimental ; do - write_page " " + write_page "
" + for ARCH in ${ARCHS} ; do + write_page " " done + # write suite builds age graphs write_page "
" - write_page "
"
+ done
# link to index_breakages
- write_page "
There are some problems in this test setup itself too. And there is documentation too, in case you missed the link at the top. Feedback is always welcome!