|
| 1 | +from importlib import metadata |
| 2 | + |
| 3 | +# Configuration file for the Sphinx documentation builder. |
| 4 | +# |
| 5 | +# For the full list of built-in configuration values, see the documentation: |
| 6 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html |
| 7 | + |
| 8 | +# -- Project information ----------------------------------------------------- |
| 9 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information |
| 10 | + |
| 11 | +project = "IDAES Flowsheet Processor" |
| 12 | +copyright = "2024, WaterTAP" |
| 13 | +author = "WaterTAP" |
| 14 | + |
| 15 | +release = version = metadata.version("idaes-flowsheet-processor") |
| 16 | + |
| 17 | +# -- General configuration --------------------------------------------------- |
| 18 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration |
| 19 | + |
| 20 | +extensions = [ |
| 21 | + "sphinx_rtd_theme", |
| 22 | + "sphinx.ext.doctest", |
| 23 | + "sphinx.ext.napoleon", |
| 24 | + "autoapi.extension", |
| 25 | + "sphinx.ext.intersphinx", |
| 26 | +] |
| 27 | +suppress_warnings = [] |
| 28 | + |
| 29 | +templates_path = ["_templates"] |
| 30 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] |
| 31 | + |
| 32 | +# see https://sphinx-autoapi.readthedocs.io/en/latest/reference/config.html |
| 33 | +autoapi_dirs = ["../src"] |
| 34 | +autoapi_root = "technical_reference" |
| 35 | +autoapi_options = [ |
| 36 | + "members", |
| 37 | + "undoc-members", |
| 38 | + "show-module-summary", |
| 39 | +] |
| 40 | +# set to True to save the autogenerated |
| 41 | +autoapi_keep_files = False |
| 42 | +autoapi_ignore = ["*conftest.py", "*test_*.py", "*tests/*.py", "*_testing/*.py"] |
| 43 | +# suppress_warnings += ["autoapi.python_import_resolution"] |
| 44 | + |
| 45 | +intersphinx_mapping = { |
| 46 | + "python": ("https://docs.python.org/3", None), |
| 47 | + "pyomo": ("https://pyomo.readthedocs.io/en/stable", None), |
| 48 | + "numpy": ("https://numpy.org/doc/stable", None), |
| 49 | + "idaes": ("https://idaes-pse.readthedocs.io/en/stable", None), |
| 50 | + "watertap": ("https://watertap.readthedocs.io/en/latest", None), |
| 51 | + "prommis": ("https://prommis.readthedocs.io/en/latest", None), |
| 52 | +} |
| 53 | + |
| 54 | + |
| 55 | +def _skip_tests(app, what: str, name: str, obj, skip, options): |
| 56 | + return skip |
| 57 | + |
| 58 | + |
| 59 | +def setup(sphinx): |
| 60 | + sphinx.connect("autoapi-skip-member", _skip_tests) |
| 61 | + |
| 62 | + |
| 63 | +# -- Options for HTML output ------------------------------------------------- |
| 64 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output |
| 65 | + |
| 66 | +html_theme = "sphinx_rtd_theme" |
| 67 | +html_static_path = [] |
0 commit comments