mkdocs-material: Error: Unrecognised theme 'material'
Guys i am trying to use this great looking material theme. As mentioned in instructions i did installation and setup like this.
pip install mkdocs-material
- Added
theme: 'material'
inmkdocs.yml
- Restarted
mkdocs serve
Browser did’nt got updated with material theme, instead i am getting this in mkdocs serve logs. Can you please help
INFO - Building documentation...
ERROR - Config value: 'theme'. Error: Unrecognised theme 'material'. The available installed themesare:
[E 161010 01:48:04 ioloop:633] Exception in callback <bound method type.poll_tasks of <class 'livereload.handlers.LiveReloadHandler'>>
Traceback (most recent call last):
File "/usr/local/lib/python2.7/site-packages/tornado/ioloop.py", line 1041, in _run
return self.callback()
File "/usr/local/lib/python2.7/site-packages/livereload/handlers.py", line 66, in poll_tasks
filepath, delay = cls.watcher.examine()
File "/usr/local/lib/python2.7/site-packages/livereload/watcher.py", line 73, in examine
func and func()
File "/usr/local/lib/python2.7/site-packages/mkdocs/commands/serve.py", line 71, in builder
theme=theme,
File "/usr/local/lib/python2.7/site-packages/mkdocs/config/base.py", line 164, in load_config
"Aborted with {0} Configuration Errors!".format(len(errors))
ConfigurationError: Aborted with 1 Configuration Errors!
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Reactions: 2
- Comments: 26 (8 by maintainers)
Commits related to this issue
- Prepare release 100.0.10 (#52) — committed to paulocfjunior/mkdocs-material by mmatur 3 years ago
SOLVED!
@JerryC8080 thank you so much for your help.
I had at some point installed mkdocs via Homebrew and later switched to the pip install. Somewhere my config paths had become mixed up.
Solution:
@ksingh7 @g0dlight
Your are suggested to make
mkdocs
andmeterial
on the save way.Such as both installed by
pip
.I meet the same problem when I installed mkdocs by
brew install mkdocs
and meterial bypip install mkdocs-meterial
.We can see the differ of variable
theme_dir
that mkdocs on different way installed.On My Device:
On
brew install mkdocs
On
pip install mkdocs
And
pip install mkdocs-meterial
So, Make
mkdocs
andthemes
install in the save directory. Becausemkdocs build
andmkdocs serve
command will load the same level directory to find theme.Hope the way i solve my problem will be same on you.
In the mkdocs.yml file, you should change this line as follows:
to this version,
OR
Added a new section called Troubleshooting: http://squidfunk.github.io/mkdocs-material/getting-started/#troubleshooting
It has to be
custom_dir
, see: https://squidfunk.github.io/mkdocs-material/getting-started/#configuration