From 347ae56f3cd72ab2f110e198df66bdab3e813064 Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Fri, 29 Jul 2022 10:43:46 -0400 Subject: [PATCH 1/5] drop py3.6 --- .github/workflows/pytest-remote-data.yml | 6 ++-- .github/workflows/pytest.yml | 6 ++-- benchmarks/asv.conf.json | 2 +- ci/requirements-py3.6.yml | 33 ------------------- ...3.6-min.yml => requirements-py3.7-min.yml} | 2 +- setup.py | 2 +- 6 files changed, 9 insertions(+), 42 deletions(-) delete mode 100644 ci/requirements-py3.6.yml rename ci/{requirements-py3.6-min.yml => requirements-py3.7-min.yml} (96%) diff --git a/.github/workflows/pytest-remote-data.yml b/.github/workflows/pytest-remote-data.yml index f9a726af41..581dd1dc2e 100644 --- a/.github/workflows/pytest-remote-data.yml +++ b/.github/workflows/pytest-remote-data.yml @@ -56,10 +56,10 @@ jobs: strategy: fail-fast: false # don't cancel other matrix jobs when one fails matrix: - python-version: [3.6, 3.7, 3.8, 3.9] + python-version: [3.7, 3.8, 3.9] suffix: [''] # the alternative to "-min" include: - - python-version: 3.6 + - python-version: 3.7 suffix: -min runs-on: ubuntu-latest @@ -102,7 +102,7 @@ jobs: run: pytest pvlib/tests/iotools pvlib/tests/test_forecast.py --cov=./ --cov-report=xml --remote-data - name: Upload coverage to Codecov - if: matrix.python-version == 3.6 && matrix.suffix == '' + if: matrix.python-version == 3.7 && matrix.suffix == '' uses: codecov/codecov-action@v2 with: fail_ci_if_error: true diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 64ad2a724b..c46dac7c14 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -13,12 +13,12 @@ jobs: matrix: # use macos-10.15 instead of macos-latest for py3.6 support os: [ubuntu-latest, macos-10.15, windows-latest] - python-version: [3.6, 3.7, 3.8, 3.9] + python-version: [3.7, 3.8, 3.9] environment-type: [conda, bare] suffix: [''] # placeholder as an alternative to "-min" include: - os: ubuntu-latest - python-version: 3.6 + python-version: 3.7 environment-type: conda suffix: -min exclude: @@ -81,7 +81,7 @@ jobs: pytest pvlib --cov=./ --cov-report=xml --ignore=pvlib/tests/iotools --ignore=pvlib/tests/test_forecast.py - name: Upload coverage to Codecov - if: matrix.python-version == 3.6 && matrix.suffix == '' && matrix.os == 'ubuntu-latest' && matrix.environment-type == 'conda' + if: matrix.python-version == 3.7 && matrix.suffix == '' && matrix.os == 'ubuntu-latest' && matrix.environment-type == 'conda' uses: codecov/codecov-action@v2 with: fail_ci_if_error: true diff --git a/benchmarks/asv.conf.json b/benchmarks/asv.conf.json index 79773e928f..16e66ab8a1 100644 --- a/benchmarks/asv.conf.json +++ b/benchmarks/asv.conf.json @@ -114,7 +114,7 @@ "include": [ // minimum supported versions { - "python": "3.6", + "python": "3.7", "numpy": "1.16.0", "pandas": "0.25.0", "scipy": "1.2.0", diff --git a/ci/requirements-py3.6.yml b/ci/requirements-py3.6.yml deleted file mode 100644 index 596a2e0bbd..0000000000 --- a/ci/requirements-py3.6.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: test_env -channels: - - defaults - - conda-forge -dependencies: - - coveralls - - cython - - ephem - - h5py - - netcdf4 - - nose - - numba - - numpy >= 1.16.0 - - pandas >= 0.25.0 - - pip - - pytest - - pytest-cov - - pytest-mock - - requests-mock - - pytest-rerunfailures - - pytest-remotedata - - pytest-timeout - - python=3.6 - - pytz - - requests - - scipy >= 1.2.0 - - shapely # pvfactors dependency - - siphon # conda-forge - - statsmodels - - pip: - - dataclasses - - nrel-pysam>=2.0 - - pvfactors==1.4.1 diff --git a/ci/requirements-py3.6-min.yml b/ci/requirements-py3.7-min.yml similarity index 96% rename from ci/requirements-py3.6-min.yml rename to ci/requirements-py3.7-min.yml index dfff0a9f97..d93d0b2bd3 100644 --- a/ci/requirements-py3.6-min.yml +++ b/ci/requirements-py3.7-min.yml @@ -9,7 +9,7 @@ dependencies: - pytest-cov - pytest-mock - pytest-timeout - - python=3.6 + - python=3.7 - pytz - requests - pip: diff --git a/setup.py b/setup.py index 96b4737515..236aa1cca4 100755 --- a/setup.py +++ b/setup.py @@ -75,7 +75,7 @@ 'zip_safe': False, 'scripts': [], 'include_package_data': True, - 'python_requires': '>=3.6' + 'python_requires': '>=3.7' } PROJECT_URLS = { From cddc98399d77c0b80e2a1fc25a04058204bff5db Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Fri, 29 Jul 2022 10:52:33 -0400 Subject: [PATCH 2/5] bump CI from macos-10.15 to macos-latest --- .github/workflows/pytest.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index c46dac7c14..620c9a9289 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -11,8 +11,7 @@ jobs: strategy: fail-fast: false # don't cancel other matrix jobs when one fails matrix: - # use macos-10.15 instead of macos-latest for py3.6 support - os: [ubuntu-latest, macos-10.15, windows-latest] + os: [ubuntu-latest, macos-latest, windows-latest] python-version: [3.7, 3.8, 3.9] environment-type: [conda, bare] suffix: [''] # placeholder as an alternative to "-min" @@ -22,7 +21,7 @@ jobs: environment-type: conda suffix: -min exclude: - - os: macos-10.15 + - os: macos-latest environment-type: conda - os: windows-latest environment-type: bare From 5d4a711c85901a305a1b19c950163fea05297fb8 Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Fri, 29 Jul 2022 11:00:32 -0400 Subject: [PATCH 3/5] add testing on py3.10 --- .github/workflows/pytest-remote-data.yml | 2 +- .github/workflows/pytest.yml | 2 +- ci/requirements-py3.10.yml | 32 ++++++++++++++++++++++++ 3 files changed, 34 insertions(+), 2 deletions(-) create mode 100644 ci/requirements-py3.10.yml diff --git a/.github/workflows/pytest-remote-data.yml b/.github/workflows/pytest-remote-data.yml index 581dd1dc2e..ad57d2c175 100644 --- a/.github/workflows/pytest-remote-data.yml +++ b/.github/workflows/pytest-remote-data.yml @@ -56,7 +56,7 @@ jobs: strategy: fail-fast: false # don't cancel other matrix jobs when one fails matrix: - python-version: [3.7, 3.8, 3.9] + python-version: [3.7, 3.8, 3.9, "3.10"] suffix: [''] # the alternative to "-min" include: - python-version: 3.7 diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 620c9a9289..79e345baff 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -12,7 +12,7 @@ jobs: fail-fast: false # don't cancel other matrix jobs when one fails matrix: os: [ubuntu-latest, macos-latest, windows-latest] - python-version: [3.7, 3.8, 3.9] + python-version: [3.7, 3.8, 3.9, "3.10"] environment-type: [conda, bare] suffix: [''] # placeholder as an alternative to "-min" include: diff --git a/ci/requirements-py3.10.yml b/ci/requirements-py3.10.yml new file mode 100644 index 0000000000..c7e5248230 --- /dev/null +++ b/ci/requirements-py3.10.yml @@ -0,0 +1,32 @@ +name: test_env +channels: + - defaults + - conda-forge +dependencies: + - coveralls + - cython + - ephem + - h5py + # - netcdf4 # pulls in a different version of numpy with ImportError + - nose + # - numba # python 3.9 compat in early 2021 + - numpy >= 1.16.0 + - pandas >= 0.25.0 + - pip + - pytest + - pytest-cov + - pytest-mock + - requests-mock + - pytest-timeout + - pytest-rerunfailures + - pytest-remotedata + - python=3.10 + - pytz + - requests + - scipy >= 1.2.0 + - shapely # pvfactors dependency + # - siphon # conda-forge + - statsmodels + - pip: + # - nrel-pysam>=2.0 # install error on windows + - pvfactors==1.4.1 From 17a59527ef62b6698c9c8f7dc8b0599c92db3e82 Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Fri, 29 Jul 2022 12:02:39 -0400 Subject: [PATCH 4/5] remove dataclasses requirement --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 236aa1cca4..c33e1c3715 100755 --- a/setup.py +++ b/setup.py @@ -44,7 +44,7 @@ 'requests', 'scipy >= 1.2.0', 'h5py', - 'dataclasses; python_version < "3.7"'] + ] TESTS_REQUIRE = ['nose', 'pytest', 'pytest-cov', 'pytest-mock', 'requests-mock', 'pytest-timeout', 'pytest-rerunfailures', From 338d3e7707b71da4523b741ab03a78af9dbf523a Mon Sep 17 00:00:00 2001 From: Kevin Anderson Date: Fri, 29 Jul 2022 12:12:01 -0400 Subject: [PATCH 5/5] whatsnew --- docs/sphinx/source/whatsnew/v0.9.2.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/sphinx/source/whatsnew/v0.9.2.rst b/docs/sphinx/source/whatsnew/v0.9.2.rst index dcce33370f..d5a415f972 100644 --- a/docs/sphinx/source/whatsnew/v0.9.2.rst +++ b/docs/sphinx/source/whatsnew/v0.9.2.rst @@ -30,6 +30,7 @@ Testing ~~~~~~~ * Switched CI testing provider from Azure to GitHub Actions (:pull:`1306`) * Speed up CI setup using micromamba instead of conda (:pull:`1493`) +* Drop python 3.6 (reached end of life Dec 2021) and add 3.10 to test matrix (:pull:`1507`) Documentation @@ -47,6 +48,7 @@ Benchmarking Requirements ~~~~~~~~~~~~ +* Python 3.7 or greater. (:pull:`1507`) * Minimum pandas version increased to v0.25.0, released July 18, 2019. (:pull:`1448`) Contributors