diff --git a/.travis.yml b/.travis.yml index 0f43e4cf54faa..9eccf87960dd0 100644 --- a/.travis.yml +++ b/.travis.yml @@ -51,7 +51,7 @@ matrix: - python-gtk2 - dist: trusty env: - - JOB="3.5" TEST_ARGS="--skip-slow --skip-network" COVERAGE=true + - JOB="3.5_CONDA_BUILD_TEST" TEST_ARGS="--skip-slow --skip-network" CONDA_BUILD_TEST=true COVERAGE=true - dist: trusty env: - JOB="3.6" TEST_ARGS="--skip-slow --skip-network" PANDAS_TESTING_MODE="deprecate" CONDA_FORGE=true @@ -62,7 +62,7 @@ matrix: # In allow_failures - dist: trusty env: - - JOB="3.6_BUILD_TEST" TEST_ARGS="--skip-slow" BUILD_TEST=true + - JOB="3.6_PIP_BUILD_TEST" TEST_ARGS="--skip-slow" PIP_BUILD_TEST=true addons: apt: packages: @@ -81,7 +81,7 @@ matrix: - JOB="2.7_SLOW" SLOW=true - dist: trusty env: - - JOB="3.6_BUILD_TEST" TEST_ARGS="--skip-slow" BUILD_TEST=true + - JOB="3.6_PIP_BUILD_TEST" TEST_ARGS="--skip-slow" PIP_BUILD_TEST=true addons: apt: packages: diff --git a/ci/install_travis.sh b/ci/install_travis.sh index dac3625cba4ba..90b9bf3f3186e 100755 --- a/ci/install_travis.sh +++ b/ci/install_travis.sh @@ -50,6 +50,13 @@ conda config --set ssl_verify false || exit 1 conda config --set quiet true --set always_yes true --set changeps1 false || exit 1 conda update -q conda +if [ "$CONDA_BUILD_TEST" ]; then + echo + echo "[installing conda-build]" + conda install conda-build +fi + + echo echo "[add channels]" conda config --remove channels defaults || exit 1 @@ -116,7 +123,7 @@ if [ "$COVERAGE" ]; then fi echo -if [ -z "$BUILD_TEST" ]; then +if [ -z "$PIP_BUILD_TEST" ] and [ -z "$CONDA_BUILD_TEST" ]; then # build but don't install echo "[build em]" @@ -155,23 +162,34 @@ echo "[removing installed pandas]" conda remove pandas -y --force pip uninstall -y pandas -if [ "$BUILD_TEST" ]; then +echo +echo "[no installed pandas]" +conda list pandas +pip list --format columns |grep pandas - # remove any installation - pip uninstall -y pandas - conda list pandas - pip list --format columns |grep pandas +# build and install +echo + +if [ "$PIP_BUILD_TEST" ]; then # build & install testing - echo ["building release"] + echo "[building release]" bash scripts/build_dist_for_release.sh conda uninstall -y cython time pip install dist/*tar.gz || exit 1 +elif [ "$CONDA_BUILD_TEST" ]; then + + # build & install testing + echo "[building conda recipe]" + conda build ./conda.recipe --numpy 1.13 --python 3.5 -q --no-test + + echo "[installing]" + conda install $(conda build ./conda.recipe --numpy 1.13 --python 3.5 --output) --force + else # install our pandas - echo echo "[running setup.py develop]" python setup.py develop || exit 1 diff --git a/ci/requirements-3.5.build b/ci/requirements-3.5_CONDA_BUILD_TEST.build similarity index 77% rename from ci/requirements-3.5.build rename to ci/requirements-3.5_CONDA_BUILD_TEST.build index 76227e106e1fd..6648e3778777c 100644 --- a/ci/requirements-3.5.build +++ b/ci/requirements-3.5_CONDA_BUILD_TEST.build @@ -2,5 +2,5 @@ python=3.5* python-dateutil pytz nomkl -numpy=1.11.3 +numpy=1.13* cython diff --git a/ci/requirements-3.5.pip b/ci/requirements-3.5_CONDA_BUILD_TEST.pip similarity index 100% rename from ci/requirements-3.5.pip rename to ci/requirements-3.5_CONDA_BUILD_TEST.pip diff --git a/ci/requirements-3.5.run b/ci/requirements-3.5_CONDA_BUILD_TEST.run similarity index 92% rename from ci/requirements-3.5.run rename to ci/requirements-3.5_CONDA_BUILD_TEST.run index 52828b5220997..19d9a91e86585 100644 --- a/ci/requirements-3.5.run +++ b/ci/requirements-3.5_CONDA_BUILD_TEST.run @@ -1,5 +1,5 @@ pytz -numpy=1.11.3 +numpy=1.13* openpyxl xlsxwriter xlrd diff --git a/ci/requirements-3.5.sh b/ci/requirements-3.5_CONDA_BUILD_TEST.sh similarity index 86% rename from ci/requirements-3.5.sh rename to ci/requirements-3.5_CONDA_BUILD_TEST.sh index d694ad3679ac1..09d6775cfc894 100644 --- a/ci/requirements-3.5.sh +++ b/ci/requirements-3.5_CONDA_BUILD_TEST.sh @@ -2,7 +2,7 @@ source activate pandas -echo "install 35" +echo "install 35 CONDA_BUILD_TEST" # pip install python-dateutil to get latest conda remove -n pandas python-dateutil --force diff --git a/ci/requirements-3.6_BUILD_TEST.build b/ci/requirements-3.6_PIP_BUILD_TEST.build similarity index 100% rename from ci/requirements-3.6_BUILD_TEST.build rename to ci/requirements-3.6_PIP_BUILD_TEST.build diff --git a/ci/requirements-3.6_BUILD_TEST.pip b/ci/requirements-3.6_PIP_BUILD_TEST.pip similarity index 100% rename from ci/requirements-3.6_BUILD_TEST.pip rename to ci/requirements-3.6_PIP_BUILD_TEST.pip diff --git a/ci/requirements-3.6_BUILD_TEST.sh b/ci/requirements-3.6_PIP_BUILD_TEST.sh similarity index 75% rename from ci/requirements-3.6_BUILD_TEST.sh rename to ci/requirements-3.6_PIP_BUILD_TEST.sh index 2a3adeff836ee..3a8cf673b32f2 100644 --- a/ci/requirements-3.6_BUILD_TEST.sh +++ b/ci/requirements-3.6_PIP_BUILD_TEST.sh @@ -2,6 +2,6 @@ source activate pandas -echo "install 36 BUILD_TEST" +echo "install 36 PIP_BUILD_TEST" conda install -n pandas -c conda-forge pyarrow dask pyqt qtpy diff --git a/ci/script_multi.sh b/ci/script_multi.sh index 58742552628c8..c1fa756ece965 100755 --- a/ci/script_multi.sh +++ b/ci/script_multi.sh @@ -18,7 +18,7 @@ fi export PYTHONHASHSEED=$(python -c 'import random; print(random.randint(1, 4294967295))') echo PYTHONHASHSEED=$PYTHONHASHSEED -if [ "$BUILD_TEST" ]; then +if [ "$PIP_BUILD_TEST" ] || [ "$CONDA_BUILD_TEST" ]; then echo "[build-test]" echo "[env]" diff --git a/ci/script_single.sh b/ci/script_single.sh index 963ce00b4a094..005c648ee025f 100755 --- a/ci/script_single.sh +++ b/ci/script_single.sh @@ -16,7 +16,7 @@ if [ "$SLOW" ]; then TEST_ARGS="--only-slow --skip-network" fi -if [ "$BUILD_TEST" ]; then +if [ "$PIP_BUILD_TEST" ] || [ "$CONDA_BUILD_TEST" ]; then echo "We are not running pytest as this is a build test." elif [ "$DOC" ]; then diff --git a/conda.recipe/meta.yaml b/conda.recipe/meta.yaml index 0b54980d2bc87..3510496f0b519 100644 --- a/conda.recipe/meta.yaml +++ b/conda.recipe/meta.yaml @@ -1,9 +1,9 @@ package: name: pandas - version: {{ GIT_DESCRIBE_TAG|replace("v","") }} + version: {{ environ.get('GIT_DESCRIBE_TAG','').replace('v', '', 1) }} build: - number: {{ GIT_DESCRIBE_NUMBER|int }} + number: {{ environ.get('GIT_DESCRIBE_NUMBER', 0) }} {% if GIT_DESCRIBE_NUMBER|int == 0 %}string: np{{ CONDA_NPY }}py{{ CONDA_PY }}_0 {% else %}string: np{{ CONDA_NPY }}py{{ CONDA_PY }}_{{ GIT_BUILD_STR }}{% endif %} @@ -14,12 +14,14 @@ requirements: build: - python - cython - - numpy x.x + - {{ pin_compatible('numpy') }} - setuptools >=3.3 + - python-dateutil >=2.5.0 + - pytz run: - python - - numpy x.x + - {{ pin_compatible('numpy') }} - python-dateutil >=2.5.0 - pytz diff --git a/doc/source/whatsnew/v0.22.0.txt b/doc/source/whatsnew/v0.22.0.txt index ae6d0816abc41..55c50bf8c6442 100644 --- a/doc/source/whatsnew/v0.22.0.txt +++ b/doc/source/whatsnew/v0.22.0.txt @@ -162,8 +162,12 @@ If installed, we now require: +-----------------+-----------------+----------+ +Build Changes +^^^^^^^^^^^^^ + - Building pandas for development now requires ``cython >= 0.24`` (:issue:`18613`) - Building from source now explicity requires ``setuptools`` in ``setup.py`` (:issue:`18113`) +- Updated conda recipe to be in compliance with conda-build 3.0+ (:issue:`18002`) .. _whatsnew_0220.api: