-
Notifications
You must be signed in to change notification settings - Fork 224
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
NEP29: Set minimum required versions to NumPy 1.17+ and Python 3.7+ (#…
…1074) Start adopting NEP29 - Recommend Python and NumPy version support as a community policy standard, see https://numpy.org/neps/nep-0029-deprecation_policy.html. Bumps minimum supported NumPy version to 1.17 in the setup.py, requirements.txt and environment.yml files. Also set minimum required Python version to be 3.7+. * Modify CI test matrix to test on Numpy 1.17 and 1.20, Python 3.7 and 3.9 Test only on minimum and maximum supported versions according to NEP. I.e. minimum of NumPy 1.17 and Py3.7, maximum of NumPy 1.20 and Py3.9. This drops testing on the middle Python 3.8 version to conserve CI resources. * Add NumPy version to codecov reporting * Update website links of PyGMT deps to use https and official sources * Update MAINTENANCE.md to mention two Linux CI jobs are run in draft PRs * Place NEP29 dependencies policy in MAINTENANCE.md * List NumPy in compatibility version list on main README.rst page
- Loading branch information
Showing
7 changed files
with
57 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,12 +25,12 @@ on: | |
|
||
jobs: | ||
test: | ||
name: ${{ matrix.os }} - Python ${{ matrix.python-version }} | ||
name: ${{ matrix.os }} - Python ${{ matrix.python-version }} / NumPy ${{ matrix.numpy-version }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: [3.7, 3.8, 3.9] | ||
python-version: [3.7, 3.9] | ||
os: [ubuntu-latest, macOS-latest, windows-latest] | ||
# Is it a draft Pull Request (true or false)? | ||
isDraft: | ||
|
@@ -41,20 +41,24 @@ jobs: | |
isDraft: true | ||
- os: windows-latest | ||
isDraft: true | ||
- os: ubuntu-latest | ||
python-version: 3.7 | ||
isDraft: true | ||
- os: ubuntu-latest | ||
python-version: 3.8 | ||
isDraft: true | ||
# - os: ubuntu-latest | ||
# python-version: 3.7 | ||
# isDraft: true | ||
# Pair Python 3.7 with NumPy 1.17 and Python 3.9 with NumPy 1.20 | ||
include: | ||
- python-version: 3.7 | ||
numpy-version: '1.17' | ||
- python-version: 3.9 | ||
numpy-version: '1.20' | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
|
||
# environmental variables used in coverage | ||
# Environment variables used by codecov | ||
env: | ||
OS: ${{ matrix.os }} | ||
PYTHON: ${{ matrix.python-version }} | ||
NUMPY: ${{ matrix.numpy-version }} | ||
|
||
steps: | ||
# Cancel previous runs that are not completed | ||
|
@@ -82,7 +86,8 @@ jobs: | |
# Install GMT and other required dependencies from conda-forge | ||
- name: Install dependencies | ||
run: | | ||
conda install gmt=6.1.1 numpy pandas xarray netCDF4 packaging \ | ||
conda install gmt=6.1.1 numpy=${{ matrix.numpy-version }} \ | ||
pandas xarray netCDF4 packaging \ | ||
codecov coverage[toml] dvc ipython make \ | ||
pytest-cov pytest-mpl pytest>=6.0 \ | ||
sphinx-gallery | ||
|
@@ -138,5 +143,5 @@ jobs: | |
uses: codecov/[email protected] | ||
with: | ||
file: ./coverage.xml # optional | ||
env_vars: OS,PYTHON | ||
env_vars: OS,PYTHON,NUMPY | ||
fail_ci_if_error: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# Required packages | ||
numpy | ||
numpy>=1.17 | ||
pandas | ||
xarray | ||
netCDF4 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters