Skip to content

Commit

Permalink
[R-package] [ci] Fix CI timeouts for Mac builds on Travis (fixes micr…
Browse files Browse the repository at this point in the history
…osoft#3091) (microsoft#3092)

* [R-package] use processx to speed up builds

* different fix

* echoing more frequently

* fix it

* more stdout

* use print() instead of message()

* shell tricks

* fix message

* travis

* Update .ci/test_r_package.sh

Co-authored-by: Nikita Titov <[email protected]>

Co-authored-by: Nikita Titov <[email protected]>
  • Loading branch information
2 people authored and odimka committed May 17, 2020
1 parent b0502ab commit d3d99c0
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions .ci/test_r_package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,21 @@ export _R_CHECK_FORCE_SUGGESTS_=0
# fails tests if either ERRORs or WARNINGs are thrown by
# R CMD CHECK
check_succeeded="yes"
R CMD check ${PKG_TARBALL} \
--as-cran \
|| check_succeeded="no"
(
R CMD check ${PKG_TARBALL} \
--as-cran \
|| check_succeeded="no"
) &

# R CMD check suppresses output, some CIs kill builds after
# a few minutes with no output. This trick gives R CMD check more time
# * https:/travis-ci/travis-ci/issues/4190#issuecomment-169987525
# * https://stackoverflow.com/a/29890106/3986677
CHECK_PID=$!
while kill -0 ${CHECK_PID} >/dev/null 2>&1; do
echo -n -e " \b"
sleep 5
done

echo "R CMD check build logs:"
cat ${BUILD_DIRECTORY}/lightgbm.Rcheck/00install.out
Expand Down

0 comments on commit d3d99c0

Please sign in to comment.