loud-laptop-89838
01/02/2023, 8:46 PMjupyter-book on a jupyter notebook (rather than markdown) the pex doesn't have ipykernel properly setup. The issue is documented here: github.com/jupyter/notebook/issues/2636
I don't have a lot of familiarity with the jupyter kernel, but it looks like the issue is that the kernel isn't properly set up in the sandbox. Looking for anyone who's found a solution? I tried using the pants-jupyter-plugin to no avail.enough-analyst-54434
01/02/2023, 8:55 PM--venv PEXes are new since then and install themselves as a standard venv before running the 1st time. You may need to specify --venv-site-packages-copies, but with those two options a PEX should be pretty much indistinguishable from a non PEX. This was written from a Pex perspective and not a Pants perspective. I like to disentangle the two when debugging issues like this.
Have you experiment with venv knobs, etc?loud-laptop-89838
01/02/2023, 8:58 PMloud-laptop-89838
01/02/2023, 8:59 PMPexProcess for jupyter-book, which itself then runs jupyter notebooks.enough-analyst-54434
01/02/2023, 9:01 PMpex CLI. Mess with options, debug, get that working, build back up.loud-laptop-89838
01/02/2023, 9:01 PMenough-analyst-54434
01/02/2023, 9:01 PMloud-laptop-89838
01/02/2023, 9:01 PMenough-analyst-54434
01/02/2023, 9:01 PMloud-laptop-89838
01/02/2023, 9:02 PMenough-analyst-54434
01/02/2023, 9:03 PMloud-laptop-89838
01/03/2023, 1:59 PMpex $(pip freeze) -c jupyter-book -o jb.pex. My understanding is that this sets up the pex to use a console script. So rather than running python -m jupyter-book it just runs jupyter-book in the pex env.
When I use PexProcess I write main=ConsoleScript("jupyter-book"), but in the sandbox that is created there is a pex directory rather than a binary file, and the kernel issue comes up. Any ideas on what the difference is?enough-analyst-54434
01/03/2023, 2:43 PM-ldebug --no-local-cache - all Process arguments will be printed, including the one that builds that PEX. Then you can directly compare using the Pex CLI and hopefully repro / isolate the difference.enough-analyst-54434
01/03/2023, 2:45 PM