Skip to content

Commit 88bef2f

Browse files
fix: downgrade the autoapi and keep autoapi toctree to True by default (#453)
Co-authored-by: pyansys-ci-bot <[email protected]>
1 parent b766d1d commit 88bef2f

File tree

5 files changed

+7
-6
lines changed

5 files changed

+7
-6
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
repos:
22
- repo: https://github.com/psf/black
3-
rev: 24.4.2
3+
rev: 24.8.0
44
hooks:
55
- id: black
66

@@ -10,7 +10,7 @@ repos:
1010
- id: isort
1111

1212
- repo: https://github.com/PyCQA/flake8
13-
rev: 7.1.0
13+
rev: 7.1.1
1414
hooks:
1515
- id: flake8
1616

@@ -54,7 +54,7 @@ repos:
5454
exclude: 'src/ansys_sphinx_theme/theme/ansys_sphinx_theme/_templates/'
5555

5656
- repo: https://github.com/ansys/pre-commit-hooks
57-
rev: v0.3.1
57+
rev: v0.4.3
5858
hooks:
5959
- id: add-license-headers
6060
files: '(src|doc/source/examples)/.*\.(py)'

doc/changelog.d/453.fixed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fix: downgrade the autoapi and keep ``autoapi`` toctree to ``True`` by default

doc/source/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@
2424

2525
THIS_PATH = Path(__file__).parent.resolve()
2626
EXAMPLE_PATH = (THIS_PATH / "examples" / "sphinx_examples").resolve()
27-
API_TEMPLATES = (THIS_PATH / "examples" / "autoapi").resolve()
2827

2928
# Project information
3029
project = "ansys_sphinx_theme"
@@ -72,6 +71,7 @@
7271
"directory": "src/ansys_sphinx_theme/examples",
7372
"output": "examples/",
7473
"own_page_level": "function",
74+
"add_toctree_entry": False,
7575
},
7676
"logo": "ansys",
7777
}

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ dependencies = [
3030

3131
[project.optional-dependencies]
3232
autoapi = [
33-
"sphinx-autoapi==3.2.1",
33+
"sphinx-autoapi==3.1.1",
3434
"sphinx-design==0.6.1",
3535
"sphinx-jinja==2.0.2",
3636
]

src/ansys_sphinx_theme/extension/autoapi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ def prepare_jinja_env(jinja_env) -> None:
8282
app.config["autoapi_python_class_content"] = autoapi.get("class_content", "class")
8383
app.config["autoapi_options"] = autoapi.get("options", AUTOAPI_OPTIONS)
8484
app.config["autoapi_ignore"] = autoapi.get("ignore", [])
85-
app.config["autoapi_add_toctree_entry"] = autoapi.get("add_toctree_entry", False)
85+
app.config["autoapi_add_toctree_entry"] = autoapi.get("add_toctree_entry", True)
8686

8787
# HACK: The ``autoapi_dirs`` should be given as a relative path to the conf.py.
8888
relative_autoapi_dir = os.path.relpath(

0 commit comments

Comments
 (0)