Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Jupyter notebook not loading in the Python tool

FilipR
11 - Bolide

After trying to install PyCaret via cmd (following the instruction I found here: https://community.alteryx.com/t5/Alteryx-Designer-Knowledge-Base/Install-Python-packages-via-command...), I got some red error messages about incompatible libraries. After that the Python tool stopped working. If it is in Interactive mode, Jupyter notebook does not load and if I try to run the workflow, I will get an error like the below (which, from what I understand, is caused by no code being pushed from the tool to Python):

 

Error: Python (69): Traceback (most recent call last):  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\runpy.py", line 194, in _run_module_as_main    return _run_code(code, main_globals, None,  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\runpy.py", line 87, in _run_code    exec(code, run_globals)  File "C:\Users\Filip.R\AppData\Local\Alteryx\bin\Miniconda3\envs\JupyterTool_vEnv\Scripts\jupyter-nbconvert.EXE\__main__.py", line 4, in <module>  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\nbconvert\__init__.py", line 4, in <module>    from .exporters import *  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\nbconvert\exporters\__init__.py", line 3, in <module>    from .html import HTMLExporter  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\nbconvert\exporters\html.py", line 11, in <module>    from jinja2 import contextfilter  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\jinja2\__init__.py", line 33, in <module>    from jinja2.environment import Environment, Template  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\jinja2\environment.py", line 15, in <module>    from jinja2 import nodes  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\jinja2\nodes.py", line 19, in <module>    from jinja2.utils import Markup  File "c:\users\filip.r\appdata\local\alteryx\bin\miniconda3\envs\jupytertool_venv\lib\site-packages\jinja2\utils.py", line 647, in <module>    from markupsafe import Markup, escape, soft_unicodeImportError: cannot import name 'soft_unicode' from 'markupsafe' (C:\Users\Filip.R\AppData\Roaming\Python\Python38\site-packages\markupsafe\__init__.py)

 

 

I am using Alteryx 2020.4.6.36807. Mainly the Non-Admin version, but I have the regular one also installed.

 

I tried reinstalling the Non-Admin version of Alteryx but it didn't help (even though it looked like it was reinstalling the Python packages as well). Reinstalling the regular version didn't help either.

 

3 REPLIES 3
PhilipMannering
16 - Nebula
16 - Nebula

I had a similar problem. Try,

C:\Users\filip.r\AppData\Local\Alteryx\bin\Miniconda3\Scripts\pip.exe uninstall markupsafe

in Powershell / Command Prompt.

FilipR
11 - Bolide

@PhilipMannering you're a lifesaver! It works like a charm. Thanks!

clmc9601
13 - Pulsar
13 - Pulsar

Thanks, @PhilipMannering!! This was super helpful for me.

 

I still needed markupsafe to run Jupyter locally on my machine, but downgrading markupsafe worked for me. I read online that this function "soft_unicode" was deprecated in the newest version of markupsafe. 

 

Also, since I use admin Designer, my filepath was slightly different.

 

"C:\Program Files\Alteryx\bin\Miniconda3\Scripts\pip.exe" install markupsafe==2.0.1 --force-reinstall

 

For anyone running this from Mac with Parallels, I had to run this from my Command Prompt within Windows, not my Mac Terminal 😅

Labels