-
-
Notifications
You must be signed in to change notification settings - Fork 8k
API: only support python 3.5+ #10425
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
Changes from all commits
579726c
2cac22c
e3442ae
c36902c
b1ffc81
fc4ace6
08b5466
60cc718
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -99,6 +99,8 @@ | |
to MATLAB®, a registered trademark of The MathWorks, Inc. | ||
|
||
""" | ||
# NOTE: This file must remain Python 2 compatible for the forseeable future, | ||
# to ensure that we error out properly for existing editable installs. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In that case it may be worth having a test entry that just tries to |
||
from __future__ import absolute_import, division, print_function | ||
|
||
import six | ||
|
@@ -122,6 +124,17 @@ | |
import tempfile | ||
import warnings | ||
|
||
if sys.version_info < (3, 5): # noqa: E402 | ||
raise ImportError(""" | ||
Matplotlib 3.0+ does not support Python 2.x, 3.0, 3.1, 3.2, 3.3, or 3.4. | ||
Beginning with Matplotlib 3.0, Python 3.5 and above is required. | ||
|
||
See Matplotlib `INSTALL.rst` file for more information: | ||
|
||
https://github.com/matplotlib/matplotlib/blob/master/INSTALL.rst | ||
|
||
""") | ||
|
||
# cbook must import matplotlib only within function | ||
# definitions, so it is safe to import from it here. | ||
from . import cbook | ||
|
@@ -142,7 +155,7 @@ | |
|
||
_log = logging.getLogger(__name__) | ||
|
||
__version__numpy__ = str('1.7.1') # minimum required numpy version | ||
__version__numpy__ = str('1.10.0') # minimum required numpy version | ||
|
||
__bibtex__ = r"""@Article{Hunter:2007, | ||
Author = {Hunter, J. D.}, | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,9 @@ | |
setup.cfg.template for more information. | ||
""" | ||
|
||
# NOTE: This file must remain Python 2 compatible for the forseeable future, | ||
# to ensure that we error out properly for people with outdated setuptools | ||
# and/or pip. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would just move the version check here and allow setupext to use Py3. |
||
from __future__ import print_function, absolute_import | ||
from string import Template | ||
from setuptools import setup | ||
|
@@ -265,6 +268,7 @@ def run(self): | |
classifiers=classifiers, | ||
download_url="http://matplotlib.org/users/installing.html", | ||
|
||
python_requires='>=3.5', | ||
# List third-party Python packages that we require | ||
install_requires=install_requires, | ||
setup_requires=setup_requires, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of changing all calls to
pip
topython -mpip
it would be easier to change all calls topython
to bepython3
and all calls topip
to bepip3
. That would avoid the need for the symlink.