Skip to content

Commit b328b01

Browse files
dcherianscottyhq
andauthored
Add sphinx-autocodelink & intersphinx_mapping (xarray-contrib#85)
* Add intersphinx mapping Closes xarray-contrib#82 * Add codeautolink * markdown codeblock syntax needs to be valid --------- Co-authored-by: Scott Henderson <[email protected]>
1 parent e4061f2 commit b328b01

File tree

3 files changed

+28
-3
lines changed

3 files changed

+28
-3
lines changed

_config.yml

+26
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,13 @@ sphinx:
6868
# maintain old paths and redirect them (so google results dont go to 404)
6969
# https://github.com/wpilibsuite/sphinxext-rediraffe
7070
- sphinxext.rediraffe
71+
- sphinx_codeautolink
72+
7173
config:
7274
language: en # accessibility
7375
# application/vnd.holoviews_load.v0+json, application/vnd.holoviews_exec.v0+json
7476
suppress_warnings: ["mystnb.unknown_mime_type", "misc.highlighting_failure"]
77+
codeautolink_concat_default: True
7578
notfound_context:
7679
body: "<h1>Whoops! 404 Page Not Found</h1>\n\n<p>Sorry, this page doesn't exist. Many sections of this book have been updated recently.</p><p> Try the search box 🔎 to find what you're looking for!</p>"
7780
notfound_urls_prefix: /
@@ -81,3 +84,26 @@ sphinx:
8184
fundamentals/02.1_working_with_labeled_data.ipynb: fundamentals/02.1_indexing_Basic.ipynb
8285

8386
bibtex_reference_style: author_year # or label, super, \supercite
87+
88+
intersphinx_mapping:
89+
xarray:
90+
- https://docs.xarray.dev/en/latest/
91+
- null
92+
numpy:
93+
- https://numpy.org/doc/stable
94+
- null
95+
scipy:
96+
- https://docs.scipy.org/doc/scipy
97+
- null
98+
matplotlib:
99+
- https://matplotlib.org/stable/
100+
- null
101+
dask:
102+
- https://docs.dask.org/en/latest
103+
- null
104+
python:
105+
- https://docs.python.org/3/
106+
- null
107+
pandas:
108+
- https://pandas.pydata.org/pandas-docs/stable
109+
- null

advanced/apply_ufunc/complex-output-numpy.ipynb

+1-1
Original file line numberDiff line numberDiff line change
@@ -336,7 +336,7 @@
336336
"\n",
337337
"Try applying the minmax function to a 3d air temperature dataset \n",
338338
"```python\n",
339-
"air3d = xr.tutorial.load_dataset(\"air_temperature\").air)\n",
339+
"air3d = xr.tutorial.load_dataset(\"air_temperature\").air\n",
340340
"``` \n",
341341
"Your goal is to have a minimum and maximum value of temperature across all latitudes for a given time and longitude.\n",
342342
"\n",

advanced/backends/1.Backend_without_Lazy_Loading.ipynb

+1-2
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@
4242
"\n",
4343
"```python\n",
4444
"setuptools.setup(\n",
45-
" ...\n",
4645
" entry_points={\n",
4746
" 'xarray.backends': ['engine_name=package.module:my_backendentrypoint'],\n",
4847
" },\n",
@@ -51,7 +50,7 @@
5150
"or pass it in `xr.open_dataset`:\n",
5251
"\n",
5352
"```python\n",
54-
"xr.open_dataset(..., engine=MyBackendEntrypoint)\n",
53+
"xr.open_dataset(filename, engine=MyBackendEntrypoint)\n",
5554
"```"
5655
]
5756
},

0 commit comments

Comments
 (0)