gemini-code-assist[bot] commented on code in PR #19862:
URL: https://github.com/apache/tvm/pull/19862#discussion_r3449738066
##########
docs/conf.py:
##########
@@ -561,9 +577,12 @@ def fixup_tutorials(original_url: str) -> str:
"edit_link_hook_fn": fixup_tutorials,
}
-# add additional overrides
-templates_path += [tlcpack_sphinx_addon.get_templates_path()]
-html_static_path += [tlcpack_sphinx_addon.get_static_path()]
+# add additional overrides. The tlcpack templates override layout.html for the
+# RTD theme (and assume its header/footer html_context); only apply them when
the
+# RTD theme is active so they don't clobber another theme's own layout.
+if html_theme == "sphinx_rtd_theme":
Review Comment:

On Read the Docs (`on_rtd = True`), if `TVM_THEME` is set to `"rtd"`,
`html_theme` remains `"rtd"` because the local normalization block on line 361
does not execute. Checking only `html_theme == "sphinx_rtd_theme"` will
evaluate to `False` in this case, preventing the `tlcpack_sphinx_addon`
templates and static overrides from being applied. We should check for both
`"sphinx_rtd_theme"` and `"rtd"` to ensure correctness.
```suggestion
if html_theme in ("sphinx_rtd_theme", "rtd"):
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]