Skip to content

Commit 92daa11

Browse files
authored
Merge branch 'master' into optimize_3d
2 parents 867819f + 739b86a commit 92daa11

File tree

405 files changed

+9915
-11940
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

405 files changed

+9915
-11940
lines changed

.appveyor.yml

+5-3
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ branches:
88
except:
99
- /auto-backport-.*/
1010

11+
clone_depth: 50
12+
1113
environment:
1214

1315
global:
@@ -19,12 +21,12 @@ environment:
1921
# theoretically the CONDA_INSTALL_LOCN could be only two: one for 32bit,
2022
# one for 64bit because we construct envs anyway. But using one for the
2123
# right python version is hopefully making it fast due to package caching.
22-
- PYTHON_VERSION: "3.5"
23-
CONDA_INSTALL_LOCN: "C:\\Miniconda35-x64"
24-
TEST_ALL: "no"
2524
- PYTHON_VERSION: "3.6"
2625
CONDA_INSTALL_LOCN: "C:\\Miniconda36-x64"
2726
TEST_ALL: "no"
27+
- PYTHON_VERSION: "3.7"
28+
CONDA_INSTALL_LOCN: "C:\\Miniconda37-x64"
29+
TEST_ALL: "no"
2830

2931
# We always use a 64-bit machine, but can build x86 distributions
3032
# with the PYTHON_ARCH variable

.circleci/config.yml

+15-20
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ mpl-run: &mpl-install
7474

7575
doc-run: &doc-build
7676
name: Build documentation
77-
command: make html
77+
command: make html O=-T
7878
working_directory: doc
7979

8080
doc-bundle-run: &doc-bundle
@@ -97,8 +97,10 @@ jobs:
9797
- run: *apt-install
9898
- run: *fonts-install
9999
- run: *pip-install
100-
101-
- run: *deps-install
100+
- run:
101+
<<: *deps-install
102+
environment:
103+
NUMPY_VERSION: "==1.11.0"
102104
- run: *mpl-install
103105

104106
- run: *doc-build
@@ -114,34 +116,21 @@ jobs:
114116
name: "Built documentation is available at:"
115117
command: echo "${CIRCLE_BUILD_URL}/artifacts/${CIRCLE_NODE_INDEX}/${CIRCLE_WORKING_DIRECTORY/#\~/$HOME}/doc/build/html/index.html"
116118

117-
- add_ssh_keys:
118-
fingerprints:
119-
- "78:13:59:08:61:a9:e5:09:af:df:3a:d8:89:c2:84:c0"
120-
- deploy:
121-
name: "Deploy new docs"
122-
command: ./.circleci/deploy-docs.sh
123-
124-
docs-python35:
119+
docs-python37:
125120
docker:
126-
- image: circleci/python:3.5
121+
- image: circleci/python:3.7
127122
steps:
128123
- checkout
129124

130125
- run: *apt-install
131126
- run: *fonts-install
132127
- run: *pip-install
133128

134-
- run:
135-
<<: *deps-install
136-
environment:
137-
NUMPY_VERSION: "==1.10.0"
129+
- run: *deps-install
138130
- run: *mpl-install
139131

140132
- run: *doc-build
141133

142-
# We don't build the LaTeX docs here, so linkchecker will complain
143-
- run: touch doc/build/html/Matplotlib.pdf
144-
145134
- run: *doc-bundle
146135
- store_artifacts:
147136
path: doc/build/sphinx-gallery-files.tar.gz
@@ -153,6 +142,12 @@ jobs:
153142
name: "Built documentation is available at:"
154143
command: echo "${CIRCLE_BUILD_URL}/artifacts/${CIRCLE_NODE_INDEX}/${CIRCLE_WORKING_DIRECTORY/#\~/$HOME}/doc/build/html/index.html"
155144

145+
- add_ssh_keys:
146+
fingerprints:
147+
- "78:13:59:08:61:a9:e5:09:af:df:3a:d8:89:c2:84:c0"
148+
- deploy:
149+
name: "Deploy new docs"
150+
command: ./.circleci/deploy-docs.sh
156151

157152
#########################################
158153
# Defining workflows gets us parallelism.
@@ -162,5 +157,5 @@ workflows:
162157
version: 2
163158
build:
164159
jobs:
165-
- docs-python35
166160
- docs-python36
161+
- docs-python37

.flake8

+8-13
Original file line numberDiff line numberDiff line change
@@ -30,20 +30,18 @@ per-file-ignores =
3030

3131
matplotlib/_cm.py: E202, E203, E302
3232
matplotlib/_mathtext_data.py: E203, E261
33-
matplotlib/backend_bases.py: E225
34-
matplotlib/backends/_backend_tk.py: E203, E222, E225, E301, E401, E501
33+
matplotlib/backends/_backend_tk.py: E501
3534
matplotlib/backends/backend_agg.py: E302
3635
matplotlib/backends/backend_cairo.py: E203, E221, E402
3736
matplotlib/backends/backend_gtk3.py: E203, E221, E222, E225, E251, E501
3837
matplotlib/backends/backend_pgf.py: E731
39-
matplotlib/backends/qt_editor/formlayout.py: E301, E501
38+
matplotlib/backends/qt_editor/_formlayout.py: E501
4039
matplotlib/font_manager.py: E203, E221, E251, E501
4140
matplotlib/fontconfig_pattern.py: E201, E203, E221, E222, E225
4241
matplotlib/mathtext.py: E201, E202, E203, E211, E221, E222, E225, E251, E301, E402
4342
matplotlib/projections/geo.py: E203, E221, E502
4443
matplotlib/pylab.py: E501
45-
matplotlib/pyplot.py: E302, E701
46-
matplotlib/rcsetup.py: E203, E225, E501
44+
matplotlib/rcsetup.py: E501
4745
matplotlib/sphinxext/plot_directive.py: E402
4846
matplotlib/tests/test_mathtext.py: E501
4947
matplotlib/transforms.py: E201, E202, E203, E501
@@ -58,7 +56,6 @@ per-file-ignores =
5856
mpl_toolkits/axes_grid1/inset_locator.py: E501
5957
mpl_toolkits/axes_grid1/mpl_axes.py: E501
6058
mpl_toolkits/axisartist/angle_helper.py: E221
61-
mpl_toolkits/axisartist/axislines.py: E225, E501
6259
mpl_toolkits/axisartist/clip_path.py: E225, E501
6360
mpl_toolkits/axisartist/floating_axes.py: E225, E402, E501
6461
mpl_toolkits/axisartist/grid_helper_curvelinear.py: E225, E501
@@ -76,17 +73,16 @@ per-file-ignores =
7673
tutorials/colors/colors.py: E402
7774
tutorials/colors/colormap-manipulation.py: E402
7875
tutorials/intermediate/artists.py: E402, E501
79-
tutorials/intermediate/constrainedlayout_guide.py: E402, E501
76+
tutorials/intermediate/constrainedlayout_guide.py: E402
8077
tutorials/intermediate/gridspec.py: E402, E501
8178
tutorials/intermediate/legend_guide.py: E402, E501
8279
tutorials/intermediate/tight_layout_guide.py: E402, E501
8380
tutorials/introductory/customizing.py: E501
8481
tutorials/introductory/images.py: E402, E501
8582
tutorials/introductory/pyplot.py: E402, E501
8683
tutorials/introductory/sample_plots.py: E501
87-
tutorials/introductory/usage.py: E402, E501
84+
tutorials/introductory/usage.py: E501
8885
tutorials/text/annotations.py: E501
89-
tutorials/text/mathtext.py: E501
9086
tutorials/text/pgf.py: E501
9187
tutorials/text/text_intro.py: E402
9288
tutorials/text/text_props.py: E501
@@ -111,7 +107,7 @@ per-file-ignores =
111107
examples/event_handling/poly_editor.py: E501
112108
examples/event_handling/viewlims.py: E501
113109
examples/images_contours_and_fields/affine_image.py: E402
114-
examples/images_contours_and_fields/barb_demo.py: E402, E501
110+
examples/images_contours_and_fields/barb_demo.py: E402
115111
examples/images_contours_and_fields/barcode_demo.py: E402
116112
examples/images_contours_and_fields/contour_corner_mask.py: E402
117113
examples/images_contours_and_fields/contour_demo.py: E402, E501
@@ -186,8 +182,7 @@ per-file-ignores =
186182
examples/pyplots/pyplot_formatstr.py: E231, E402
187183
examples/pyplots/pyplot_mathtext.py: E231, E402
188184
examples/pyplots/pyplot_scales.py: E402
189-
examples/pyplots/pyplot_simple.py: E231
190-
examples/pyplots/pyplot_simple.py: E402
185+
examples/pyplots/pyplot_simple.py: E231, E402
191186
examples/pyplots/pyplot_text.py: E402
192187
examples/pyplots/pyplot_three.py: E402
193188
examples/pyplots/pyplot_two_subplots.py: E302, E402
@@ -257,7 +252,7 @@ per-file-ignores =
257252
examples/user_interfaces/gtk_spreadsheet_sgskip.py: E402
258253
examples/user_interfaces/mathtext_wx_sgskip.py: E402, E501
259254
examples/user_interfaces/mpl_with_glade3_sgskip.py: E402
260-
examples/user_interfaces/pylab_with_gtk_sgskip.py: E402, E501
255+
examples/user_interfaces/pylab_with_gtk_sgskip.py: E302, E402
261256
examples/user_interfaces/toolmanager_sgskip.py: E402
262257
examples/userdemo/custom_boxstyle01.py: E402
263258
examples/userdemo/pgf_preamble_sgskip.py: E402

.lgtm.yml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
path_classifiers:
2+
examples:
3+
# Exclude example files from analysis by tagging them.
4+
# We intentionally use multiple imports and unused variables in the
5+
# examples to make them more explicit. These generate a lot of alerts.
6+
# Since lgtm does not yet support suppressing selected alerts per
7+
# file, we currently deactivate analysis completely here. May be
8+
# reactivated when we can selectively suppress
9+
# - py/import-and-import-from
10+
# - py/repeated-import
11+
# - py/unused-local-variable
12+
# - py/multiple-definition
13+
- examples
14+
- tutorials

.meeseeksdev.yml

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
users:
2+
Carreau:
3+
can:
4+
- backport

.travis.yml

+12-7
Original file line numberDiff line numberDiff line change
@@ -64,20 +64,22 @@ env:
6464
- OPENBLAS_NUM_THREADS=1
6565
- PYTHONFAULTHANDLER=1
6666
- PYTEST_ADDOPTS="-raR --maxfail=50 --timeout=300 --durations=25 --cov-report= --cov=lib -n $NPROC"
67+
- RUN_PYTEST=1
6768
- RUN_FLAKE8=
6869

6970
matrix:
7071
include:
71-
- python: 3.5
72-
dist: trusty
73-
# pytest-cov>=2.3.1 due to https://github.com/pytest-dev/pytest-cov/issues/124.
72+
- name: flake8
73+
python: 3.6
7474
env:
75-
- PINNEDVERS='-c requirements/testing/travis35.txt'
75+
- RUN_PYTEST=
76+
- RUN_FLAKE8=1
77+
- EXTRAREQS='-r requirements/testing/travis_flake8.txt'
7678
- python: 3.6
7779
env:
80+
- PINNEDVERS='-c requirements/testing/travis36minver.txt'
7881
- DELETE_FONT_CACHE=1
7982
- EXTRAREQS='-r requirements/testing/travis36.txt'
80-
- RUN_FLAKE8=1
8183
- python: 3.7
8284
sudo: true
8385
- python: "nightly"
@@ -103,6 +105,7 @@ before_install: |
103105
export PATH=/usr/lib/ccache:$PATH
104106
else
105107
ci/silence brew update
108+
brew uninstall numpy gdal postgis
106109
brew upgrade python
107110
brew install ffmpeg imagemagick mplayer ccache
108111
hash -r
@@ -161,8 +164,10 @@ script:
161164
# each script we want to run need to go in it's own section and the program you want
162165
# to fail travis need to be the last thing called
163166
- |
164-
echo "Calling pytest with the following arguments: $PYTEST_ADDOPTS"
165-
python -mpytest
167+
if [[ $RUN_PYTEST == 1 ]]; then
168+
echo "Calling pytest with the following arguments: $PYTEST_ADDOPTS"
169+
python -mpytest
170+
fi
166171
- |
167172
if [[ $RUN_FLAKE8 == 1 ]]; then
168173
flake8 --statistics && echo "Flake8 passed without any issues!"

INSTALL.rst

+19-32
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ Installing an official release
1515
Matplotlib and its dependencies are available as wheel packages for macOS,
1616
Windows and Linux distributions::
1717

18-
python -mpip install -U pip
19-
python -mpip install -U matplotlib
18+
python -m pip install -U pip
19+
python -m pip install -U matplotlib
2020

2121
.. note::
2222

@@ -133,10 +133,10 @@ Dependencies
133133

134134
Matplotlib requires the following dependencies:
135135

136-
* `Python <https://www.python.org/downloads/>`_ (>= 3.5)
136+
* `Python <https://www.python.org/downloads/>`_ (>= 3.6)
137137
* `FreeType <https://www.freetype.org/>`_ (>= 2.3)
138138
* `libpng <http://www.libpng.org>`_ (>= 1.2)
139-
* `NumPy <http://www.numpy.org>`_ (>= 1.10.0)
139+
* `NumPy <http://www.numpy.org>`_ (>= 1.11)
140140
* `setuptools <https://setuptools.readthedocs.io/en/latest/>`_
141141
* `cycler <http://matplotlib.org/cycler/>`_ (>= 0.10.0)
142142
* `dateutil <https://pypi.org/project/python-dateutil>`_ (>= 2.1)
@@ -170,8 +170,8 @@ etc., you can install the following:
170170
animated gifs;
171171
* `Pillow <https://pillow.readthedocs.io/en/latest/>`_ (>= 3.4): for a larger
172172
selection of image file formats: JPEG, BMP, and TIFF image files;
173-
* `LaTeX <https://miktex.org/>`_ and `GhostScript
174-
<https://ghostscript.com/download/>`_ (for rendering text with LaTeX).
173+
* `LaTeX <https://miktex.org/>`_ and `GhostScript (>=9.0)
174+
<https://ghostscript.com/download/>`_ : for rendering text with LaTeX.
175175

176176
.. note::
177177

@@ -262,8 +262,8 @@ at `matplotlib-winbuild <https://github.com/jbmohler/matplotlib-winbuild>`_.
262262
There are a few possibilities to build Matplotlib on Windows:
263263

264264
* Wheels via `matplotlib-winbuild <https://github.com/jbmohler/matplotlib-winbuild>`_
265-
* Wheels by using conda packages
266-
* Conda packages
265+
* Wheels by using conda packages (see below)
266+
* Conda packages (see below)
267267

268268
Wheel builds using conda packages
269269
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -272,32 +272,19 @@ This is a wheel build, but we use conda packages to get all the requirements.
272272
The binary requirements (png, FreeType,...) are statically linked and therefore
273273
not needed during the wheel install.
274274

275+
Set up the conda environment. Note, if you want a qt backend, add ``pyqt`` to
276+
the list of conda packages.
277+
275278
::
276279

277-
# create a new environment with the required packages
278-
conda create -n "matplotlib_build" python=3.5 numpy python-dateutil pyparsing pytz tornado cycler tk libpng zlib freetype
279-
activate matplotlib_build
280-
# if you want a qt backend, you also have to install pyqt (be aware that pyqt doesn't mix well if
281-
# you have created the environment with conda-forge already activated...)
282-
conda install pyqt
283-
# this package is only available in the conda-forge channel
284-
conda install -c conda-forge msinttypes
285-
286-
# copy the libs which have "wrong" names
287-
set LIBRARY_LIB=%CONDA_PREFIX%\Library\lib
288-
mkdir lib || cmd /c "exit /b 0"
289-
copy %LIBRARY_LIB%\zlibstatic.lib lib\z.lib
290-
copy %LIBRARY_LIB%\libpng_static.lib lib\png.lib
291-
292-
# Make the header files and the rest of the static libs available during the build
293-
# CONDA_DEFAULT_ENV is a env variable which is set to the currently active environment path
294-
set MPLBASEDIRLIST=%CONDA_PREFIX%\Library\;.
295-
296-
# build the wheel
297-
python setup.py bdist_wheel
298-
299-
The `build_alllocal.cmd` script in the root folder automates these steps if
300-
you have already created and activated the conda environment.
280+
conda create -n "matplotlib_build" python=3.7 numpy python-dateutil pyparsing tornado cycler tk libpng zlib freetype msinttypes
281+
conda activate matplotlib_build
282+
283+
For building, call the script ``build_alllocal.cmd`` in the root folder of the
284+
repository::
285+
286+
build_alllocal.cmd
287+
301288

302289
Conda packages
303290
^^^^^^^^^^^^^^

README.rst

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
1-
|Travis|_ |AppVeyor|_ |Codecov|_ |LGTM|_ |PyPi|_ |Gitter|_ |NUMFocus|_
1+
|Travis|_ |AzurePipelines|_ |AppVeyor|_ |Codecov|_ |LGTM|_ |PyPi|_ |Gitter|_ |NUMFocus|_ |GitTutorial|_
22

33

44
.. |Travis| image:: https://travis-ci.org/matplotlib/matplotlib.svg?branch=master
55
.. _Travis: https://travis-ci.org/matplotlib/matplotlib
66

7+
.. |AzurePipelines| image:: https://dev.azure.com/matplotlib/matplotlib/_apis/build/status/matplotlib.matplotlib?branchName=master
8+
.. _AzurePipelines: https://dev.azure.com/matplotlib/matplotlib/_build/latest?definitionId=1&branchName=master
9+
710
.. |AppVeyor| image:: https://ci.appveyor.com/api/projects/status/github/matplotlib/matplotlib?branch=master&svg=true
811
.. _AppVeyor: https://ci.appveyor.com/project/matplotlib/matplotlib
912

@@ -22,6 +25,8 @@
2225
.. |NUMFocus| image:: https://img.shields.io/badge/powered%20by-NumFOCUS-orange.svg?style=flat&colorA=E1523D&colorB=007D8A
2326
.. _NUMFocus: http://www.numfocus.org
2427

28+
.. |GitTutorial| image:: https://img.shields.io/badge/PR-Welcome-%23FF8300.svg?
29+
.. _GitTutorial: https://git-scm.com/book/en/v2/GitHub-Contributing-to-a-Project
2530

2631
##########
2732
Matplotlib
@@ -86,4 +91,4 @@ You want to tell us about it – best of all!
8691

8792
Start at the `contributing guide <http://matplotlib.org/devdocs/devel/contributing.html>`_!
8893

89-
Developer notes are now at `Developer Discussions <https://github.com/orgs/matplotlib/teams/developers/discussions>`_
94+
Developer notes are now at `Developer Discussions <https://github.com/orgs/matplotlib/teams/developers/discussions>`_ (Note: For technical reasons, this is currently only accessible for matplotlib developers.)

0 commit comments

Comments
 (0)