napalm
napalm copied to clipboard
Documentation is outdated due to a build error
Hello,
Documentation hosted on RTD is outdated, there is an issue when building the documentation
https://readthedocs.org/projects/napalm/builds
Last successfull operation was 3 months ago
Traceback (most recent call last):
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/registry.py", line 472, in load_extension
mod = __import__(extname, None, None, ['setup'])
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/builders/latex/__init__.py", line 37, in <module>
from sphinx.writers.latex import DEFAULT_SETTINGS, LaTeXWriter, LaTeXTranslator
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/writers/latex.py", line 33, in <module>
from sphinx.util.template import LaTeXRenderer
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/util/template.py", line 17, in <module>
from sphinx.jinja2glue import SphinxFileSystemLoader
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/jinja2glue.py", line 16, in <module>
from jinja2 import FileSystemLoader, BaseLoader, TemplateNotFound, \
ImportError: cannot import name 'contextfunction' from 'jinja2' (/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/jinja2/__init__.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/cmd/build.py", line 303, in build_main
args.tags, args.verbosity, args.jobs, args.keep_going)
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/application.py", line 224, in __init__
self.setup_extension(extension)
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/application.py", line 449, in setup_extension
self.registry.load_extension(self, extname)
File "/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/sphinx/registry.py", line 475, in load_extension
raise ExtensionError(__('Could not import extension %s') % extname, err)
sphinx.errors.ExtensionError: Could not import extension sphinx.builders.latex (exception: cannot import name 'contextfunction' from 'jinja2' (/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/jinja2/__init__.py))
Extension error:
Could not import extension sphinx.builders.latex (exception: cannot import name 'contextfunction' from 'jinja2' (/home/docs/checkouts/readthedocs.org/user_builds/napalm/envs/stable/lib/python3.7/site-packages/jinja2/__init__.py))
https://github.com/napalm-automation/napalm/blob/ef8326ceb925439b3031017c75ea5e2ca4392e2e/requirements.txt#L7
Probably related with this https://github.com/mkdocs/mkdocs/issues/2799
Should be fixed here:
https://github.com/napalm-automation/napalm/pull/1700
This PR still needs to be merged.
@M0NsTeRRR Thanks for letting us know.
Build is still failling, I don't have time to look into in before one or two weeks
I assume it works with #1734 make doctest
build succeeded.
The HTML pages are in _build/html.
It's a little ugly some dependencies are outdated, an other issue should be opened to clean and upgrade documentation dependencies, also all dependencies should be pinned with their appropriate version. There is a lot of requirements.txt file maybe we could reduce the number.
I don't know why there is an error on test, on my laptop I don't get this if someone can look into in
I've added this PR that should fix readthedoc build