From 8423f820680e6e7303df27857fbb8efa0e63f5c1 Mon Sep 17 00:00:00 2001 From: Mario Picciani Date: Wed, 16 Oct 2024 16:22:46 +0200 Subject: [PATCH] fix requirements, mock imports for docs building --- docs/conf.py | 5 ++++- docs/requirements.txt | 5 ++++- requirements.txt | 2 ++ 3 files changed, 10 insertions(+), 2 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 37bfef3..7c31e3b 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -15,7 +15,7 @@ from jinja2.defaults import DEFAULT_FILTERS -sys.path.insert(0, os.path.abspath("..")) +sys.path.insert(0, os.path.abspath("../")) # -- General configuration --------------------------------------------- @@ -165,6 +165,9 @@ autodoc_typehints = "description" +autodoc_mock_imports = ["numpy", "sklearn", "pandas", "networkx", "yaml", "pytorch_lightning", "torch", "scipy"] + + # -- Options for Texinfo output ---------------------------------------- # Grouping the document tree into Texinfo files. List of tuples diff --git a/docs/requirements.txt b/docs/requirements.txt index 3c8d7e7..d45dd64 100644 --- a/docs/requirements.txt +++ b/docs/requirements.txt @@ -1 +1,4 @@ --r ../requirements.txt +sphinx-autobuild==2024.10.3 ; python_version >= "3.9" and python_version < "3.12" +sphinx-autodoc-typehints==1.25.3 ; python_version >= "3.9" and python_version < "3.12" +sphinx-click==6.0.0 ; python_version >= "3.9" and python_version < "3.12" +sphinx-rtd-theme==3.0.1 ; python_version >= "3.9" and python_version < "3.12" diff --git a/requirements.txt b/requirements.txt index 62b3e54..9b62dc4 100644 --- a/requirements.txt +++ b/requirements.txt @@ -91,6 +91,7 @@ pytest==8.3.3 ; python_version >= "3.9" and python_version < "3.12" python-dateutil==2.9.0.post0 ; python_version >= "3.9" and python_version < "3.12" pytorch-lightning==2.4.0 ; python_version >= "3.9" and python_version < "3.12" pytz==2024.2 ; python_version >= "3.9" and python_version < "3.12" +pyupgrade==3.18.0 ; python_version >= "3.9" and python_version < "3.12" pyyaml==6.0.2 ; python_version >= "3.9" and python_version < "3.12" requests==2.32.3 ; python_version >= "3.9" and python_version < "3.12" restructuredtext-lint==1.4.0 ; python_version >= "3.9" and python_version < "3.12" @@ -122,6 +123,7 @@ stevedore==5.3.0 ; python_version >= "3.9" and python_version < "3.12" sympy==1.13.3 ; python_version >= "3.9" and python_version < "3.12" tabulate==0.9.0 ; python_version >= "3.9" and python_version < "3.12" threadpoolctl==3.5.0 ; python_version >= "3.9" and python_version < "3.12" +tokenize-rt==6.0.0 ; python_version >= "3.9" and python_version < "3.12" tomli==2.0.2 ; python_version >= "3.9" and python_version < "3.11" tomlkit==0.13.2 ; python_version >= "3.9" and python_version < "3.12" torch==2.4.1 ; python_version >= "3.9" and python_version < "3.12"