Skip to content

[MRG+1] Travis: move scipy-dev-wheels build to a cron job #9852

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

Merged
merged 4 commits into from
Oct 1, 2017

Conversation

lesteve
Copy link
Member

@lesteve lesteve commented Sep 29, 2017

The plan is to use a daily cron job to test the development numpy and scipy wheels. The idea behind this is that it is very rare that a particular numpy-dev or scipy-dev related failure is due to a change in the PR.

The cron job will be daily and the numpy-dev scipy-dev will not be allowed to fail. I think it fails quite rarely and allow_failures means we tend not to pay enough attention to failures. Also because it only runs daily it does not mean that many emails in case of failure.

I am skipping doctests in scipy-dev build because they are broken on numpy dev due to a change in the numpy array repr/str with spaces. Note I switched to pytest for the scipy-dev build, mostly because it is easier to skip doctests.

I have tested the cron job and the .travis.yml on lesteve/scikit-learn in Travis and everything works. I'll wait to see if anyone has comments/concerns and if not I'll merge this one.

More details about the numpy array repr/str changes

import numpy as np
print(repr(np.array([0., 1., 2.5])))

1.13.1:

array([ 0. ,  1. ,  2.5])

1.14dev:

array([0. , 1. , 2.5])

Part of the gory details: numpy/numpy#9139.

@lesteve lesteve force-pushed the travis-cron branch 7 times, most recently from e41bc8e to b00a14d Compare September 29, 2017 14:36
scipy-dev-wheels build not allowed to fail anymore.

Do not run doctests in scipy-dev build because they are broken on
numpy dev due to a change in the numpy array repr/str with spaces.
Copy link
Member

@jnothman jnothman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for this rather than allowed failures.

LGTM

if [[ "$DISTRIB" == "scipy-dev-wheels" ]]; then
# Do not run doctests in scipy-dev-wheels build for now
# (broken by numpy 1.14.dev array repr/str formatting change)
export PYTEST_ADDOPTS="-p no:doctest"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd rather modify TEST_CMD than mix local and global env changes.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I ended up using np.set_printoptions(sign='legacy') in conftest.py. This way, the Travis test_script.sh code is simpler and it works locally for people using numpy > 1.13.

@jnothman jnothman changed the title [MRG] Travis: move scipy-dev-wheels build to a cron job [MRG+1] Travis: move scipy-dev-wheels build to a cron job Oct 1, 2017
@lesteve
Copy link
Member Author

lesteve commented Oct 1, 2017

I am going to merge this one and enable a Travis cron job on the master branch.

@lesteve lesteve merged commit 636a73e into scikit-learn:master Oct 1, 2017
@lesteve lesteve deleted the travis-cron branch October 1, 2017 07:31
@amueller
Copy link
Member

amueller commented Oct 3, 2017

This is pretty cool. When were cron jobs introduced and how are they configured? I don't see the frequency in the code.

@lesteve
Copy link
Member Author

lesteve commented Oct 3, 2017

I think they were introduced a while ago (maybe months) but what is new is the fact that you can have a dynamical build matrix (the cron job has only scipy-dev-wheels build and the "normal" build has all the builds). The latter is more recent:
travis-ci/travis-ci#7181 (comment)
https://blog.travis-ci.com/2017-09-12-build-stages-order-and-conditions

The cron job has to be configured in https://travis-ci.org/scikit-learn/scikit-learn/settings (branch name and frequency which can be daily, weekly or monthly)

wdevazelhes pushed a commit to wdevazelhes/scikit-learn that referenced this pull request Oct 27, 2017
maskani-moh pushed a commit to maskani-moh/scikit-learn that referenced this pull request Nov 15, 2017
jwjohnson314 pushed a commit to jwjohnson314/scikit-learn that referenced this pull request Dec 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants