Edwin Lai
Edwin Lai

Reputation: 399

sphinx not able to find sphinx_rtd_theme

I'm newbe of Sphinx,

I tried to use html_theme = 'sphinx_rtd_theme' in conf.py

but I get message below when I run "make html" :

sphinx_rtd_theme is no longer a hard dependency since version 1.4.0. Please install it manually.(pip install sphinx_rtd_theme)

I already installed it with pip install sphinx_rtd_them
(part of pip list)

Package Version


alabaster 0.7.11
sphinx-rtd-theme 0.4.1
Sphinx 1.8.1

Also I installed sphinx-doc with brew.

Anybody with same issue??

Another things to know is...My ubuntu PC works perfectly,
but not works on Macbook pro...

Upvotes: 2

Views: 2426

Answers (2)

OctaviaLo
OctaviaLo

Reputation: 1396

I re-did the symlinks and it worked. The make file wants to use sphinx-apidoc, sphinx-autogen, sphinx-build and sphinx-quickstart in the sphinx_rtd_theme folder, but the symlink could be wrong, pointing to the versions in the sphinx folder. I had to re-do the symlinks.

To redo the symlinks: Go to /Users/<username>/.local/bin

Remove each with rm sphinx-build, rm sphinx-autogen etc.

ln -s /Users/<username>/.local/pipx/venvs/sphinx-rtd-theme/bin/sphinx-autogen /Users/<username>/.local/bin/sphinx-quickstart

Later when I go into /Users/<username>/.local/bin and do ls -l I get the versions correctly symlinked.

lrwxr-xr-x  1<username>  73 Apr 25 16:30 sphinx-quickstart -> /Users/<username>/.local/pipx/venvs/sphinx-rtd-theme/bin/sphinx-autogen

as opposed to when the symlink was wrong it was like this:

lrwxr-xr-x  1 <username> 63 Apr 25 16:11 sphinx-autogen -> /Users/<username>/.local/pipx/venvs/sphinx/bin/sphinx-autogen

Upvotes: 0

Edwin Lai
Edwin Lai

Reputation: 399

Ok...WTF...I have no idea how it works, But I ran

brew remove sphinx-doc

and "make html" worked,

If anyone can answer why and how this happened, please let me know...

Upvotes: 1

Related Questions