Skip to content

Commit 2cf4c7d

Browse files
keewismax-sixty
authored andcommitted
fix the failing docs (pydata#8188)
* don't try to build with `pandas=2.1.0` one of the docstrings we inherit from `pandas` is malformatted in that version * reorder the project metadata sections * source the exhaustive list of optional deps from `pyproject.toml` * link to the new location of the colormap tutorial in matplotlib * also convert the narrative documentation to `pyproject.toml`
1 parent 056f427 commit 2cf4c7d

File tree

5 files changed

+23
-23
lines changed

5 files changed

+23
-23
lines changed

ci/requirements/doc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ dependencies:
2121
- numba
2222
- numpy>=1.21
2323
- packaging>=21.3
24-
- pandas>=1.4
24+
- pandas>=1.4,!=2.1.0
2525
- pooch
2626
- pip
2727
- pre-commit

doc/getting-started-guide/installing.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -135,13 +135,13 @@ We also maintain other dependency sets for different subsets of functionality::
135135
The above commands should install most of the `optional dependencies`_. However,
136136
some packages which are either not listed on PyPI or require extra
137137
installation steps are excluded. To know which dependencies would be
138-
installed, take a look at the ``[options.extras_require]`` section in
139-
``setup.cfg``:
138+
installed, take a look at the ``[project.optional-dependencies]`` section in
139+
``pyproject.toml``:
140140

141-
.. literalinclude:: ../../setup.cfg
142-
:language: ini
143-
:start-at: [options.extras_require]
144-
:end-before: [options.package_data]
141+
.. literalinclude:: ../../pyproject.toml
142+
:language: toml
143+
:start-at: [project.optional-dependencies]
144+
:end-before: [build-system]
145145

146146
Development versions
147147
--------------------

pyproject.toml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -27,33 +27,33 @@ dependencies = [
2727
"pandas>=1.4",
2828
]
2929

30-
[project.optional-dependencies]
31-
accel = ["scipy", "bottleneck", "numbagg", "flox"]
32-
complete = ["xarray[accel,io,parallel,viz]"]
33-
io = ["netCDF4", "h5netcdf", "scipy", 'pydap; python_version<"3.10"', "zarr", "fsspec", "cftime", "pooch"]
34-
parallel = ["dask[complete]"]
35-
viz = ["matplotlib", "seaborn", "nc-time-axis"]
36-
37-
[tool.setuptools]
38-
packages = ["xarray"]
39-
40-
[project.entry-points."xarray.chunkmanagers"]
41-
dask = "xarray.core.daskmanager:DaskManager"
42-
4330
[project.urls]
4431
Documentation = "https://docs.xarray.dev"
4532
SciPy2015-talk = "https://www.youtube.com/watch?v=X0pAhJgySxk"
4633
homepage = "https://xarray.dev/"
4734
issue-tracker = "https://github.com/pydata/xarray/issues"
4835
source-code = "https://github.com/pydata/xarray"
4936

37+
[project.entry-points."xarray.chunkmanagers"]
38+
dask = "xarray.core.daskmanager:DaskManager"
39+
40+
[project.optional-dependencies]
41+
accel = ["scipy", "bottleneck", "numbagg", "flox"]
42+
complete = ["xarray[accel,io,parallel,viz]"]
43+
io = ["netCDF4", "h5netcdf", "scipy", 'pydap; python_version<"3.10"', "zarr", "fsspec", "cftime", "pooch"]
44+
parallel = ["dask[complete]"]
45+
viz = ["matplotlib", "seaborn", "nc-time-axis"]
46+
5047
[build-system]
5148
build-backend = "setuptools.build_meta"
5249
requires = [
5350
"setuptools>=42",
5451
"setuptools-scm>=7",
5552
]
5653

54+
[tool.setuptools]
55+
packages = ["xarray"]
56+
5757
[tool.setuptools_scm]
5858
fallback_version = "9999"
5959

xarray/plot/dataarray_plot.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -789,7 +789,7 @@ def _plot1d(plotfunc):
789789
be either ``'viridis'`` (if the function infers a sequential
790790
dataset) or ``'RdBu_r'`` (if the function infers a diverging
791791
dataset).
792-
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:tutorials/colors/colormaps>`
792+
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:users/explain/colors/colormaps>`
793793
for more information.
794794
795795
If *seaborn* is installed, ``cmap`` may also be a
@@ -1325,7 +1325,7 @@ def _plot2d(plotfunc):
13251325
The mapping from data values to color space. If not provided, this
13261326
will be either be ``'viridis'`` (if the function infers a sequential
13271327
dataset) or ``'RdBu_r'`` (if the function infers a diverging dataset).
1328-
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:tutorials/colors/colormaps>`
1328+
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:users/explain/colors/colormaps>`
13291329
for more information.
13301330
13311331
If *seaborn* is installed, ``cmap`` may also be a

xarray/plot/dataset_plot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def _dsplot(plotfunc):
103103
be either ``'viridis'`` (if the function infers a sequential
104104
dataset) or ``'RdBu_r'`` (if the function infers a diverging
105105
dataset).
106-
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:tutorials/colors/colormaps>`
106+
See :doc:`Choosing Colormaps in Matplotlib <matplotlib:users/explain/colors/colormaps>`
107107
for more information.
108108
109109
If *seaborn* is installed, ``cmap`` may also be a

0 commit comments

Comments
 (0)