Closed krivenko closed 11 months ago
I am getting a theme error when trying to build the docs with Sphinx 7.2.5
Theme error: An error happened in rendering the page ChangeLog. Reason: UndefinedError("'logo' is undefined")
Is appears that Sphinx 6.0.0 renamed the logo variable in HTML templates and now it is called logo_url.
logo
logo_url
The offending HTML fragment is
https://github.com/TRIQS/triqs/blob/e1fa5dd2c8984e334574163f6323e956a49ffbd5/doc/_templates/layout.html#L11-L13
Since layout.html is based on some code from sphinx_rtd_theme, I suggest doing the same thing as RTD's devs did,
layout.html
sphinx_rtd_theme
+{%- set _logo_url = logo_url|default(pathto('_static/' + (logo or ""), 1)) %} <a href={{ pathto('index') }}> - <img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="{{ _('Logo') }}"/> + <img src="{{ _logo_url }}" class="logo" alt="{{ _('Logo') }}"/> </a>
With this change, the documentation builds normally and the logo is properly displayed.
Thank you @krivenko for pointing this out. This was fixed in 873e425be
I am getting a theme error when trying to build the docs with Sphinx 7.2.5
Is appears that Sphinx 6.0.0 renamed the
logo
variable in HTML templates and now it is calledlogo_url
.The offending HTML fragment is
https://github.com/TRIQS/triqs/blob/e1fa5dd2c8984e334574163f6323e956a49ffbd5/doc/_templates/layout.html#L11-L13
Since
layout.html
is based on some code fromsphinx_rtd_theme
, I suggest doing the same thing as RTD's devs did,With this change, the documentation builds normally and the logo is properly displayed.