简体   繁体   English

导出 Jupyter 笔记本在 VSCode 中不起作用

[英]Exporting Jupyter notebook doesn't work in VSCode

I'm using VSCode with WSL Ubuntu 20.04.我将 VSCode 与 WSL Ubuntu 20.04 一起使用。 I'm trying to export a Jupyter notebook to PDF or HTML in VSCode using the built-in Export feature in the Jupyter extension.我正在尝试使用 Jupyter 扩展中的内置导出功能将 Jupyter 笔记本导出到 VSCode 中的 PDF 或 HTML。 I get this error message: Jupyter command 'jupyter-nbconvert' not found.我收到此错误消息: Jupyter command 'jupyter-nbconvert' not found.

Things I have tried:我尝试过的事情:

  • Changing the interpreter that starts Jupyter in VSCode在 VSCode 中更改启动 Jupyter 的解释器
  • Uninstalling and reinstalling jupyter and nbconvert in the integrated terminal在集成终端中卸载并重新安装 jupyter 和 nbconvert
  • Making sure the path where Jupyter is installed is on my PATH确保安装 Jupyter 的路径在我的 PATH 上

Things I have not tried that were suggested by others in this similar question :我没有尝试过其他人在这个类似问题中建议的事情:

  • Uninstalling and reinstalling jupyter and nbconvert in Powershell.在 Powershell 中卸载并重新安装 jupyter 和 nbconvert。 How would one do this?如何做到这一点? pip3 install nbconvert returns this error: pip3: The term 'pip3' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. pip3 install nbconvert返回此错误: pip3: The term 'pip3' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again. pip3: The term 'pip3' is not recognized as the name of a cmdlet, function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.

Running which nbconvert from the integrated terminal returns nothing.从集成终端运行which nbconvert不会返回任何内容。 I installed nbconvert via pip3.我通过 pip3 安装了 nbconvert。

pip3: The term 'pip3' is not recognized as the name of a cmdlet pip3:术语“pip3”未被识别为 cmdlet 的名称

Try this command to install nbconvert:试试这个命令来安装 nbconvert:

python -m pip install nbconvert -U

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM