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

no theme named 'python-docs-theme' found (missing theme.conf?) #45

Open
zdens opened this issue Feb 18, 2020 · 6 comments
Open

no theme named 'python-docs-theme' found (missing theme.conf?) #45

zdens opened this issue Feb 18, 2020 · 6 comments

Comments

@zdens
Copy link

@zdens zdens commented Feb 18, 2020

after installing this theme in virtual environment I've got "Theme error".
I do see "missing theme.conf" in the folder "venv/lib/python3.7/site-packages/python_docs_theme" but "make html" produces an error.
How can this error be fixed?

@beijersb
Copy link

@beijersb beijersb commented Jun 11, 2020

Hmm, i also got this error, after looking around for a while, finally found it:
conf.py for your sphinx project should contain something like:
extensions = [ ....., 'python_docs_theme', ]
and further on:
html_theme = 'python_docs_theme'
Pay special attention to the _ (underscore); don't use - (minus sign).

Works like a charm.
Grtx,
Ben

@JulienPalard
Copy link
Member

@JulienPalard JulienPalard commented Jun 15, 2020

Interestingly, cpython just has html_theme = 'python_docs_theme', and we're not having the issue.

@andy-maier
Copy link

@andy-maier andy-maier commented Jul 21, 2020

I can confirm the issue as described above, for Python 3.8.2 on macOS with Sphinx 3.1.2, and also that it went away after adding 'python_docs_theme' to extensions.

I think the installation instructions on the README page should be updated accordingly (unless someone volunteers to find out why exactly it works without adding 'python_docs_theme' to extensions for the Python 3 docs).

andy-maier added a commit to andy-maier/python-docs-theme that referenced this issue Jul 21, 2020
Details:

* It turns out that projects other than Python 3 that use the theme have to set
  it up in their conf.py files. This change adds the instructions to set that
  up, to the README file. See issue python#45.

Signed-off-by: Andreas Maier <[email protected]>
@andy-maier
Copy link

@andy-maier andy-maier commented Jul 21, 2020

I have created PR #48 to address this issue. Afterwards, I saw there is already PR #32 that addresses this similarly, but needs to be rebased. Let me know how to proceed there.

@JulienPalard
Copy link
Member

@JulienPalard JulienPalard commented Jul 23, 2020

I checked the following steps on Debian:

  • Created a venv with Python 3.8.4
  • pip installed Sphinx==3.1.2 python-docs-theme==2020.1
  • ran sphinx-quickstart
  • ran make html
  • ran firefox _build/html/index.html

and it worked as expected, no need to edit extensions for me.

Can someone having the issue try this to compare?

@Mariatta
Copy link
Member

@Mariatta Mariatta commented Sep 14, 2020

For the core sprint repo, we only added the html_theme='python_docs_theme', using Python 3.8.3 and sphinx 3.2.1.

I think it's not needed to add it to extensions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
5 participants
You can’t perform that action at this time.