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

'jQuery is not defined' when using .readthedocs.yaml #10318

Closed
Dramelac opened this issue May 13, 2023 · 2 comments
Closed

'jQuery is not defined' when using .readthedocs.yaml #10318

Dramelac opened this issue May 13, 2023 · 2 comments

Comments

@Dramelac
Copy link

Details

We didn't have any problem with or previous setup without a .readthedocs.yaml (as you can see in our latest version of the documentation.
For test & debug purpose i created a jsbug branch / version to showcase the bug: https://exegol.readthedocs.io/en/jsbug/

Am I missing something with the configuration ?

The config file:

# .readthedocs.yaml

# Required
version: 2

# Set the version of Python and other tools you might need
build:
  os: ubuntu-22.04
  tools:
    python: "3.11"

# Build documentation in the docs/ directory with Sphinx
sphinx:
  configuration: source/conf.py

# If using Sphinx, optionally build your docs in additional formats such as PDF
formats: all

# Optionally declare the Python requirements required to build your docs
python:
  install:
    - requirements: requirements.txt

Expected Result

  • The user should be able to open the side bar from the movile view
  • The user should be able to open the readthedocs 'popup' ? on the bottom left of the page to select a version, a branch or download the doc in another format

Actual Result

  • Clicking on the 'hamburger' button on the mobile view doesn't open the menu
  • Clicking on the readthedocks overlay doesn't open the section to navigation between version & formats etc
  • An error message regarding jQuery is raised in the console:
    image

Thank you for the help !

@Dramelac Dramelac changed the title 'jQuery is not defined' when using a custom build config file 'jQuery is not defined' when using .readthedocs.yaml May 13, 2023
@mjiggidy
Copy link

mjiggidy commented May 14, 2023

A very emphatic +1. This also affects Search.

Tried the suggestion from readthedocs/sphinx_rtd_theme#1452 (comment)_ (adding sphinxcontrib.jquery to the config.py extensions list). When built locally, this fixes Search and the mobile hamburger button (assume it fixes the version pop-up, but cannot test without rtd.io building it), but has no affect/doesn't work when rtd.io builds the documentation automatically.

@stsewd
Copy link
Member

stsewd commented May 15, 2023

Hi, this is a problem with the version of the theme and sphinx, this isn't a problem with the configuration file. See readthedocs/sphinx_rtd_theme#1452.

Your past builds were probably using an old version of sphinx.

@stsewd stsewd closed this as completed May 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants