Skip to content

Commit 3247e7d

Browse files
authored
Merge branch 'matplotlib:main' into fail-filter
2 parents 984d8cb + c1a55a4 commit 3247e7d

File tree

27 files changed

+193
-97
lines changed

27 files changed

+193
-97
lines changed

.circleci/config.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ commands:
147147
export RELEASE_TAG='-t release'
148148
fi
149149
mkdir -p logs
150-
make html O="-T $RELEASE_TAG -j4 -w /tmp/sphinxerrorswarnings.log"
150+
make html O="-T $RELEASE_TAG -j1 -w /tmp/sphinxerrorswarnings.log"
151151
rm -r build/html/_sources
152152
working_directory: doc
153153
- save_cache:

.github/workflows/cibuildwheel.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,4 +213,4 @@ jobs:
213213
run: ls dist
214214

215215
- name: Publish package distributions to PyPI
216-
uses: pypa/gh-action-pypi-publish@2f6f737ca5f74c637829c0f5c3acd0e29ea5e8bf # v1.8.11
216+
uses: pypa/gh-action-pypi-publish@e53eb8b103ffcb59469888563dc324e3c8ba6f06 # v1.8.12

.github/workflows/cygwin.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ jobs:
243243
shell: bash.exe -eo pipefail -o igncr "{0}"
244244
id: cygwin-run-pytest
245245
run: |
246-
xvfb-run pytest -rfEsXR -n auto \
246+
xvfb-run pytest-3.${{ matrix.python-minor-version }} -rfEsXR -n auto \
247247
--maxfail=50 --timeout=300 --durations=25 \
248248
--cov-report=xml --cov=lib --log-level=DEBUG --color=yes
249249

.github/workflows/nightlies.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ jobs:
5959
ls -l dist/
6060
6161
- name: Upload wheels to Anaconda Cloud as nightlies
62-
uses: scientific-python/upload-nightly-action@6e9304f7a3a5501c6f98351537493ec898728299 # 0.3.0
62+
uses: scientific-python/upload-nightly-action@b67d7fcc0396e1128a474d1ab2b48aa94680f9fc # 0.5.0
6363
with:
6464
artifacts_path: dist
6565
anaconda_nightly_upload_token: ${{ secrets.ANACONDA_ORG_UPLOAD_TOKEN }}

doc/_static/mpl.css

Lines changed: 0 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -14,29 +14,6 @@
1414
margin: 0;
1515
}
1616

17-
/* Make announcement an error colour for unreleased documentation, and sticky. */
18-
#unreleased-message.bd-header-announcement {
19-
border-bottom: solid var(--pst-color-danger-highlight);
20-
color: var(--pst-color-danger-text);
21-
font-weight: var(--pst-admonition-font-weight-heading);
22-
position: sticky;
23-
top: 0;
24-
z-index: 1050;
25-
}
26-
27-
#unreleased-message.bd-header-announcement:after {
28-
background-color: var(--pst-color-danger);
29-
opacity: 1;
30-
}
31-
32-
#unreleased-message.bd-header-announcement a {
33-
color: var(--pst-color-danger-text);
34-
}
35-
36-
#unreleased-message.bd-header-announcement + .bd-navbar {
37-
top: 3rem; /* Minimum height of announcement header. */
38-
}
39-
4017
/* multi column TOC */
4118
.contents ul {
4219
list-style-type: none;
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
``plot_date``
2+
~~~~~~~~~~~~~
3+
4+
Use of `~.Axes.plot_date` has been discouraged since Matplotlib 3.5 and the
5+
function is now formally deprecated.
6+
7+
- ``datetime``-like data should directly be plotted using `~.Axes.plot`.
8+
- If you need to plot plain numeric data as :ref:`date-format` or need to set
9+
a timezone, call ``ax.xaxis.axis_date`` / ``ax.yaxis.axis_date`` before
10+
`~.Axes.plot`. See `.Axis.axis_date`.

doc/conf.py

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,7 @@ def _check_dependencies():
200200
missing_references_write_json = False
201201
missing_references_warn_unused_ignores = False
202202

203+
203204
intersphinx_mapping = {
204205
'Pillow': ('https://pillow.readthedocs.io/en/stable/', None),
205206
'cycler': ('https://matplotlib.org/cycler/', None),
@@ -484,15 +485,21 @@ def js_tag_with_cache_busting(js):
484485
# the server, but will be used as part of the key for caching by browsers
485486
# so when we do a new meso release the switcher will update "promptly" on
486487
# the stable and devdocs.
487-
"json_url": f"https://matplotlib.org/devdocs/_static/switcher.json?{SHA}",
488+
"json_url": (
489+
"https://output.circle-artifacts.com/output/job/"
490+
f"{os.environ['CIRCLE_WORKFLOW_JOB_ID']}/artifacts/"
491+
f"{os.environ['CIRCLE_NODE_INDEX']}"
492+
"/doc/build/html/_static/switcher.json" if CIRCLECI else
493+
f"https://matplotlib.org/devdocs/_static/switcher.json?{SHA}"
494+
),
488495
"version_match": (
489496
# The start version to show. This must be in switcher.json.
490497
# We either go to 'stable' or to 'devdocs'
491498
'stable' if matplotlib.__version_info__.releaselevel == 'final'
492499
else 'devdocs')
493500
},
494501
"navbar_end": ["theme-switcher", "version-switcher", "mpl_icon_links"],
495-
"secondary_sidebar_items": "page-toc.html",
502+
"navbar_persistent": ["search-button"],
496503
"footer_start": ["copyright", "sphinx-version", "doc_version"],
497504
# We override the announcement template from pydata-sphinx-theme, where
498505
# this special value indicates the use of the unreleased banner. If we need
@@ -543,6 +550,9 @@ def js_tag_with_cache_busting(js):
543550
# '**': ['localtoc.html', 'pagesource.html']
544551
}
545552

553+
# Don't include link to doc source files
554+
html_show_sourcelink = False
555+
546556
# Copies only relevant code, not the '>>>' prompt
547557
copybutton_prompt_text = r'>>> |\.\.\. '
548558
copybutton_prompt_is_regexp = True

environment.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ dependencies:
3434
- ipywidgets
3535
- numpydoc>=1.0
3636
- packaging>=20
37-
- pydata-sphinx-theme~=0.13.1
37+
- pydata-sphinx-theme~=0.15.0
3838
- pyyaml
3939
- sphinx>=3.0.0,!=6.1.2
4040
- sphinx-copybutton
@@ -59,7 +59,7 @@ dependencies:
5959
- psutil
6060
- pre-commit
6161
- pydocstyle>=5.1.0
62-
- pytest!=4.6.0,!=5.4.0
62+
- pytest!=4.6.0,!=5.4.0,!=8.1.0
6363
- pytest-cov
6464
- pytest-rerunfailures
6565
- pytest-timeout

lib/matplotlib/axes/_axes.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1742,17 +1742,17 @@ def plot(self, *args, scalex=True, scaley=True, data=None, **kwargs):
17421742
self._request_autoscale_view("y")
17431743
return lines
17441744

1745+
@_api.deprecated("3.9", alternative="plot")
17451746
@_preprocess_data(replace_names=["x", "y"], label_namer="y")
17461747
@_docstring.dedent_interpd
17471748
def plot_date(self, x, y, fmt='o', tz=None, xdate=True, ydate=False,
17481749
**kwargs):
17491750
"""
1750-
[*Discouraged*] Plot coercing the axis to treat floats as dates.
1751+
Plot coercing the axis to treat floats as dates.
17511752
1752-
.. admonition:: Discouraged
1753+
.. deprecated:: 3.9
17531754
1754-
This method exists for historic reasons and will be deprecated in
1755-
the future.
1755+
This method exists for historic reasons and will be removed in version 3.11.
17561756
17571757
- ``datetime``-like data should directly be plotted using
17581758
`~.Axes.plot`.

lib/matplotlib/backends/backend_pdf.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2755,8 +2755,7 @@ def savefig(self, figure=None, **kwargs):
27552755
raise ValueError(f"No figure {figure}")
27562756
figure = manager.canvas.figure
27572757
# Force use of pdf backend, as PdfPages is tightly coupled with it.
2758-
with cbook._setattr_cm(figure, canvas=FigureCanvasPdf(figure)):
2759-
figure.savefig(self, format="pdf", **kwargs)
2758+
figure.savefig(self, format="pdf", backend="pdf", **kwargs)
27602759

27612760
def get_pagecount(self):
27622761
"""Return the current number of pages in the multipage pdf file."""

0 commit comments

Comments
 (0)