albertz / background-zmq-ipython

Background ZMQ IPython/Jupyter kernel
BSD 2-Clause "Simplified" License
17 stars 4 forks source link

Simplify dependencies #14

Closed user202729 closed 1 year ago

user202729 commented 1 year ago

The whole jupyter is not necessary to run this, just these 3 appear to suffice. (tested in a virtual environment, but looks like jupyter is not really well-isolated so jupyter-console seems to still work in the virtual environment even though it's not installed in there, not sure)

The latter 2 is a dependency of ipykernel in fact.

albertz commented 1 year ago

I like to keep it simple, i.e. I prefer having a single dependency instead of three dependencies.

I also like to keep it more future-proof, i.e. I want to reduce the chance that things break in the future. I'm not 100% sure those three separate packages will stay the real dependencies for the next few years, or maybe they change their internal structure and the packages get renamed, or maybe some other packages become the new dependencies.

Also, how important is this? How much bigger does the dependency get by installing whole jupyter? How realistic is it that a user does not want to install just all of jupyter?

user202729 commented 1 year ago

At it happens, in my current installation I only install IPython which drags along enough to run this, but not the whole of jupyter. I think IPython itself is relatively frequent.

At the moment if I install jupyter-notebook in addition it will install the following on my Arch Linux machine (I already have IPython and jupyter-console installed):

Package (35)                           New Version  Net Change  Download Size

extra/jupyter-nbclassic                1.0.0-1       27.61 MiB       2.47 MiB
extra/jupyter-nbclient                 0.8.0-1        0.57 MiB       0.11 MiB
extra/jupyter-nbconvert                7.6.0-2        1.88 MiB       0.30 MiB
extra/jupyter-nbformat                 5.9.0-1        0.68 MiB       0.10 MiB
extra/jupyter-notebook-shim            0.2.3-2        0.10 MiB       0.02 MiB
extra/jupyter-server                   2.7.0-1        3.31 MiB       0.49 MiB
extra/jupyterlab-pygments              0.2.2-1        0.06 MiB       0.01 MiB
extra/mathjax2                         2.7.9-1       28.23 MiB       5.99 MiB
extra/python-anyio                     3.7.0-1        1.19 MiB       0.18 MiB
extra/python-argon2-cffi-bindings      21.2.0-4       0.06 MiB       0.02 MiB
extra/python-argon2_cffi               21.3.0-3       0.10 MiB       0.02 MiB
extra/python-arrow                     1.2.3-3        0.78 MiB       0.13 MiB
extra/python-beautifulsoup4            4.12.2-1       1.68 MiB       0.27 MiB
extra/python-defusedxml                0.7.1-5        0.15 MiB       0.04 MiB
extra/python-fqdn                      1.5.1-2        0.04 MiB       0.02 MiB
extra/python-isoduration               20.11.0-3      0.08 MiB       0.02 MiB
extra/python-json-logger               2.0.7-2        0.04 MiB       0.01 MiB
extra/python-jsonpointer               2.4-1          0.03 MiB       0.01 MiB
extra/python-jupyter-events            0.6.3-4        0.14 MiB       0.03 MiB
extra/python-jupyter-server-terminals  0.4.4-4        0.08 MiB       0.02 MiB
extra/python-mistune                   2.0.5-2        0.27 MiB       0.06 MiB
extra/python-overrides                 7.3.1-2        0.15 MiB       0.03 MiB
extra/python-pandocfilters             1.5.0-3        0.05 MiB       0.01 MiB
extra/python-prometheus_client         0.17.0-1       0.61 MiB       0.12 MiB
extra/python-rfc3339-validator         0.1.4-4        0.01 MiB       0.01 MiB
extra/python-rfc3986-validator         0.1.1-2        0.02 MiB       0.01 MiB
extra/python-send2trash                1.8.2-1        0.10 MiB       0.03 MiB
extra/python-sniffio                   1.3.0-3        0.03 MiB       0.01 MiB
extra/python-soupsieve                 2.4.1-1        0.46 MiB       0.08 MiB
extra/python-terminado                 0.17.1-3       0.14 MiB       0.03 MiB
extra/python-testpath                  0.6.0-2        0.08 MiB       0.02 MiB
extra/python-tinycss2                  1.2.1-2        0.27 MiB       0.04 MiB
extra/python-uri-template              1.2.0-2        0.13 MiB       0.02 MiB
extra/python-webcolors                 1.13-2         0.13 MiB       0.03 MiB
extra/jupyter-notebook                 6.5.4-3        4.25 MiB       0.63 MiB

Total Download Size:   11.42 MiB
Total Installed Size:  73.50 MiB

Yes, these are valid considerations. Up to you.

albertz commented 1 year ago

Thanks for the information. Maybe we just use this now and once we see sth breaks with the dependencies, we revert back.