Replies: 1 comment
-
Name has changed to https://github.com/bluss/pyproject-local-kernel It's a generalization and a better, more stable name. It was "discovered" that this kernel is just doing "rye run python -m ipykernel_launcher" - and we can generalize this to poetry run, pdm run, hatch run, pipenv run etc etc, it's quite simple really (well, let's see if it is..) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Rye seems like it can be useful for reproducible jupyterlab projects, and for sensible management of different notebooks.
There's a halfway brilliant little jupyter addon called poetry-kernel here: https://github.com/pathbird/poetry-kernel which seems to not have been updated with current versions. I found this and saw it can be applied to rye, and and I think that with Rye, maybe it comes even closer to my ideal dependency management situation for Jupyter.
The structure I want to have is that jupyter and rye are installed in the main/user installation. Jupyterlab is a user-facing application and it can open many notebooks at the same time. Each notebook can use different python and different dependencies, even if they are open in the same jupyterlab interface.
Because of this, it seems useful to have Jupyterlab at the top, and notebook files reside in different rye project directories.
With starting point in poetry-kernel, the quick hack ryeish-kernel was produced here: https://github.com/bluss/ryeish-kernel (s/poetry/rye/ and go), and it works as a proof of concept. It works really, really well.
Steps for typical use:
Now, I'm not that deeply connected with the jupyter community or python or so. If someone feels like this is a great idea and can do this rye(ish)-kernel better than me, feel free to take it and run with it.
I don't know how others would like to change this further, I guess jupyterlab and ryeish-kernel should be installed as rye tools, but I would need to bunch them together into one tool environment. (For now, it works fine to just have them installed in a separate project.)
Beta Was this translation helpful? Give feedback.
All reactions