jupyter nbconvert --to html SymMeasNodeNet.ipynb
Traceback (most recent call last):
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/traitlets.py", line 537, in get
value = obj._trait_values[self.name]
KeyError: 'template_paths'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/homebrew/bin/jupyter-nbconvert", line 8, in <module>
sys.exit(main())
File "/opt/homebrew/lib/python3.9/site-packages/jupyter_core/application.py", line 269, in launch_instance
return super().launch_instance(argv=argv, **kwargs)
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/config/application.py", line 846, in launch_instance
app.start()
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/nbconvertapp.py", line 414, in start
self.convert_notebooks()
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/nbconvertapp.py", line 582, in convert_notebooks
cls = get_exporter(self.export_format)
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/base.py", line 101, in get_exporter
if getattr(exporter(config=config), "enabled", True):
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/templateexporter.py", line 341, in __init__
super().__init__(config=config, **kw)
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/exporter.py", line 117, in __init__
self._init_preprocessors()
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/templateexporter.py", line 507, in _init_preprocessors
conf = self._get_conf()
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/templateexporter.py", line 525, in _get_conf
for path in map(Path, self.template_paths):
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/traitlets.py", line 577, in __get__
return self.get(obj, cls)
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/traitlets.py", line 540, in get
default = obj.trait_defaults(self.name)
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/traitlets.py", line 1580, in trait_defaults
return self._get_trait_default_generator(names[0])(self)
File "/opt/homebrew/lib/python3.9/site-packages/traitlets/traitlets.py", line 977, in __call__
return self.func(*args, **kwargs)
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/templateexporter.py", line 536, in _template_paths
template_names = self.get_template_names()
File "/opt/homebrew/lib/python3.9/site-packages/nbconvert/exporters/templateexporter.py", line 620, in get_template_names
raise ValueError(
ValueError: No template sub-directory with name 'lab' found in the following paths:
/Users/dguger/Library/Jupyter
/Users/dguger/Library/Python/3.9/share/jupyter
/opt/homebrew/opt/python@3.9/Frameworks/Python.framework/Versions/3.9/share/jupyter
/usr/local/share/jupyter
/usr/share/jupyter
Description
I want to export a pdf of my jupyter notebook (.ipynb) file, but this doesn't work, as it can't resolve the template_path.
Stacktrace:
Can you list steps to reproduce this issue?
Try to export a file using
nbconverton macOS.Environment Data: