From 35e7005184ee212945edc985e81e80855113e5ac Mon Sep 17 00:00:00 2001 From: Todd Volkert Date: Sat, 25 Jul 2020 09:44:17 -0700 Subject: [PATCH] Rather than timing out dashing, run it in background (#62251) https://github.com/flutter/flutter/issues/60646 --- dev/bots/docs.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/dev/bots/docs.sh b/dev/bots/docs.sh index 1a69d568b1..f4c1415d63 100755 --- a/dev/bots/docs.sh +++ b/dev/bots/docs.sh @@ -54,13 +54,17 @@ function create_docset() { echo "$(date): Building Flutter docset." rm -rf flutter.docset # If dashing gets stuck, Cirrus will time out the build after an hour, and we - # never get to see the logs. Thus, we time it out after 30 minutes to see the - # logs. - (timeout '30m' dashing build --source ./doc --config ./dashing.json > /tmp/dashing.log 2>&1 || \ - (echo 'Dashing failed! Tailing last 200 lines of log...'; tail -200 /tmp/dashing.log; exit 1)) && \ + # never get to see the logs. Thus, we run it in the background and tail the logs + # while we wait for it to complete. + dashing build --source ./doc --config ./dashing.json > /tmp/dashing.log 2>&1 & + dashing_pid=$! + tail -f /tmp/dashing.log & + tail_pid=$! + wait $dashing_pid && \ cp ./doc/flutter/static-assets/favicon.png ./flutter.docset/icon.png && \ "$DART" --disable-dart-dev ./dashing_postprocess.dart && \ - tar cf flutter.docset.tar.gz --use-compress-program="gzip --best" flutter.docset + tar cf flutter.docset.tar.gz --use-compress-program="gzip --best" flutter.docset && \ + kill $tail_pid &> /dev/null } # Move the offline archives into place, after all the processing of the doc