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

Builds failing with html_theme not set #10662

Closed
st-bender opened this issue Aug 24, 2023 · 2 comments · Fixed by #10663
Closed

Builds failing with html_theme not set #10662

st-bender opened this issue Aug 24, 2023 · 2 comments · Fixed by #10663
Assignees
Labels
Accepted Accepted issue on our roadmap Bug A bug

Comments

@st-bender
Copy link

Looks like #10638 broke builds when html_theme is not set (see also comments in the PR).
I am not sure that breaking builds was intended.

Running Sphinx v5.3.0

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/config.py", line 350, in eval_config_file
    exec(code, namespace)
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/checkouts/latest/docs/conf.py", line 164, in <module>
    'html_theme': html_theme,
NameError: name 'html_theme' is not defined

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/cmd/build.py", line 276, in build_main
    app = Sphinx(args.sourcedir, args.confdir, args.outputdir,
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/application.py", line 202, in __init__
    self.config = Config.read(self.confdir, confoverrides or {}, self.tags)
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/config.py", line 172, in read
    namespace = eval_config_file(filename, tags)
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/config.py", line 363, in eval_config_file
    raise ConfigError(msg % traceback.format_exc()) from exc
sphinx.errors.ConfigError: There is a programmable error in your configuration file:

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/config.py", line 350, in eval_config_file
    exec(code, namespace)
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/checkouts/latest/docs/conf.py", line 164, in <module>
    'html_theme': html_theme,
NameError: name 'html_theme' is not defined


Configuration error:
There is a programmable error in your configuration file:

Traceback (most recent call last):
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/conda/latest/lib/python3.9/site-packages/sphinx/config.py", line 350, in eval_config_file
    exec(code, namespace)
  File "/home/docs/checkouts/readthedocs.org/user_builds/pyeppaurora/checkouts/latest/docs/conf.py", line 164, in <module>
    'html_theme': html_theme,
NameError: name 'html_theme' is not defined

Expected Result

The build should use RTD's default theme.

Actual Result

Build error, see above.

@st-bender
Copy link
Author

Thanks a lot!

@humitos
Copy link
Member

humitos commented Aug 29, 2023

We are releasing a fix for this today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted Accepted issue on our roadmap Bug A bug
Projects
Archived in project
2 participants