diff --git a/.appveyor.yml b/.appveyor.yml
index 5d9dce4bcaa0..91d5a022fd42 100644
--- a/.appveyor.yml
+++ b/.appveyor.yml
@@ -21,15 +21,12 @@ environment:
PINNEDVERS: "pyzmq!=21.0.0,!=22.0.0"
matrix:
- # In theory we could use a single CONDA_INSTALL_LOCN because we construct
- # the envs anyway. But using one for the right python version hopefully
- # making things faster due to package caching.
- - PYTHON_VERSION: "3.7"
- CONDA_INSTALL_LOCN: "C:\\Miniconda37-x64"
+ - PYTHON_VERSION: "3.8"
+ CONDA_INSTALL_LOCN: "C:\\Miniconda3-x64"
TEST_ALL: "no"
EXTRAREQS: "-r requirements/testing/extra.txt"
- - PYTHON_VERSION: "3.8"
- CONDA_INSTALL_LOCN: "C:\\Miniconda37-x64"
+ - PYTHON_VERSION: "3.9"
+ CONDA_INSTALL_LOCN: "C:\\Miniconda3-x64"
TEST_ALL: "no"
EXTRAREQS: "-r requirements/testing/extra.txt"
diff --git a/.github/workflows/cibuildwheel.yml b/.github/workflows/cibuildwheel.yml
index 39b9c46d61a4..c56f2596f512 100644
--- a/.github/workflows/cibuildwheel.yml
+++ b/.github/workflows/cibuildwheel.yml
@@ -28,8 +28,6 @@ jobs:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
env:
- min-numpy-version: "1.17.3"
- min-numpy-hash: "b6/d6/be8f975f5322336f62371c9abeb936d592c98c047ad63035f1b38ae08efe"
CIBW_ARCHS_MACOS: "x86_64 universal2 arm64"
strategy:
matrix:
@@ -53,29 +51,12 @@ jobs:
- uses: actions/setup-python@v2
name: Install Python
with:
- python-version: '3.7'
-
- - uses: actions/cache@v2
- id: numpy-cache
- with:
- path: numpy-aarch64-cache/
- key: numpy-${{ matrix.cibw_archs }}-cache-${{ env.min-numpy-version }}
+ python-version: '3.8'
- name: Install cibuildwheel
run: |
python -m pip install cibuildwheel==2.1.1
- - name: Build minimum NumPy for aarch64
- if: matrix.cibw_archs == 'aarch64' && steps.numpy-cache.outputs.cache-hit != 'true'
- run: |
- wget https://files.pythonhosted.org/packages/${{ env.min-numpy-hash }}/numpy-${{ env.min-numpy-version }}.zip
- unzip numpy-${{ env.min-numpy-version }}.zip
- cd numpy-${{ env.min-numpy-version }}
- python -m cibuildwheel --output-dir ../numpy-aarch64-cache
- env:
- CIBW_BUILD: "cp37-* cp38-*"
- CIBW_ARCHS: aarch64
-
- name: Build wheels for CPython 3.10
run: |
python -m cibuildwheel --output-dir dist
@@ -83,7 +64,7 @@ jobs:
CIBW_BUILD: "cp310-*"
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
CIBW_MANYLINUX_I686_IMAGE: manylinux2014
- CIBW_BEFORE_BUILD: pip install certifi numpy==1.21.3
+ CIBW_BEFORE_BUILD: pip install certifi oldest-supported-numpy
MPL_DISABLE_FH4: "yes"
CIBW_ARCHS: ${{ matrix.cibw_archs }}
@@ -94,18 +75,18 @@ jobs:
CIBW_BUILD: "cp39-*"
CIBW_MANYLINUX_X86_64_IMAGE: manylinux1
CIBW_MANYLINUX_I686_IMAGE: manylinux1
- CIBW_BEFORE_BUILD: pip install certifi numpy==1.19.3
+ CIBW_BEFORE_BUILD: pip install certifi oldest-supported-numpy
MPL_DISABLE_FH4: "yes"
CIBW_ARCHS: ${{ matrix.cibw_archs }}
- - name: Build wheels for CPython
+ - name: Build wheels for CPython 3.8
run: |
python -m cibuildwheel --output-dir dist
env:
- CIBW_BUILD: "cp37-* cp38-*"
+ CIBW_BUILD: "cp38-*"
CIBW_MANYLINUX_X86_64_IMAGE: manylinux1
CIBW_MANYLINUX_I686_IMAGE: manylinux1
- CIBW_BEFORE_BUILD: pip install certifi; pip install --find-links=numpy-aarch64-cache/ numpy==${{ env.min-numpy-version }}
+ CIBW_BEFORE_BUILD: pip install certifi numpy==1.19.2
MPL_DISABLE_FH4: "yes"
CIBW_ARCHS: ${{ matrix.cibw_archs }}
@@ -113,11 +94,11 @@ jobs:
run: |
python -m cibuildwheel --output-dir dist
env:
- CIBW_BUILD: "pp37-*"
- CIBW_BEFORE_BUILD: pip install certifi numpy==${{ env.min-numpy-version }}
+ CIBW_BUILD: "pp38-*"
+ CIBW_BEFORE_BUILD: pip install certifi oldest-supported-numpy
CIBW_ARCHS: ${{ matrix.cibw_archs }}
PIP_USE_FEATURE: in-tree-build
- if: matrix.cibw_archs != 'aarch64'
+ if: false && matrix.cibw_archs != 'aarch64'
- name: Validate that LICENSE files are included in wheels
run: |
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 3f2cb2bd7fef..13ae3c8d3322 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -26,20 +26,16 @@ jobs:
include:
- name-suffix: "(Minimum Versions)"
os: ubuntu-18.04
- python-version: 3.7
+ python-version: 3.8
extra-requirements: '-c requirements/testing/minver.txt'
- pyqt5-ver: '==5.8 sip==4.19.7' # oldest versions with a Py3.7 wheel.
+ pyqt5-ver: '==5.11.2 sip==5.0.0' # oldest versions with a Py3.8 wheel.
delete-font-cache: true
XVFB_RUN: xvfb-run -a
- - os: ubuntu-18.04
- python-version: 3.7
- extra-requirements: '-r requirements/testing/extra.txt'
- XVFB_RUN: xvfb-run -a
- CFLAGS: "-fno-lto" # Ensure that disabling LTO works.
- os: ubuntu-18.04
python-version: 3.8
extra-requirements: '-r requirements/testing/extra.txt'
XVFB_RUN: xvfb-run -a
+ CFLAGS: "-fno-lto" # Ensure that disabling LTO works.
- os: ubuntu-20.04
python-version: 3.9
extra-requirements: '-r requirements/testing/extra.txt'
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index a35e04b34688..3ed2c5233f16 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -38,33 +38,33 @@ stages:
- job: Pytest
strategy:
matrix:
- Linux_py37:
- vmImage: 'ubuntu-18.04'
- python.version: '3.7'
Linux_py38:
vmImage: 'ubuntu-18.04'
python.version: '3.8'
Linux_py39:
vmImage: 'ubuntu-18.04'
python.version: '3.9'
- macOS_py37:
- vmImage: 'macOS-10.15'
- python.version: '3.7'
+ Linux_py310:
+ vmImage: 'ubuntu-18.04'
+ python.version: '3.10'
macOS_py38:
vmImage: 'macOS-latest'
python.version: '3.8'
macOS_py39:
vmImage: 'macOS-latest'
python.version: '3.9'
- Windows_py37:
- vmImage: 'vs2017-win2016'
- python.version: '3.7'
+ macOS_py310:
+ vmImage: 'macOS-latest'
+ python.version: '3.10'
Windows_py38:
vmImage: 'windows-latest'
python.version: '3.8'
Windows_py39:
vmImage: 'windows-latest'
python.version: '3.9'
+ Windows_py310:
+ vmImage: 'vs2017-win2016'
+ python.version: '3.10'
maxParallel: 4
pool:
vmImage: '$(vmImage)'
diff --git a/doc/api/next_api_changes/development/22205-ES.rst b/doc/api/next_api_changes/development/22205-ES.rst
index cfd8f5afe271..1e500142c0ff 100644
--- a/doc/api/next_api_changes/development/22205-ES.rst
+++ b/doc/api/next_api_changes/development/22205-ES.rst
@@ -7,6 +7,7 @@ being bumped:
+------------+-----------------+---------------+
| Dependency | min in mpl3.5 | min in mpl3.6 |
+============+=================+===============+
+| Python | 3.7 | 3.8 |
| NumPy | 1.17 | 1.19 |
+------------+-----------------+---------------+
diff --git a/doc/devel/coding_guide.rst b/doc/devel/coding_guide.rst
index 2ff18bb8f1f0..cbd2ef8214f3 100644
--- a/doc/devel/coding_guide.rst
+++ b/doc/devel/coding_guide.rst
@@ -271,11 +271,11 @@ The current active branches are
*main*
The current development version. Future minor releases (*v3.N.0*) will be
- branched from this. Supports Python 3.7+.
+ branched from this.
*v3.N.x*
Maintenance branch for Matplotlib 3.N. Future patch releases will be
- branched from this. Supports Python 3.6+.
+ branched from this.
*v3.N.M-doc*
Documentation for the current release. On a patch release, this will be
diff --git a/doc/devel/dependencies.rst b/doc/devel/dependencies.rst
index 90cb04c2bff1..98cbca51b7ab 100644
--- a/doc/devel/dependencies.rst
+++ b/doc/devel/dependencies.rst
@@ -14,7 +14,7 @@ When installing through a package manager like ``pip`` or ``conda``, the
mandatory dependencies are automatically installed. This list is mainly for
reference.
-* `Python `_ (>= 3.7)
+* `Python `_ (>= 3.8)
* `NumPy `_ (>= 1.19)
* `setuptools `_
* `cycler `_ (>= 0.10.0)
diff --git a/doc/devel/min_dep_policy.rst b/doc/devel/min_dep_policy.rst
index d69fd76c4c03..6f0ec95c7969 100644
--- a/doc/devel/min_dep_policy.rst
+++ b/doc/devel/min_dep_policy.rst
@@ -83,7 +83,7 @@ specification of the dependencies.
========== ======== ======
Matplotlib Python NumPy
========== ======== ======
-`3.6`_ 3.7 1.19.0
+`3.6`_ 3.8 1.19.0
`3.5`_ 3.7 1.17.0
`3.4`_ 3.7 1.16.0
`3.3`_ 3.6 1.15.0
diff --git a/doc/devel/testing.rst b/doc/devel/testing.rst
index 65898b95ee0c..dd98c7a6970a 100644
--- a/doc/devel/testing.rst
+++ b/doc/devel/testing.rst
@@ -169,7 +169,7 @@ Using tox
`Tox `_ is a tool for running tests
against multiple Python environments, including multiple versions of Python
-(e.g., 3.6, 3.7) and even different Python implementations altogether
+(e.g., 3.7, 3.8) and even different Python implementations altogether
(e.g., CPython, PyPy, Jython, etc.), as long as all these versions are
available on your system's $PATH (consider using your system package manager,
e.g. apt-get, yum, or Homebrew, to install them).
@@ -186,7 +186,7 @@ You can also run tox on a subset of environments:
.. code-block:: bash
- $ tox -e py37,py38
+ $ tox -e py38,py39
Tox processes everything serially so it can take a long time to test
several environments. To speed it up, you might try using a new,
diff --git a/lib/matplotlib/tests/test_ticker.py b/lib/matplotlib/tests/test_ticker.py
index 5c551a296c3e..24e10c62afbb 100644
--- a/lib/matplotlib/tests/test_ticker.py
+++ b/lib/matplotlib/tests/test_ticker.py
@@ -908,13 +908,12 @@ def logit_deformatter(string):
float 1.41e-4, as '0.5' or as r'$\mathdefault{\frac{1}{2}}$' in float
0.5,
"""
- # Can inline the Unicode escapes to the raw strings in Python 3.8+
match = re.match(
r"[^\d]*"
- r"(?P1" "[-\N{Minus Sign}]" r")?"
+ r"(?P1[-\N{Minus Sign}])?"
r"(?P\d*\.?\d*)?"
r"(?:\\cdot)?"
- r"(?:10\^\{(?P" "[-\N{Minus Sign}]" r"?\d*)})?"
+ r"(?:10\^\{(?P[-\N{Minus Sign}]?\d*)})?"
r"[^\d]*$",
string,
)
diff --git a/requirements/testing/extra.txt b/requirements/testing/extra.txt
index 4582783c743d..e5bb5d86a667 100644
--- a/requirements/testing/extra.txt
+++ b/requirements/testing/extra.txt
@@ -1,4 +1,4 @@
-# Extra pip requirements for the Python 3.7+ builds
+# Extra pip requirements for the Python 3.8+ builds
ipykernel
nbconvert[execute]!=6.0.0,!=6.0.1
diff --git a/requirements/testing/minver.txt b/requirements/testing/minver.txt
index ca07c883d586..30b8124b5bec 100644
--- a/requirements/testing/minver.txt
+++ b/requirements/testing/minver.txt
@@ -4,7 +4,7 @@ cycler==0.10
kiwisolver==1.0.1
numpy==1.19.0
packaging==20.0
-pillow==6.2.0
+pillow==6.2.1
pyparsing==2.2.1
python-dateutil==2.7
fonttools==4.22.0
diff --git a/setup.py b/setup.py
index 34093ff3ac54..0e39e893c3a8 100644
--- a/setup.py
+++ b/setup.py
@@ -8,8 +8,8 @@
# and/or pip.
import sys
-py_min_version = (3, 7) # minimal supported python version
-since_mpl_version = (3, 4) # py_min_version is required since this mpl version
+py_min_version = (3, 8) # minimal supported python version
+since_mpl_version = (3, 6) # py_min_version is required since this mpl version
if sys.version_info < py_min_version:
error = """
@@ -160,12 +160,6 @@ def prepare_flags(name, enable_lto):
return env
def build_extensions(self):
- # Remove the -Wstrict-prototypes option, it's not valid for C++. Fixed
- # in Py3.7 as bpo-5755.
- try:
- self.compiler.compiler_so.remove('-Wstrict-prototypes')
- except (ValueError, AttributeError):
- pass
if (self.compiler.compiler_type == 'msvc' and
os.environ.get('MPL_DISABLE_FH4')):
# Disable FH4 Exception Handling implementation so that we don't
@@ -289,7 +283,6 @@ def make_release_tree(self, base_dir, files):
'License :: OSI Approved :: Python Software Foundation License',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
- 'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
diff --git a/tox.ini b/tox.ini
index b6b94c41b5fc..fc8479269160 100644
--- a/tox.ini
+++ b/tox.ini
@@ -4,7 +4,7 @@
# and then run "tox" from this directory.
[tox]
-envlist = py37, py38
+envlist = py38, py39, py310
[testenv]
changedir = /tmp