From ff98ec1f86adf93c92fd58f64264b04b59831206 Mon Sep 17 00:00:00 2001 From: IanCa Date: Fri, 21 Jun 2024 16:04:37 -0500 Subject: [PATCH] Try to fix readthedocs --- docs/source/api2.rst | 18 ++++++++---------- docs/source/conf.py | 14 ++------------ hedmat/hedtools/HedToolsPython.m | 12 ++++++------ hedmat/hedtools/HedToolsService.m | 6 +++--- hedmat/web_services_demos/getSessionInfo.m | 13 +++++++------ 5 files changed, 26 insertions(+), 37 deletions(-) diff --git a/docs/source/api2.rst b/docs/source/api2.rst index 1b95183..f866294 100644 --- a/docs/source/api2.rst +++ b/docs/source/api2.rst @@ -1,16 +1,14 @@ HED API reference ================= -.. currentmodule:: hedmat +.. automodule:: hedmat.hedtools + :members: -.. autosummary:: - :toctree: _autosummary - :template: custom-module-template.rst - :recursive: - - hedtools - remodeling_demos - utilities - web_services_demos +.. automodule:: hedmat.remodeling_demos + :members: +.. automodule:: hedmat.utilities + :members: +.. automodule:: hedmat.web_services_demos + :members: diff --git a/docs/source/conf.py b/docs/source/conf.py index 522405f..4eeeb42 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -15,8 +15,7 @@ import sphinx_rtd_theme from datetime import date -sys.path.insert(0, os.path.abspath('../../')) -sys.path.insert(0, os.path.abspath('.')) + # -- Project information ----------------------------------------------------- @@ -29,9 +28,8 @@ version = '0.0.1' release = '0.0.1' -currentdir = os.path.abspath(os.path.dirname(__file__)) # -- General configuration --------------------------------------------------- -matlab_src_dir = os.path.abspath(os.path.join(currentdir, '../../hedmat')) +matlab_src_dir = os.path.abspath(os.path.join("..", "..")) # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. @@ -39,14 +37,6 @@ "myst_parser", "sphinxcontrib.matlab", "sphinx.ext.autodoc", - "sphinx.ext.autosummary", - "sphinx.ext.autosectionlabel", - "sphinx.ext.intersphinx", - "sphinx.ext.coverage", - "sphinx.ext.mathjax", - "sphinx.ext.viewcode", - "sphinx.ext.githubpages", - "sphinx.ext.napoleon" ] diff --git a/hedmat/hedtools/HedToolsPython.m b/hedmat/hedtools/HedToolsPython.m index e9ca620..1f679a2 100644 --- a/hedmat/hedtools/HedToolsPython.m +++ b/hedmat/hedtools/HedToolsPython.m @@ -28,8 +28,7 @@ % % Optional name-value: % 'includeContext' - boolean true->expand context (usually true). - % 'removeTypesOn' - boolean true-> remove Condition-variable - % and Task + % 'removeTypesOn' - boolean true-> remove Condition-variable and Task % 'replaceDefs' - boolean true->replace def with definition (usually true). % % Returns: @@ -167,12 +166,13 @@ % hedTags - A MATLAB string or character array. % % Optional name-value: - % 'checkWarnings' - boolean (optional, default false) - % indicates whether to include warnings. + % 'checkWarnings' - boolean (optional, default false) + % indicates whether to include warnings. % % Returns: - % issues - A string with the validation issues suitable for - % printing (has newlines). + % issues - A string with the validation issues suitable for + % printing (has newlines). + % ToDo: Make hedDefinitions optional. % diff --git a/hedmat/hedtools/HedToolsService.m b/hedmat/hedtools/HedToolsService.m index 3722bba..07ba9b9 100644 --- a/hedmat/hedtools/HedToolsService.m +++ b/hedmat/hedtools/HedToolsService.m @@ -32,8 +32,7 @@ % % Optional name-value: % 'includeContext' - boolean true->expand context (usually true). - % 'removeTypesOn' - boolean true-> remove Condition-variable - % and Task + % 'removeTypesOn' - boolean true-> remove Condition-variable and Task % 'replaceDefs' - boolean true->replace def with definition (usually true). % % Returns: @@ -223,7 +222,8 @@ end function [] = resetSessionInfo(obj, host) - %% Reset the session for accessing the HED webservices + % Reset the session for accessing the HED webservices + % % Parameters: % host = URL for the services % diff --git a/hedmat/web_services_demos/getSessionInfo.m b/hedmat/web_services_demos/getSessionInfo.m index bdb3aa8..ec0d5ce 100644 --- a/hedmat/web_services_demos/getSessionInfo.m +++ b/hedmat/web_services_demos/getSessionInfo.m @@ -1,12 +1,13 @@ function [cookie, csrftoken] = getSessionInfo(csrf_url) -%% Setup the session for accessing the HED webservices -% Parameters: -% csrf_url = URL for the services +% Setup the session for accessing the HED webservices % -% Returns: -% cookie = a string cookie value -% csrftoken = a string csrf token for the session. +% Parameters: +% csrf_url - URL for the services. % +% Returns: +% cookie - A string cookie value. +% csrftoken - A string csrf token for the session. + request = matlab.net.http.RequestMessage; uri = matlab.net.URI(csrf_url); response1 = send(request,uri);