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

adds multi-OS support to travis CI #124

Merged
merged 8 commits into from
Dec 17, 2019
Merged

Conversation

mastersplinter
Copy link
Collaborator

Adds multi-OS Support to address #109

This requires a few changes to the current approach:

  • removing linux/macOS specific environment setup
  • changing the "language" feature because "Python" is currently not supported for Windows instances on Travis, using environment variables instead
  • separating the installation of conda, and the setup of the conda environment to keep the CI file easy to read

@mastersplinter mastersplinter added the enhancement New feature or request label Nov 23, 2019
@codecov-io
Copy link

codecov-io commented Nov 23, 2019

Codecov Report

Merging #124 into master will decrease coverage by 0.07%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    #124      +/-   ##
=========================================
- Coverage   95.98%   95.9%   -0.08%     
=========================================
  Files           9       8       -1     
  Lines         448     440       -8     
=========================================
- Hits          430     422       -8     
  Misses         18      18
Impacted Files Coverage Δ
pandera/__init__.py

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5b29d9a...738938f. Read the comment docs.

@cosmicBboy
Copy link
Collaborator

not sure why this build is failing:
https://travis-ci.org/pandera-dev/pandera/jobs/616075868#L418-L419

@mastersplinter
Copy link
Collaborator Author

mastersplinter commented Nov 26, 2019

Please consider this PR WIP - I need to work through the test failures.

* fix windows ci

* fix osx ci
@mastersplinter
Copy link
Collaborator Author

mastersplinter commented Dec 17, 2019

@cosmicBboy please re-review, I've had help from @bensaxby to resolve the test failures.

This PR extends CI support from Linux to also include Windows and osX/macOS by:

  • handling the way Python and Conda work on Travis for different OS versions
  • includes code like conda list because it's easier to debug the CI if it's included
  • contains a specific safety net for if the terminal window is sized too small. The setting of the doctest_global_setup variable is included because when Travis is running a Python environment on macOS it misreports the size of the terminal window as 0 cols, 0 rows. This can be replicated by running make doctest locally with a small terminal window. When the window is too small Pandas trims the dataframe output with ellipsis. I've been unable to replicate this bug locally, i.e. terminal always reports the correct size, so I think it's a bug in Travis-CI.
  • the intermittent Python 3.5 error was caused by a Travis CI cache issue.

Separate to enabling multi-OS support, I believe we should specify specific environments and packages as is achieved here:
https://github.com/kangwonlee/travis-yml-conda-posix-nt/blob/master/.travis.yml

i.e. we would adopt:

env:
  - CONDA_PYTHON=3.6
  - CONDA_PYTHON=3.7
  - CONDA_PYTHON=2018.12
  - CONDA_PYTHON=2019.03
  - CONDA_PYTHON=2019.07
  - CONDA_PYTHON=nightly

and those get substituted into a specific conda environment.yaml file containing explicitly tested dependencies.

At the moment, because we only specify the "minimum" package versions, when the conda environment is rebuilt on CI runs, there's a risk that a change in a new version of a dependency would break the CI Pipeline.

@mastersplinter
Copy link
Collaborator Author

mastersplinter commented Dec 17, 2019

I think Codecov is misreporting the coverage issue and can be bypassed/ignored.

@cosmicBboy
Copy link
Collaborator

@mastersplinter looking good to me!

looks like flake8 is complaining:

tests/test_docs_setting_column_widths.py:4:1: E302 expected 2 blank lines, found 1
tests/test_docs_setting_column_widths.py:9:37: E711 comparison to None should be 'if cond is None:'
tests/test_docs_setting_column_widths.py:10:37: E711 comparison to None should be 'if cond is None:'
tests/test_docs_setting_column_widths.py:10:44: W292 no newline at end of file

@cosmicBboy
Copy link
Collaborator

will ignore code coverage drop, looks like a non-issue

@mastersplinter
Copy link
Collaborator Author

mastersplinter commented Dec 17, 2019

sorry about that - flake8 compliance was a silly miss on my part - I've updated.

FYI I've opened a bug report on the TravisCI Community documenting the specific issue with the way Python on macOS images on Travis report their terminal width.

@cosmicBboy should be good to go

@cosmicBboy cosmicBboy merged this pull request into master Dec 17, 2019
@mastersplinter mastersplinter deleted the feature/ci_enhancements branch December 18, 2019 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants