我正在使用nbconvert
将 markdown 文件转换为 pdf。在我使用的代码中writer = nbconvert.RSTExporter()
,但是当使用 渲染结果时writer.from_notebook_node()
,我遇到了错误:
ValueError: No template sub-directory with name 'rst' found in the following paths:
/Users/hoanguyen/Library/Jupyter
/Users/hoanguyen/miniconda3/envs/d2l-book/share/jupyter #this is my current environment
/usr/local/share/jupyter
/usr/share/jupyter
Run Code Online (Sandbox Code Playgroud)
代码可以在这里看到:https://github.com/d2l-ai/d2l-book/blob/dev/d2lbook/build.py#L653-L657
我用这个指令nbconvert
安装了pandoc ,并且我也安装了。Tex
如何安装rst
模板nbconvert
?请帮我建议一些解决此问题的方法?
系统信息:
ProductName: Mac OS X
ProductVersion: 10.15.1
python: 3.6
nbconvert: 6.0.0a3
pandoc: 1.0.2
Run Code Online (Sandbox Code Playgroud)