From c234463a6765491c6a8baee10541ad67be28b468 Mon Sep 17 00:00:00 2001 From: Richard Darst Date: Thu, 16 Apr 2020 11:47:07 +0300 Subject: [PATCH 1/3] sphinx conf.py: update add_stylesheet -> add_css_file - Seems to be added in 1.0: https://www.sphinx-doc.org/en/latest/changes.html#release-1-0-jul-23-2010 --- docs/source/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index fd0d4b92..14b548ee 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -62,7 +62,7 @@ from recommonmark.transform import AutoStructify def setup(app): app.add_config_value('recommonmark_config', {'enable_eval_rst': True}, True) - app.add_stylesheet('custom.css') + app.add_css_file('custom.css') app.add_transform(AutoStructify) From e882e7954c0473d2941c0fbc7d5f8c8e04a8658a Mon Sep 17 00:00:00 2001 From: Richard Darst Date: Thu, 16 Apr 2020 16:59:05 +0300 Subject: [PATCH 2/3] docs: use recommonmark as an extension - source_parsers deprecated in sphinx 3.0 - Since sphinx 1.4, it can (should) be used as a direct extension: https://github.com/readthedocs/recommonmark/pull/43 --- docs/source/conf.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 14b548ee..64e4939a 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -20,6 +20,7 @@ extensions = [ 'autodoc_traits', 'sphinx_copybutton', 'sphinx-jsonschema', + 'recommonmark', ] templates_path = ['_templates'] @@ -66,8 +67,6 @@ def setup(app): app.add_transform(AutoStructify) -source_parsers = {'.md': 'recommonmark.parser.CommonMarkParser'} - source_suffix = ['.rst', '.md'] # source_encoding = 'utf-8-sig' From 9d6e8e6b6fb02ca7952b158bf665b3ad8a8a0223 Mon Sep 17 00:00:00 2001 From: Richard Darst Date: Thu, 16 Apr 2020 11:45:35 +0300 Subject: [PATCH 3/3] Temporary patch autodoc-traits to fix build error [temporary] - This commit should be removed later after autodoc-traits is fixed upstream --- docs/requirements.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/requirements.txt b/docs/requirements.txt index e0ea5aa4..472fcc28 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1,7 +1,9 @@ -r ../requirements.txt alabaster_jupyterhub -autodoc-traits +# Temporary fix of #3021. Revert back to released autodoc-traits when +# 0.1.0 released. +https://github.com/jupyterhub/autodoc-traits/archive/75885ee24636efbfebfceed1043459715049cd84.zip pydata-sphinx-theme recommonmark>=0.6 sphinx-copybutton