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

Add Python 3.7 and Python 3.8 to CI test jobs #2450

Merged
merged 17 commits into from
Apr 1, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 14 additions & 7 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,12 @@ install:
$PIP install --upgrade pip
$PIP install --upgrade wheel
$PIP install --upgrade setuptools
echo "Travis build stage: $TRAVIS_BUILD_STAGE_NAME"
# install dependencies yt
if [[ $TRAVIS_BUILD_STAGE_NAME != "Lint" ]]; then
if [[ ${TRAVIS_BUILD_STAGE_NAME} == "lint" ]]; then
export TRAVIS_BUILD_STAGE_NAME="Lint"
fi
if [[ ${TRAVIS_BUILD_STAGE_NAME} != "Lint" ]]; then
Comment on lines +53 to +56
Copy link
Member

Choose a reason for hiding this comment

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

Here and below, what is the reason to use Lint instead of lint?

Copy link
Member

Choose a reason for hiding this comment

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

I suppose it could be either, but basically what seemed to be happening is that while previously Travis had been capitalizing the stage names (i.e., lint became Lint) for some reason it no longer was in our jobs. And, because OS X runs bash 3.2, we couldn't use the ${VAR^^} or ${VAR,,} construction to change the case as a whole.

So, this is in there in case it switches back. It could use either one, but we figured that the least invasive one would be to assume the old behavior would return some day.

if [[ $MINIMAL == 1 ]]; then
# The first numpy to support py3.6 is 1.12, but numpy 1.13 matches
# unyt so we'll match it here.
Expand All @@ -71,7 +75,7 @@ install:

jobs:
include:
- stage: lint
- stage: Lint
python: 3.6
script: flake8 yt/

Expand All @@ -82,13 +86,13 @@ jobs:
script: coverage run $(which nosetests) -c nose_unit.cfg

- stage: tests
name: "Python: 3.5 Unit Tests"
python: 3.5
name: "Python: 3.6 Unit Tests"
python: 3.6
script: coverage run $(which nosetests) -c nose_unit.cfg

- stage: tests
name: "Python: 3.6 Unit Tests"
python: 3.6
name: "Python: 3.8 Unit Tests"
python: 3.8
script: coverage run $(which nosetests) -c nose_unit.cfg

- stage: tests
Expand All @@ -113,6 +117,9 @@ jobs:

after_success:
- |
if [[ $TRAVIS_BUILD_STAGE_NAME != "Lint" ]]; then
if [[ ${TRAVIS_BUILD_STAGE_NAME} == "lint" ]]; then
export TRAVIS_BUILD_STAGE_NAME="Lint"
fi
if [[ ${TRAVIS_BUILD_STAGE_NAME} != "Lint" ]]; then
codecov
fi
Binary file not shown.
Binary file not shown.
Binary file modified answer-store/py36_phase_plots/py36_phase_plots
Binary file not shown.
Binary file modified answer-store/py36_profile_plots/py36_profile_plots
Binary file not shown.
10 changes: 4 additions & 6 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,8 @@ environment:
PYTHON: "C:\\Miniconda36-x64"

matrix:
- PYTHON_VERSION: "2.7"
MPL_VERSION: "2.2.4"
- PYTHON_VERSION: "3.6"
MPL_VERSION: "3.1.3"
- PYTHON_VERSION: "3.8"

platform:
-x64
Expand All @@ -32,14 +30,14 @@ install:
- "python --version"

# Install specified version of numpy and dependencies
- "conda install --yes -c conda-forge numpy scipy nose pytest setuptools ipython Cython sympy fastcache h5py matplotlib=%MPL_VERSION% mock pandas cartopy conda-build pyyaml"
- "conda develop -b ."
- "conda install --yes -c conda-forge numpy scipy nose pytest setuptools ipython Cython sympy fastcache h5py matplotlib=3.1.3 mock pandas cartopy conda-build pyyaml"
- "pip install -e ."

# Not a .NET project
build: false

test_script:
- "nosetests --nologcapture -sv yt"
- "nosetests --nologcapture -sv --traverse-namespace yt"

# Enable this to be able to login to the build worker. You can use the
# `remmina` program in Ubuntu, use the login information that the line below
Expand Down
8 changes: 5 additions & 3 deletions tests/test_requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ glueviz==0.13.3; python_version >= '3.0'
h5py==2.8.0
ipython==7.1.1; python_version >= '3.0'
ipython==5.8.0; python_version < '3.0'
matplotlib==3.0.3; python_version >= '3.0'
matplotlib==3.1.3; python_version >= '3.0'
matplotlib==2.2.3; python_version < '3.0'
mock==2.0.0; python_version < '3.0'
nose-timer==0.7.3
Expand All @@ -16,12 +16,14 @@ pandas==0.23.4
pytest~=5.2; python_version >= '3.0'
pytest~=4.6; python_version < '3.0'
requests==2.20.0
scipy==1.1.0
scipy==1.1.0; python_version < '3.0'
Copy link
Member

Choose a reason for hiding this comment

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

Since Python 2 is not supported, is there a reason to keep this?

Copy link
Member

Choose a reason for hiding this comment

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

We're still running tests for py2.7, just not on Travis. It hasn't been dropped yet.

scipy==1.3.3; python_version >= '3.0'
sympy==1.5
pyqt5==5.11.3; python_version >= '3.0'
thingking==1.0.2; python_version < '3.0'
pint==0.8.1
netCDF4==1.4.2
netCDF4==1.4.2; python_version < '3.0'
netCDF4==1.5.3; python_version >= '3.0'
Copy link
Member

Choose a reason for hiding this comment

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

Same as above, I would advocate to remote the python_version < '3.0' line.

libconf==1.0.1
cartopy==0.17.0
pyaml==17.10.0
Expand Down
1 change: 0 additions & 1 deletion yt/visualization/tests/test_geo_projections.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ def setUp(self):
@requires_module("cartopy")
def tearDown(self):
del self.ds
del self.slc

@requires_module("cartopy")
def test_geo_projection_setup(self):
Expand Down