From f9f69a07ef8b3808ff9956fca92f90f59e668c7d Mon Sep 17 00:00:00 2001 From: "Oriol (ZBook)" Date: Mon, 10 Oct 2022 22:57:01 +0200 Subject: [PATCH 1/3] some doc fixes --- conda-envs/environment-dev.yml | 2 +- conda-envs/windows-environment-dev.yml | 2 +- docs/source/conf.py | 4 ---- docs/source/contributing/build_docs.md | 11 ++++++----- requirements-dev.txt | 2 +- 5 files changed, 9 insertions(+), 12 deletions(-) diff --git a/conda-envs/environment-dev.yml b/conda-envs/environment-dev.yml index ca8e044e21..bef8415953 100644 --- a/conda-envs/environment-dev.yml +++ b/conda-envs/environment-dev.yml @@ -27,7 +27,7 @@ dependencies: - myst-nb - numpydoc - pre-commit>=2.8.0 -- pydata-sphinx-theme<0.10.1 +- pydata-sphinx-theme>=0.11.0 - pytest-cov>=2.5 - pytest>=3.0 - sphinx-copybutton diff --git a/conda-envs/windows-environment-dev.yml b/conda-envs/windows-environment-dev.yml index bca1a3ab84..7fdf2c6bde 100644 --- a/conda-envs/windows-environment-dev.yml +++ b/conda-envs/windows-environment-dev.yml @@ -25,7 +25,7 @@ dependencies: - myst-nb - numpydoc - pre-commit>=2.8.0 -- pydata-sphinx-theme<0.10.1 +- pydata-sphinx-theme>=0.11.0 - pytest-cov>=2.5 - pytest>=3.0 - sphinx-autobuild>=0.7 diff --git a/docs/source/conf.py b/docs/source/conf.py index fea32e009f..a9608ff4aa 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -20,10 +20,6 @@ import sys from pathlib import Path -# If extensions (or modules to document with autodoc) are in another directory, -# add these directories to sys.path here. If the directory is relative to the -# documentation root, use os.path.abspath to make it absolute, like shown here. -sys.path.insert(0, os.path.abspath(os.path.join("..", ".."))) import pymc # isort:skip # -- General configuration ------------------------------------------------ diff --git a/docs/source/contributing/build_docs.md b/docs/source/contributing/build_docs.md index d4a7694aec..09e37328f4 100644 --- a/docs/source/contributing/build_docs.md +++ b/docs/source/contributing/build_docs.md @@ -8,11 +8,12 @@ To build docs on Windows we recommend running inside a Docker container. To build the docs, run these commands at PyMC repository root: ```bash -$ pip install -r requirements-dev.txt # Make sure the dev requirements are installed -$ pip install numpyro # Make sure `sampling_jax` docs can be built -$ make clean # clean built docs from previous runs and intermediate outputs -$ make html # Build docs -$ python -m http.server --directory docs/_build/ # Render docs +pip install -r requirements-dev.txt # Make sure the dev requirements are installed +pip install numpyro # Make sure `sampling_jax` docs can be built +pip install -e . # Install local pymc version as installable package +make clean # clean built docs from previous runs and intermediate outputs +make html # Build docs +python -m http.server --directory docs/_build/ # Render docs ``` Check the printed URL where docs are being served and open it. diff --git a/requirements-dev.txt b/requirements-dev.txt index b74187f6b8..5255ddfc3d 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -17,7 +17,7 @@ numpydoc pandas>=0.24.0 polyagamma pre-commit>=2.8.0 -pydata-sphinx-theme<0.10.1 +pydata-sphinx-theme>=0.11.0 pytest-cov>=2.5 pytest>=3.0 scipy>=1.4.1 From 17e283ef22ec71390053253fcd0a2d1adfd56378 Mon Sep 17 00:00:00 2001 From: "Oriol (ZBook)" Date: Mon, 10 Oct 2022 23:31:02 +0200 Subject: [PATCH 2/3] remove extra search field --- 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 a9608ff4aa..7da5d270c3 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -255,7 +255,7 @@ def setup(app): "logo_link": "https://www.pymc.io", "show_prev_next": False, "navbar_start": ["navbar-logo", "navbar-version"], - "navbar_end": ["search-field.html", "navbar-icon-links.html"], + "navbar_end": ["navbar-icon-links.html"], "page_sidebar_items": ["page-toc", "edit-this-page", "donate"], "search_bar_text": "Search...", "use_edit_page_button": True, From fb737fadb29747f6f35f770d32b0d0e50c4f2722 Mon Sep 17 00:00:00 2001 From: "Oriol (ZBook)" Date: Mon, 10 Oct 2022 23:57:06 +0200 Subject: [PATCH 3/3] remove more navbar item --- docs/source/conf.py | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 7da5d270c3..99008591a3 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -257,6 +257,7 @@ def setup(app): "navbar_start": ["navbar-logo", "navbar-version"], "navbar_end": ["navbar-icon-links.html"], "page_sidebar_items": ["page-toc", "edit-this-page", "donate"], + "header_links_before_dropdown": 6, "search_bar_text": "Search...", "use_edit_page_button": True, "google_analytics_id": "UA-176578023-1",