|
38 | 38 | warnings.filterwarnings( |
39 | 39 | 'ignore', message=("This has been deprecated in mpl 1.5,")) |
40 | 40 | warnings.filterwarnings('ignore', message="invalid value encountered in ") |
| 41 | +warnings.filterwarnings('ignore', message="\s*examples.directory") |
| 42 | +warnings.filterwarnings('ignore', message='numpy.dtype size changed') |
41 | 43 |
|
42 | 44 | # -- General configuration ------------------------------------------------ |
43 | 45 |
|
|
67 | 69 |
|
68 | 70 | # process the examples if they don't exist already |
69 | 71 | process_examples = ( |
70 | | - not osp.exists(osp.join(osp.dirname(__file__), 'examples')) or on_rtd) |
| 72 | + not osp.exists(osp.join(osp.dirname(__file__), 'examples'))) |
71 | 73 |
|
72 | 74 | if on_rtd: |
73 | 75 | spr.call([sys.executable] + |
74 | 76 | ('-m ipykernel install --user --name python3 ' |
75 | 77 | '--display-name python3').split()) |
76 | 78 |
|
77 | | -if on_rtd or not osp.exists(osp.join(osp.dirname(__file__), 'api')): |
| 79 | +if not osp.exists(osp.join(osp.dirname(__file__), 'api')): |
78 | 80 | spr.check_call(['bash', 'apigen.bash']) |
79 | 81 |
|
| 82 | +# HACK: Create an empty file called '<string>' to prevent |
| 83 | +# https://github.com/sphinx-doc/sphinx/issues/5614 |
| 84 | +if not osp.exists('<string>'): |
| 85 | + with open('<string>', 'w') as f: |
| 86 | + pass |
| 87 | + |
80 | 88 | # The cdo example would require the installation of climate data operators |
81 | 89 | # which is a bit of an overkill |
82 | 90 | example_gallery_config = dict( |
|
210 | 218 | intersphinx_mapping = { |
211 | 219 | 'pandas': ('http://pandas.pydata.org/pandas-docs/stable/', None), |
212 | 220 | 'numpy': ('https://docs.scipy.org/doc/numpy/', None), |
213 | | - 'matplotlib': ('http://matplotlib.org/', None), |
| 221 | + 'matplotlib': ('https://matplotlib.org/', None), |
214 | 222 | 'sphinx': ('http://www.sphinx-doc.org/en/stable/', None), |
215 | 223 | 'xarray': ('http://xarray.pydata.org/en/stable/', None), |
216 | | - 'cartopy': ('http://scitools.org.uk/cartopy/docs/latest/', None), |
217 | | - 'mpl_toolkits': ('http://matplotlib.org/basemap/', None), |
| 224 | + 'cartopy': ('https://scitools.org.uk/cartopy/docs/latest/', None), |
| 225 | + 'mpl_toolkits': ('https://matplotlib.org/basemap/', None), |
218 | 226 | 'psyplot': ('https://psyplot.readthedocs.io/en/latest/', None), |
219 | 227 | 'psy_simple': ( |
220 | 228 | 'https://psyplot.readthedocs.io/projects/psy-simple/en/latest/', None), |
221 | 229 | 'psy_reg': ( |
222 | 230 | 'https://psyplot.readthedocs.io/projects/psy-reg/en/latest/', None), |
223 | 231 | } |
224 | 232 | if six.PY3: |
225 | | - intersphinx_mapping['python'] = ('https://docs.python.org/3.6/', None) |
| 233 | + intersphinx_mapping['python'] = ('https://docs.python.org/3.7/', None) |
226 | 234 | else: |
227 | 235 | intersphinx_mapping['python'] = ('https://docs.python.org/2.7/', None) |
228 | 236 |
|
|
0 commit comments