Page MenuHomeSolus

Python notebook for jupyter
Closed, ResolvedPublic

Description

Currently jupyter is included in the Solus repository. However, I found the notebook package is missing and I could not run jupyter notebook until I installed notebook using pip (pip3). I think notebook is essential for usage of jupyter and it would nice if it can be included in the repository.

Name: notebook (python)
Homepage: https://pypi.python.org/pypi/notebook
Source code: https://github.com/jupyter/notebook/archive/5.2.1.tar.gz
Is it open source? Yes
Why should it be included? I think it is one of the essential packages for jupyter which is already in the repo. This package will make the jupyter package more complete.

Event Timeline

jupyter notebook is essential to me, too. Installing it with pip seems sub-optimal for common python package like this.
Packaging is straightforward, because most dependencies are already in the solus repo.

jupyter notebook depends on terminado, which needs to be added to the repo as well.

JoshStrobl moved this task from Backlog to Accepted For Inclusion on the Package Requests board.

I have an eopkg that I'm able to install locally. However if I run the notebook and select a Python 2 kernel, it still runs with Python 3.

Available kernels:

python2    /usr/share/jupyter/kernels/python2
python3    /usr/share/jupyter/kernels/python3

But in the notebook, selecting pyhton 2, I get

import sys
sys.executable
'/usr/bin/python3'

So it's probably an issue with my package.

EDIT: The same happens if I install notebook through pip rather than my eopkg. So it's possibly an upstream issue?

I am able to run notebooks with Python 2 and Python 3 with the commands jupyter notebook and jupyter notebook3 respectively. The issue is that I can not change kernels between Python 2 and Python 3 at runtime, through the widget in the notebook. It shows no errors and the widget indicates the change of kernel, but regardless it always keeps running the Python version corresponding to the command used to start the notebook.

I think I figured out why, but if someone who is knowledgeable about this can double check I would appreciate it. The kernel.json file for the Python 3 kernel, found in /usr/share/jupyter/kernels/python3, has python as the executable, not python3. However this is created by python-ipykernel, not by notebook. So I think I can submit my package and just report an issue for python-ipykernel.

The same is true for the python2 kernel.json file, it also has python as the executable instead of python2. So if you run jupyter notebook3, the python2 kernel will use python which will be Python 3.

Oh also in addition there is the same issue as T5725.

JupyterLab just released, but it's not 1.0 yet so I don't think that it satisfies Solus inclusion policy. Version 1.0 is scheduled for 2018 though and it will replace Jupyter Notebook. Still seems to use Notebook as a dep though.

https://blog.jupyter.org/jupyterlab-is-ready-for-users-5a6f039b8906

https://github.com/jupyterlab/jupyterlab

rjurga removed rjurga as the assignee of this task.May 9 2018, 8:04 PM