8000 Merge branch '3d_dynamic_masking' of github.com:scottshambaugh/matplo… · matplotlib/matplotlib@2ebe03e · GitHub
[go: up one dir, main page]

Skip to content

Commit 2ebe03e

Browse files
Merge branch '3d_dynamic_masking' of github.com:scottshambaugh/matplotlib into 3d_dynamic_masking
2 parents 7506e37 + bb36351 commit 2ebe03e

Some content is hidden

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

71 files changed

+4133
-689
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ commands:
9898
parameters:
9999
numpy_version:
100100
type: string
101-
default: ""
101+
default: "!=2.1.0"
102102
steps:
103103
- run:
104104
name: Install Python dependencies

.github/workflows/cibuildwheel.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,15 @@ jobs:
100100
CIBW_AFTER_BUILD: >-
101101
twine check {wheel} &&
102102
python {package}/ci/check_wheel_licenses.py {wheel}
103-
CIBW_CONFIG_SETTINGS: setup-args="--vsenv"
103+
# On Windows, we explicitly request MSVC compilers (as GitHub Action runners have
104+
# MinGW on PATH that would be picked otherwise), switch to a static build for
105+
# runtimes, but use dynamic linking for `VCRUNTIME140.dll`, `VCRUNTIME140_1.dll`,
106+
# and the UCRT. This avoids requiring specific versions of `MSVCP140.dll`, while
107+
# keeping shared state with the rest of the Python process/extensions.
108+
CIBW_CONFIG_SETTINGS_WINDOWS: >-
109+
setup-args="--vsenv"
110+
setup-args="-Db_vscrt=mt"
111+
setup-args="-Dcpp_link_args=['ucrt.lib','vcruntime.lib','/nodefaultlib:libucrt.lib','/nodefaultlib:libvcruntime.lib']"
104112
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
105113
CIBW_SKIP: "*-musllinux_aarch64"
106114
CIBW_TEST_COMMAND: >-
@@ -144,7 +152,6 @@ jobs:
144152
CIBW_SKIP: "cp313t-win_amd64 *-musllinux_aarch64"
145153
CIBW_BUILD_FRONTEND:
146154
"pip; args: --pre --extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple"
147-
CIBW_PRERELEASE_PYTHONS: true
148155
CIBW_FREE_THREADED_SUPPORT: true
149156
# No free-threading wheels available for aarch64 on Pillow.
150157
CIBW_TEST_SKIP: "cp313t-manylinux_aarch64"
@@ -186,6 +193,14 @@ jobs:
186193
env:
187194
CIBW_BUILD: "pp310-*"
188195
CIBW_ARCHS: ${{ matrix.cibw_archs }}
196+
# Work around for https://github.com/pypa/setuptools/issues/4571
197+
# This can be removed once kiwisolver has wheels for PyPy 3.10
198+
# https://github.com/nucleic/kiwi/pull/182
199+
CIBW_BEFORE_TEST: >-
200+
export PIP_CONSTRAINT=pypy-constraint.txt &&
201+
echo "setuptools!=72.2.0" > $PIP_CONSTRAINT &&
202+
pip install kiwisolver &&
203+
unset PIP_CONSTRAINT
189204
if: matrix.cibw_archs != 'aarch64' && matrix.os != 'windows-latest'
190205

191206
- uses: actions/upload-artifact@v4
@@ -216,7 +231,7 @@ jobs:
216231
run: ls dist
217232

218233
- name: Generate artifact attestation for sdist and wheel
219-
uses: actions/attest-build-provenance@210c1913531870065f03ce1f9440dd87bc0938cd # v1.4.0
234+
uses: actions/attest-build-provenance@310b0a4a3b0b78ef57ecda988ee04b132db73ef8 # v1.4.1
220235
with:
221236
subject-path: dist/matplotlib-*
222237

.github/workflows/tests.yml

Lines changed: 55 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,19 @@ jobs:
8585
pyqt6-ver: '!=6.6.0'
8686
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
8787
pyside6-ver: '!=6.5.1'
88+
- os: ubuntu-22.04
89+
python-version: '3.13'
90+
# https://www.riverbankcomputing.com/pipermail/pyqt/2023-November/045606.html
91+
pyqt6-ver: '!=6.6.0'
92+
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
93+
pyside6-ver: '!=6.5.1'
94+
- name-suffix: "Free-threaded"
95+
os: ubuntu-22.04
96+
python-version: '3.13t'
97+
# https://www.riverbankcomputing.com/pipermail/pyqt/2023-November/045606.html
98+
pyqt6-ver: '!=6.6.0'
99+
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
100+
pyside6-ver: '!=6.5.1'
88101
- os: macos-12 # This runner is on Intel chips.
89102
python-version: '3.10'
90103
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
@@ -93,6 +106,10 @@ jobs:
93106
python-version: '3.12'
94107
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
95108
pyside6-ver: '!=6.5.1'
109+
- os: macos-14 # This runner is on M1 (arm64) chips.
110+
python-version: '3.13'
111+
# https://bugreports.qt.io/projects/PYSIDE/issues/PYSIDE-2346
112+
pyside6-ver: '!=6.5.1'
96113

97114
steps:
98115
- uses: actions/checkout@v4
@@ -101,8 +118,17 @@ jobs:
101118

102119
- name: Set up Python ${{ matrix.python-version }}
103120
uses: actions/setup-python@v5
121+
if: matrix.python-version != '3.13t'
104122
with:
105123
python-version: ${{ matrix.python-version }}
124+
allow-prereleases: true
125+
126+
- name: Set up Python ${{ matrix.python-version }}
127+
uses: deadsnakes/action@6c8b9b82fe0b4344f4b98f2775fcc395df45e494 # v3.1.0
128+
if: matrix.python-version == '3.13t'
129+
with:
130+
python-version: '3.13'
131+
nogil: true
106132

107133
- name: Install OS dependencies
108134
run: |
@@ -149,6 +175,11 @@ jobs:
149175
texlive-luatex \
150176
texlive-pictures \
151177
texlive-xetex
178+
if [[ "${{ matrix.python-version }}" = '3.13t' ]]; then
179+
# TODO: Remove this once setup-python supports nogil distributions.
180+
sudo apt-get install -yy --no-install-recommends \
181+
python3.13-tk-nogil
182+
fi
152183
if [[ "${{ matrix.os }}" = ubuntu-20.04 ]]; then
153184
sudo apt-get install -yy --no-install-recommends libopengl0
154185
else # ubuntu-22.04
@@ -158,7 +189,13 @@ jobs:
158189
;;
159190
macOS)
160191
brew update
161-
brew install ccache ghostscript gobject-introspection gtk4 ninja
192+
export HOMEBREW_NO_INSTALL_UPGRADE=1 HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1
193+
brew install ccache ghostscript ninja
194+
# The macOS 12 images have an older Python, and this causes homebrew to generate conflicts.
195+
# We'll just skip GTK for now, to not pull in Python updates.
196+
if [[ "${{ matrix.os }}" = macos-14 ]]; then
197+
brew install gobject-introspection gtk4
198+
fi
162199
brew install --cask font-noto-sans-cjk inkscape
163200
;;
164201
esac
@@ -199,6 +236,15 @@ jobs:
199236
4-${{ runner.os }}-py${{ matrix.python-version }}-mpl-${{ github.ref }}-
200237
4-${{ runner.os }}-py${{ matrix.python-version }}-mpl-
201238
239+
- name: Install the nightly dependencies
240+
if: matrix.python-version == '3.13t'
241+
run: |
242+
python -m pip install pytz tzdata python-dateutil # Must be installed for Pandas.
243+
python -m pip install \
244+
--pre \
245+
--index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple \
246+
--upgrade --only-binary=:all: numpy pandas pillow contourpy
247+
202248
- name: Install Python dependencies
203249
run: |
204250
# Upgrade pip and setuptools and wheel to get as clean an install as
@@ -224,6 +270,7 @@ jobs:
224270
# Sphinx is needed to run sphinxext tests
225271
python -m pip install --upgrade sphinx!=6.1.2
226272
273+
if [[ "${{ matrix.python-version }}" != '3.13t' ]]; then
227274
# GUI toolkits are pip-installable only for some versions of Python
228275
# so don't fail if we can't install them. Make it easier to check
229276
# whether the install was successful by trying to import the toolkit
@@ -243,11 +290,11 @@ jobs:
243290
python -c 'import PyQt5.QtCore' &&
244291
echo 'PyQt5 is available' ||
245292
echo 'PyQt5 is not available'
246-
# Even though PySide2 wheels can be installed on Python 3.12, they are broken and since PySide2 is
293+
# Even though PySide2 wheels can be installed on Python 3.12+, they are broken and since PySide2 is
247294
# deprecated, they are unlikely to be fixed. For the same deprecation reason, there are no wheels
248295
# on M1 macOS, so don't bother there either.
249296
if [[ "${{ matrix.os }}" != 'macos-14'
250-
&& "${{ matrix.python-version }}" != '3.12' ]]; then
297+
&& "${{ matrix.python-version }}" != '3.12' && "${{ matrix.python-version }}" != '3.13' ]]; then
251298
python -mpip install --upgrade pyside2${{ matrix.pyside2-ver }} &&
252299
python -c 'import PySide2.QtCore' &&
253300
echo 'PySide2 is available' ||
@@ -269,6 +316,8 @@ jobs:
269316
echo 'wxPython is available' ||
270317
echo 'wxPython is not available'
271318
319+
fi # Skip backends on Python 3.13t.
320+
272321
- name: Install the nightly dependencies
273322
# Only install the nightly dependencies during the scheduled event
274323
if: github.event_name == 'schedule' && matrix.name-suffix != '(Minimum Versions)'
@@ -307,6 +356,9 @@ jobs:
307356

308357
- name: Run pytest
309358
run: |
359+
if [[ "${{ matrix.python-version }}" == '3.13t' ]]; then
360+
export PYTHON_GIL=0
361+
fi
310362
pytest -rfEsXR -n auto \
311363
--maxfail=50 --timeout=300 --durations=25 \
312364
--cov-report=xml --cov=lib --log-level=DEBUG --color=yes

azure-pipelines.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ stages:
111111
;;
112112
Darwin)
113113
brew update
114+
export HOMEBREW_NO_INSTALL_UPGRADE=1 HOMEBREW_NO_INSTALLED_DEPENDENTS_CHECK=1
114115
brew install --cask xquartz
115116
brew install ccache ffmpeg imagemagick mplayer ninja pkg-config
116117
brew install --cask font-noto-sans-cjk-sc

doc/_static/switcher.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[
22
{
33
"name": "3.9 (stable)",
4-
"version": "3.9.1",
4+
"version": "3.9.2",
55
"url": "https://matplotlib.org/stable/",
66
"preferred": true
77
},

doc/_static/zenodo_cache/13308876.svg

Lines changed: 35 additions & 0 deletions
Loading
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
ft2font classes are now final
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
The ft2font classes `.ft2font.FT2Font`, and `.ft2font.FT2Image` are now final
5+
and can no longer be subclassed.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
The offset string associated with ConciseDateFormatter will now invert when the axis is inverted
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
Previously, when the axis was inverted, the offset string associated with ConciseDateFormatter would not change,
4+
so the offset string indicated the axis was oriented in the wrong direction. Now, when the axis is inverted, the offset
5+
string is oriented correctly.
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
``suptitle`` in compressed layout
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
Compressed layout now automatically positions the `~.Figure.suptitle` just
5+
above the top row of axes. To keep this title in its previous position,
6+
either pass ``in_layout=False`` or explicitly set ``y=0.98`` in the
7+
`~.Figure.suptitle` call.
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
matplotlib.validate_backend
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
...is deprecated. Please use `matplotlib.rcsetup.validate_backend` instead.
5+
6+
7+
matplotlib.sanitize_sequence
8+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9+
10+
...is deprecated. Please use `matplotlib.cbook.sanitize_sequence` instead.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
``ft2font.FT2Image.draw_rect`` and ``ft2font.FT2Font.get_xys``
2+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
3+
4+
... have been removed as they are unused.
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
API Changes for 3.9.2
2+
=====================
3+
4+
Development
5+
-----------
6+
7+
Windows wheel runtime bundling made static
8+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9+
10+
In 3.7.0, the MSVC runtime DLL was bundled in wheels to enable importing Matplotlib on
11+
systems that do not have it installed. However, this could cause inconsistencies with
12+
other wheels that did the same, and trigger random crashes depending on import order. See
13+
`this issue <https://github.com/matplotlib/matplotlib/issues/28551>`_ for further
14+
details.
15+
16+
Since 3.9.2, wheels now bundle the MSVC runtime DLL statically to avoid such issues.

doc/devel/contribute.rst

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,24 @@ please reach out on the :ref:`contributor_incubator`
158 17AE 158

159159
.. _`open an issue`: https://github.com/matplotlib/matplotlib/issues/new?assignees=&labels=Documentation&projects=&template=documentation.yml&title=%5BDoc%5D%3A+
160160

161+
.. _contribute_triage:
162+
< F41A /td>
163+
Triage
164+
------
165+
We appreciate your help keeping the `issue tracker <https://github.com/matplotlib/matplotlib/issues>`_
166+
organized because it is our centralized location for feature requests,
167+
bug reports, tracking major projects, and discussing priorities. Some examples of what
168+
we mean by triage are:
169+
170+
* labeling issues and pull requests
171+
* verifying bug reports
172+
* debugging and resolving issues
173+
* linking to related issues, discussion, and external work
174+
175+
Our triage process is discussed in detail in :ref:`bug_triaging`.
176+
177+
If you have any questions about the process, please reach out on the
178+
:ref:`contributor_incubator`
161179

162180
.. _other_ways_to_contribute:
163181

doc/devel/index.rst

Lines changed: 30 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -84,43 +84,63 @@ to contributing, we recommend that you first read our
8484
contribute
8585

8686
.. grid:: 1 1 2 2
87-
:class-row: sd-align-minor-center
87+
:class-row: sd-fs-5 sd-align-minor-center
8888

8989
.. grid-item::
90-
:class: sd-fs-5
9190

92-
:octicon:`info;1em;sd-text-info` :ref:`Where should I start? <start-contributing>`
91+
.. grid:: 1
92+
:gutter: 1
93+
94+
.. grid-item::
95+
96+
:octicon:`info;1em;sd-text-info` :ref:`Where should I start? <start-contributing>`
97+
98+
.. grid-item::
99+
100+
:octicon:`question;1em;sd-text-info` :ref:`Where should I ask questions? <get_connected>`
93101

94-
:octicon:`question;1em;sd-text-info` :ref:`Where should I ask questions? <get_connected>`
102+
.. grid-item::
95103

96-
:octicon:`git-pull-request;1em;sd-text-info` :ref:`How do I work on an issue? <managing_issues_prs>`
104+
:octicon:`git-pull-request;1em;sd-text-info` :ref:`How do I work on an issue? <managing_issues_prs>`
97105

98-
:octicon:`codespaces;1em;sd-text-info` :ref:`How do I start a pull request? <how-to-pull-request>`
106+
.. grid-item::
107+
108+
:octicon:`codespaces;1em;sd-text-info` :ref:`How do I start a pull request? <how-to-pull-request>`
99109

100110
.. grid-item::
101111

102112
.. grid:: 1
103113
:gutter: 1
104-
:class-row: sd-fs-5
105114

106115
.. grid-item-card::
107116
:link: contribute_code
108117
:link-type: ref
109-
:shadow: none
118+
:class-card: sd-shadow-none
119+
:class-body: sd-text-{primary}
110120

111121
:octicon:`code;1em;sd-text-info` Contribute code
112122

113123
.. grid-item-card::
114124
:link: contribute_documentation
115125
:link-type: ref
116-
:shadow: none
126+
:class-card: sd-shadow-none
127+
:class-body: sd-text-{primary}
117128

118129
:octicon:`note;1em;sd-text-info` Write documentation
119130

131+
.. grid-item-card::
132+
:link: contribute_triage
133+
:link-type: ref
134+
:class-card: sd-shadow-none
135+
:class-body: sd-text-{primary}
136+
137+
:octicon:`issue-opened;1em;sd-text-info` Triage issues
138+
120139
.. grid-item-card::
121140
:link: other_ways_to_contribute
122141
:link-type: ref
123-
:shadow: none
142+
:class-card: sd-shadow-none
143+
:class-body: sd-text-{primary}
124144

125145
:octicon:`globe;1em;sd-text-info` Build community
126146

0 commit comments

Comments
 (0)
0