Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #8419: html search: Do not load language_data.js in non-search pages #8445

Merged

Conversation

tk0miya
Copy link
Member

@tk0miya tk0miya commented Nov 18, 2020

Feature or Bugfix

  • Bugfix

Purpose

…-search pages

The ``language_data.js`` is only used on search page.  But it is always
loaded meaninglessly.  This fixes not to load it on all non-search pages.
@tk0miya tk0miya added this to the 3.4.0 milestone Nov 18, 2020
@tk0miya tk0miya merged commit f5289bb into sphinx-doc:3.x Nov 20, 2020
@tk0miya tk0miya deleted the 8419_load_language_data.js_only_search_page branch November 20, 2020 13:35
zzzeek added a commit to sqlalchemyorg/zzzeeksphinx that referenced this pull request Jan 5, 2021
Sphinx removed a necessary js file in
sphinx-doc/sphinx#8445 .  add it to
our search template.
@zzzeek
Copy link

zzzeek commented Jan 5, 2021

hey there. Wondering what a more long term solution would be for maintainers of custom themes to not constantly get hit with these after the fact. You can see here three custom themes have already been hit.

Looking in Sphinx changelog I can see this issue is buried in a long list of other issues under "bugs fixed" with a terse message "html search: Do not load language_data.js in non-search pages":

https://github.com/sphinx-doc/sphinx/blob/3.x/CHANGES#L183

there appears to be a more prominent section called "Incompatible changes" with just one API change in it. Is it possible that fully breaking changes like these appear under "incompatible changes" and perhaps include some more detail what they mean ? thanks for reading.

timhoffm added a commit to timhoffm/matplotlib that referenced this pull request Jan 11, 2021
Sphinx stopped loading language_data.js globally in 3.4.
This file now has to be loaded explicitly on the search page.

See

- sphinx-doc/sphinx#8445
- readthedocs/sphinx_rtd_theme#1021
alexzorin added a commit to alexzorin/sphinx_rtd_theme that referenced this pull request May 12, 2021
Due to sphinx-doc/sphinx#8445 and the fact that
we are not keeping this theme fork up to date, it's necessary to
explicitly load this script on the search.html page.
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants