(prbi) PS C:\Users\WXF\AppData\Roaming\jupyter\kernels\prbi> jupyter notebook Traceback (most recent call last): File "D:\Anaconda3_202205\Scripts\jupyter-notebook-script.py", line 6, in <module> from notebook.notebookapp import main File "D:\Anaconda3_202205\lib\site-packages\notebook\notebookapp.py", line 44, in <module> from jinja2 import Environment, FileSystemLoader File "D:\Anaconda3_202205\lib\site-packages\jinja2\__init__.py", line 12, in <module> from .environment import Environment File "D:\Anaconda3_202205\lib\site-packages\jinja2\environment.py", line 25, in <module> from .defaults import BLOCK_END_STRING File "D:\Anaconda3_202205\lib\site-packages\jinja2\defaults.py", line 3, in <module> from .filters import FILTERS as DEFAULT_FILTERS # noqa: F401 File "D:\Anaconda3_202205\lib\site-packages\jinja2\filters.py", line 13, in <module> from markupsafe import soft_unicode ImportError: cannot import name 'soft_unicode' from 'markupsafe' (D:\Anaconda3_202205\lib\site-packages\markupsafe\__init__.py)
时间: 2023-07-21 20:56:45 浏览: 203
这个问题看起来是在执行 Jupyter Notebook 时出现了 ImportError: cannot import name 'soft_unicode' from 'markupsafe' (D:\Anaconda3_202205\lib\site-packages\markupsafe\__init__.py) 的错误。这个错误通常是由于 Markupsafe 包的版本与 Jupyter Notebook 不兼容所导致的。您可以尝试更新 Markupsafe 包,或者尝试使用 Conda 或 Pip 等包管理工具重新安装 Markupsafe 包,以解决这个问题。
阅读全文