Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

travis: Enable qt for all jobs #13515

Merged
merged 1 commit into from Oct 26, 2018

Conversation

Projects
None yet
6 participants
@ken2812221
Copy link
Member

commented Jun 21, 2018

  • If depends build take more than 20 mins, skip Bitcoin Core build to store depends caches and mark it fail. Then restart the job for Bitcoin Core build.
  • Enable Qt build for Windows and 32-bit Linux
  • Enable wallet for depends x86-64 Linux
  • Disable gui tests for Windows since they are not supported

This would be helpful for upgrading Qt (#12971) and protobuf (#13513)

@fanquake fanquake added the Tests label Jun 21, 2018

.travis.yml Outdated
# Win64
- HOST=x86_64-w64-mingw32 DEP_OPTS="NO_QT=1" PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine-binfmt wine64" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-reduce-exports"
- HOST=x86_64-w64-mingw32 PACKAGES="python3 nsis g++-mingw-w64-x86-64 wine-binfmt wine64" RUN_TESTS=true GOAL="install" BITCOIN_CONFIG="--enable-reduce-exports --disable-gui-tests"

This comment has been minimized.

Copy link
@MarcoFalke

MarcoFalke Jun 21, 2018

Member

Might as well change "install" to "deploy", so we get the setup.exe as well?

This comment has been minimized.

Copy link
@ken2812221

ken2812221 Jun 21, 2018

Author Member

Sure

@MarcoFalke

This comment has been minimized.

Copy link
Member

commented Jun 21, 2018

Would be nicer if travis natively supported multi-job-multi-stage builds, but yeah, maybe this hack is required.

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch Jun 21, 2018

@laanwj laanwj requested a review from theuni Jun 24, 2018

@DrahtBot

This comment has been minimized.

Copy link
Contributor

commented Jun 30, 2018

Reviewers, this pull request conflicts with the following ones:
  • #14231 (travis: Save cache even when build or test fail by ken2812221)
  • #13827 ([WIP] depends: Add native_nsis to support unicode by ken2812221)

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch Jul 18, 2018

@ken2812221 ken2812221 changed the title travis: Enable Qt build for Windows and 32-bit Linux travis: Enable Qt build for Windows , i686 and arm Linux Jul 18, 2018

@ken2812221

This comment has been minimized.

Copy link
Member Author

commented Jul 18, 2018

Update: Enable qt for arm

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch Jul 18, 2018

.travis.yml Outdated
- if [ "$RUN_TESTS" = "true" ]; then DOCKER_EXEC LD_LIBRARY_PATH=$TRAVIS_BUILD_DIR/depends/$HOST/lib make $MAKEJOBS check VERBOSE=1; fi
- if [ "$TRAVIS_EVENT_TYPE" = "cron" ]; then extended="--extended --exclude feature_pruning,feature_dbcrash"; fi
- if [ "$RUN_TESTS" = "true" ]; then DOCKER_EXEC test/functional/test_runner.py --combinedlogslen=4000 --coverage --quiet --failfast ${extended}; fi
# Skip Bitcoin Core build if depends build take more than 20 mins.

This comment has been minimized.

Copy link
@MarcoFalke

MarcoFalke Jul 18, 2018

Member

hmm. Not sure about that. We'd have to manually reset travis on all pull requests that are affected by this.

This comment has been minimized.

Copy link
@ken2812221

ken2812221 Jul 18, 2018

Author Member

We'd have to manually reset travis on all pull requests that are affected by this.

We can clear the cache of all PRs to solve this just like what we do after migrate tests to docker.

This comment has been minimized.

Copy link
@MarcoFalke

MarcoFalke Jul 18, 2018

Member

What I mean is that a early exit should not make travis green. Maybe add an echo "Travis early exit to cache current state" && false somewhere?

This comment has been minimized.

Copy link
@ken2812221

ken2812221 Jul 18, 2018

Author Member

It does not make travis green. If test $SECONDS -lt 1200 has failed, travis would turn out red. But it's a good idea to add error message.

This comment has been minimized.

Copy link
@MarcoFalke

MarcoFalke Jul 18, 2018

Member

Ah thanks for the clarification. I missed that.

.travis.yml Outdated
- if [ "$RUN_TESTS" = "true" ]; then BEGIN_FOLD functional-tests; DOCKER_EXEC test/functional/test_runner.py --combinedlogslen=4000 --coverage --quiet --failfast ${extended}; END_FOLD; fi
# Skip Bitcoin Core build if depends build take more than 20 mins.
- |
( test $SECONDS -lt 1200 || ( echo Travis early exit to cache current state && false ) ) && (

This comment has been minimized.

Copy link
@scravy

scravy Aug 1, 2018

Contributor

This could simply be its own line in the script section.

I really like the rest of the script to be joined into a single block using the | YAML goodness, but putting this check on an individual line (- ...) would spare the ) && ( LOTSOFLINES ) awkwardness.

This comment has been minimized.

Copy link
@scravy

scravy Aug 3, 2018

Contributor

As I learned in #13863 – if you split the script like that then the exit codes of the commands in each line will not make the script fail, i.e. if the unit tests fail the build will not fail.

This comment has been minimized.

Copy link
@ken2812221

ken2812221 Aug 6, 2018

Author Member

Thanks, I'll work on this after #13836 merged.

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch 2 times, most recently Aug 3, 2018

@ken2812221 ken2812221 changed the title travis: Enable Qt build for Windows , i686 and arm Linux travis: avoid timeout without saving caches, also enable all qt Aug 3, 2018

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch 2 times, most recently Aug 3, 2018

@ken2812221 ken2812221 deleted the ken2812221:travis_qt branch Aug 30, 2018

@ken2812221 ken2812221 restored the ken2812221:travis_qt branch Aug 30, 2018

@ken2812221 ken2812221 reopened this Aug 30, 2018

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch 4 times, most recently Aug 30, 2018

@ken2812221 ken2812221 changed the title travis: avoid timeout without saving caches, also enable all qt travis: Avoid being timeout without saving caches, also enable qt builds for all jobs if available Sep 1, 2018

@ken2812221

This comment has been minimized.

Copy link
Member Author

commented Sep 1, 2018

This is ready for review. Thanks for #13863, I don't have to do a lot of line changes.

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch 3 times, most recently Sep 1, 2018

@MarcoFalke

This comment has been minimized.

Copy link
Member

commented Sep 4, 2018

As this is effectively reverting a33b7c9, could the GOALs be changed to deploy?

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch 2 times, most recently Sep 4, 2018

@ken2812221

This comment has been minimized.

Copy link
Member Author

commented Sep 5, 2018

@MarcoFalke Changed goals to deploy, also revert 3d69853 because of cf01fd6

Show resolved Hide resolved .travis.yml

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch Sep 10, 2018

@ken2812221 ken2812221 force-pushed the ken2812221:travis_qt branch to 3387bb0 Sep 10, 2018

@ken2812221 ken2812221 changed the title travis: Avoid being timeout without saving caches, also enable qt builds for all jobs if available travis: Avoid timeout without saving caches, also enable qt builds for all jobs if available Sep 30, 2018

@ken2812221 ken2812221 changed the title travis: Avoid timeout without saving caches, also enable qt builds for all jobs if available travis: Enable qt for all jobs Oct 11, 2018

@Sjors
Copy link
Member

left a comment

Concept ACK

@@ -34,7 +34,7 @@ install:
before_script:
- set -o errexit; source .travis/test_05_before_script.sh
script:
- set -o errexit; source .travis/test_06_script.sh
- if [ $SECONDS -gt 1200 ]; then set +o errexit; echo "Travis early exit to cache current state"; false; else set -o errexit; source .travis/test_06_script.sh; fi

This comment has been minimized.

Copy link
@Sjors

Sjors Oct 26, 2018

Member

Should this be in the before_script?

This comment has been minimized.

Copy link
@MarcoFalke

MarcoFalke Oct 26, 2018

Member

before_script does the depends build, which should be cached, so no?

This comment has been minimized.

Copy link
@Sjors

Sjors Oct 27, 2018

Member

I didn't know chache was discared during a premature exit. If so, then this makes sense.

@MarcoFalke MarcoFalke merged commit 3387bb0 into bitcoin:master Oct 26, 2018

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

MarcoFalke added a commit that referenced this pull request Oct 26, 2018

Merge #13515: travis: Enable qt for all jobs
3387bb0 travis: avoid timeout without saving caches, also enable all qt (Chun Kuan Lee)

Pull request description:

  - If depends build take more than 20 mins, skip Bitcoin Core build to store depends caches and mark it fail. Then restart the job for Bitcoin Core build.
  - Enable Qt build for Windows and 32-bit Linux
  - Enable wallet for depends x86-64 Linux
  - Disable gui tests for Windows since they are not supported

  This would be helpful for upgrading Qt (#12971) and protobuf (#13513)

Tree-SHA512: e943cbd848d90f9f70e29c94ed717f96ad2c2d27b433bafea762015756a2d2794fc28976c54aee087bf0f3726ac2c9140920272445a902038719b956e2160cf9

@ken2812221 ken2812221 deleted the ken2812221:travis_qt branch Oct 27, 2018

@sickpig sickpig referenced this pull request Jan 18, 2019

Merged

Improve travis caching #1559

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.