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-ci: Add more recent compilers, small fixes, and Caliper testing #744

Merged
merged 20 commits into from Aug 10, 2016

Conversation

Projects
None yet
4 participants
@grondo
Copy link
Contributor

grondo commented Aug 5, 2016

The main purpose of this PR was to get Caliper built and installed in Travis so we could at least get some sanity testing with --enable-caliper.

Caliper requires C++0x11 support and a pretty recent CMake, so along the way some other travis config had to be updated. In summary the total of what is done here is:

  • Add recent compilers to Travis environment gcc-4.9 and clang-3.8 via new APT sources
  • Switch to travis' matrix.include method for adding special case items to the build matrix. After everything, we're now up to 7 builds in the matrix, so we might have to try to consolidate a couple of them
  • Checkout and build recent enough version of Caliper to work with Flux
  • Add simple test for Flux with Caliper enabled as t2007-caliper.t
  • Other minor travis fixes along the way

This could also be a jumping off point for ASan and other sanitizers that need recent llvm compilers, though it does seem like we'd have to figure out how to mark the false positives first.

I'm also looking into adding automated release uploads via Travis, and will tack that on to the end of this PR unless @garlick has already done that.

@grondo grondo added the review label Aug 5, 2016

@dongahn

This comment has been minimized.

Copy link
Contributor

dongahn commented Aug 5, 2016

Nice @grondo!

This could also be a jumping off point for ASan and other sanitizers that need recent llvm compilers, though it does seem like we'd have to figure out how to mark the false positives first.

Yes, this seems the good foundation to have CI coverage for Sanitizer tools and we need to find ways to tackle false positives before being able to run make check in the CI.

As a small first step, though, does it make sense we add simple make coverage (but not make check) at some point to ensure flux at least compiles and links with --enable-sanitizer?

@coveralls

This comment has been minimized.

Copy link

coveralls commented Aug 5, 2016

Coverage Status

Coverage increased (+0.1%) to 75.329% when pulling 972ed5e on grondo:travis-updates into 2556295 on flux-framework:master.

@grondo

This comment has been minimized.

Copy link
Contributor Author

grondo commented Aug 6, 2016

for Sanitizer tools and we need to find

As a small first step, though, does it make sense we add simple make
coverage (but not make check) at some point to ensure flux at least
compiles and links with --enable-sanitizer?

Yes, I could try coupling that with the cppcheck test


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

@garlick

This comment has been minimized.

Copy link
Member

garlick commented Aug 6, 2016

This is great.

I'm also looking into adding automated release uploads via Travis, and will tack that on to the end of this PR unless @garlick has already done that.

Please feel free - I haven't even started on this.

@coveralls

This comment has been minimized.

Copy link

coveralls commented Aug 6, 2016

Coverage Status

Coverage increased (+0.1%) to 75.368% when pulling 99d4cd0 on grondo:travis-updates into 2556295 on flux-framework:master.

@grondo

This comment has been minimized.

Copy link
Contributor Author

grondo commented Aug 6, 2016

@dongahn, I added a make only test with --enable-sanitizer after the cppcheck. Other "build-only" checks could go in there too...

@dongahn

This comment has been minimized.

Copy link
Contributor

dongahn commented Aug 6, 2016

@grondo: Awesome work! Thank you.

@dongahn

This comment has been minimized.

Copy link
Contributor

dongahn commented Aug 6, 2016

I'm also looking into adding automated release uploads via Travis, and will tack that on to the end of this PR unless @garlick has already done that.

Great. Once this is done, I will follow this pattern for sched!

@garlick

This comment has been minimized.

Copy link
Member

garlick commented Aug 8, 2016

Just scanned through these commits and it all looks good to me. I think it's fairly essential that we at least build-check any conditionally compiled code we add to Flux!

grondo added some commits Aug 4, 2016

travis-ci: use build matrix instead of custom CC
Use travis.yml matrix.include array to add extra test targets to
the matrix, instead of custom CC environment variables.
travis-ci: enable caliper on clang-3.8 builds
Allow configure ARGS to be modified in travis matrix.include.

Somewhat randomly pick clang-3.8 build to add --enable-caliper
to ./configure, so we get some compile testing of this code.
t/t2007-caliper.t: Add simple tests for caliper support
If Flux is configured with --enable-caliper, then attempt to
run under `flux start --caliper-profile=thread-trace` and ensure
a valid Caliper trace file is emitted.
travis-ci: use --enable-caliper for coverage testing
So that we run Caliper tests during coverage testing, build
with ./configure --enable-caliper during coverage test run
in Travis.
travis-ci: automate GitHub release upload on tags
Setup automated release uploading to GitHub releases via the Travis
`deploy` section. Currently, the releases are hard-coded to be a
prelease, the prelease boolean should be removed once non-prelease
versions of flux-core are being tagged.

There is an issue with creating multi-line release "body" (Release
Notes) via Travis, so for now, we place a link to the in-tree
NEWS.md file, with an anchor to the most recent entry.

A condition is set to ensure that we only attempt to deploy from
the first job of a Travis build, see `on.condition` in the deploy
section. This assumes that TRAVIS_JOB_NUMBER is constructed of the
BUILD number and a numeric job number starting at 1.
NEWS: convert to Markdown format
Convert NEWS file to Markdown format, and put dates into ISO 8601 format
NEWS: rename official NEWS file NEWS.md
Rename NEWS to NEWS.md so it is rendered as markdown on GitHub,
place a pointer to the real NEWS.md file in NEWS.

@grondo grondo force-pushed the grondo:travis-updates branch from 99d4cd0 to 25fe2ac Aug 10, 2016

@grondo

This comment has been minimized.

Copy link
Contributor Author

grondo commented Aug 10, 2016

Ok, I've rebased on current master and also added a first attempt at automated release uploads to GitHub on tags using the Travis deploy section.

There were many caveats along the way

  • GitHub API allows the Release "body" to be set at creation time, and Travis' releases deploy provider ostensibly allows this, however, I could not get a multiline body to work. The quoting seemed to confuse the Travis dpl script that does the deployment. Eventually I gave up and we now have a single line body which links to the tag-specific section of the NEWS file using a Markdown anchor.
  • It took many iterations to determine exactly how to limit the deploy to just a single job in the build matrix. Eventually I found that the current method on.condition: $TRAVIS_JOB_NUMBER = $TRAVIS_BUILD_NUMBER.1 works, but I hope it isn't too brittle.
  • I tried to test out this scheme on a throwaway repo grondo/auto-release-testing, but there is no way to know for sure if this will work with flux-core until we try it out, so there may be some iteration when we try to tag.
@grondo

This comment has been minimized.

Copy link
Contributor Author

grondo commented Aug 10, 2016

Also, as part of this work, I reformatted the NEWS file to markdown, simplified the headings and changed the date format to something standard, and renamed it to NEWS.md for proper rendering on GitHub. This is what allows the anchors to work, though I'm pretty sure they are GitHub Flavored Markdown specific.

@coveralls

This comment has been minimized.

Copy link

coveralls commented Aug 10, 2016

Coverage Status

Coverage increased (+0.1%) to 75.356% when pulling 25fe2ac on grondo:travis-updates into 2556295 on flux-framework:master.

@garlick

This comment has been minimized.

Copy link
Member

garlick commented Aug 10, 2016

Sorry I didn't notice until just now that it looks like you've completed this work and are ready for a merge? The only lingering thought I had was - it seems like autoconf gets unhappy when NEWS and other template files are missing? Do we ened an empty NEWS file or am I misremembering this?

@grondo

This comment has been minimized.

Copy link
Contributor Author

grondo commented Aug 10, 2016

Hmm, yeah I think I left a NEWS file with one line suggesting to look at NEWS.md -- have to double check.

I'd also like to automate an update to the flux-framework.github.io pages, but that one could wait perhaps as this PR has taken too long already.

@garlick garlick merged commit bc8ed62 into flux-framework:master Aug 10, 2016

2 checks passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
coverage/coveralls Coverage increased (+0.1%) to 75.356%
Details

@garlick garlick removed the review label Aug 10, 2016

@garlick garlick referenced this pull request Aug 10, 2016

Closed

0.4.0 release notes #739

@grondo grondo deleted the grondo:travis-updates branch Aug 15, 2016

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.