From d23e753d9c9ab9ce769d849086394e70fde849ec Mon Sep 17 00:00:00 2001 From: micahpw <6476273+micahpw@users.noreply.github.com> Date: Fri, 7 Aug 2026 06:16:43 -0600 Subject: [PATCH] fix: resolve the two docutils ERRORs in the Sphinx build (#3) Both were "Unexpected indentation" from malformed RST, confirmed by feeding the exact generated/cleaned docstring text through docutils.core.publish_doctree in isolation before and after each fix: - gat.registry.plot_function: the Example section's code wasn't marked as an RST literal block, so the doubly-indented `...` line broke paragraph parsing. Added the `::` marker. - `gat project scenario add` CLI help: the bullet list right after "For Sienna scenarios:" had no blank line separating it from the preceding paragraph, which is required for RST to recognize it as a list rather than a paragraph continuation. Verified with a full `sphinx-build -b html docs/source docs/build/html` -- zero ERROR lines remain (down from 2), no new warnings introduced. --- src/gat/cli_projects_v1.py | 1 + src/gat/registry/__init__.py | 8 +++++--- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/gat/cli_projects_v1.py b/src/gat/cli_projects_v1.py index 97b8d1d..d5afc1f 100644 --- a/src/gat/cli_projects_v1.py +++ b/src/gat/cli_projects_v1.py @@ -590,6 +590,7 @@ def add_scenario( to absolute filesystem paths for storage. For Sienna scenarios: + - If --simulation-type is specified (e.g., UC, ED, PF), creates a single scenario for that specific simulation type - If --simulation-type is NOT specified, auto-discovers all simulation types in the diff --git a/src/gat/registry/__init__.py b/src/gat/registry/__init__.py index 0b5bcb8..3034e51 100644 --- a/src/gat/registry/__init__.py +++ b/src/gat/registry/__init__.py @@ -38,9 +38,11 @@ def plot_function( The decorated function Example: - @plot_function("MultiScenario", "system") - def plot_generation_capacities(multi_scenario, **kwargs): - ... + :: + + @plot_function("MultiScenario", "system") + def plot_generation_capacities(multi_scenario, **kwargs): + ... """ def decorator(func: Callable) -> Callable: