Closed KyleKing closed 3 years ago
The problem was that the custom_dir
was not an absolute path and it works when set to custom_dir = "/Users/kyleking/Developer/recipes/docs/_theme"
Follow up questions:
"docs/_theme"
path into an absolute path rather than having the user specify the full path?
os.path.join(os.path.dirname(__file__), theme["custom_dir"])
somewhere around here: https://github.com/timothycrosley/portray/blob/master/portray/config.py#L212as_html --local
be of interest to support this configuration out of the box?Update: submitted a PR to resolve the absolute path. The config item as_html --local
is likely too specific to this one use case and would potentially create edge cases where merging configuration options would be challenging
I ran into some issues configuring the as_html output to work locally (navigation and search of the HTML documentation without
mkdocs serve
). The error also happens when usingin_browser
Working MKDocs setup
poetry add mkdocs-localsearch
In
mkdocs.yml
In
docs/_theme/main.html
Portray Configuration
To
pyproject.toml
If I comment out the last line (
custom_dir = "docs/_theme"
), the rest of the configuration seems to work fineError
Python 3.8.3 and portray Version: 1.4.0
When running
poetry run portray as_html
(orin_browser
), I get this error:Summary
What configuration information is portray missing?