···997998### Interpreters {#interpreters}
9991000-Versions 2.7, 3.8, 3.9, 3.10 and 3.11 of the CPython interpreter are available
1001-as respectively `python27`, `python38`, `python39`, `python310` and `python311`.
1002-The aliases `python2` and `python3` correspond to respectively `python27` and
1003-`python310`. The attribute `python` maps to `python2`. The PyPy interpreters
1004-compatible with Python 2.7 and 3 are available as `pypy27` and `pypy3`, with
1005-aliases `pypy2` mapping to `pypy27` and `pypy` mapping to `pypy2`. The Nix
1006-expressions for the interpreters can be found in
000001007`pkgs/development/interpreters/python`.
10081009All packages depending on any Python interpreter get appended
···33 '';
3435 meta = with lib; {
036 description = "A modern media center that gives you the freedom to watch everything you want.";
37 homepage = "https://www.stremio.com/";
38 # (Server-side) web UI is closed source now, apparently they work on open-sourcing it.
···33 '';
3435 meta = with lib; {
36+ mainProgram = "stremio";
37 description = "A modern media center that gives you the freedom to watch everything you want.";
38 homepage = "https://www.stremio.com/";
39 # (Server-side) web UI is closed source now, apparently they work on open-sourcing it.
···1+diff --git a/exputils/gui/jupyter/__init__.py b/exputils/gui/jupyter/__init__.py
2+index 6e9aefb..fdfdd28 100644
3+--- a/exputils/gui/jupyter/__init__.py
4++++ b/exputils/gui/jupyter/__init__.py
5+@@ -30,8 +30,8 @@ from exputils.gui.jupyter.misc import remove_children_from_widget
6+ from exputils.gui.jupyter.misc import set_children_of_widget
7+ from exputils.gui.jupyter.misc import generate_random_state_backup_name
8+9+-from exputils.gui.jupyter.ipynbname import get_notebook_name
10+-from exputils.gui.jupyter.ipynbname import get_notebook_path
11++from ipynbname import name as get_notebook_name
12++from ipynbname import path as get_notebook_path
13+14+ DEFAULT_CONFIG_DIRECTORY = '.ipython_config'
15+16+diff --git a/exputils/gui/jupyter/ipynbname.py b/exputils/gui/jupyter/ipynbname.py
17+deleted file mode 100644
18+index 51e21b7..0000000
19+--- a/exputils/gui/jupyter/ipynbname.py
20++++ /dev/null
21+@@ -1,86 +0,0 @@
22+-##
23+-## This file is part of the exputils package.
24+-##
25+-## Copyright: INRIA
26+-## Year: 2022, 2023
27+-## Contact: chris.reinke@inria.fr
28+-##
29+-## exputils is provided under GPL-3.0-or-later
30+-##
31+-# Taken from https://pypi.org/project/ipynbname/
32+-# TODO: add them to licence
33+-
34+-from notebook import notebookapp
35+-import urllib, json, os, ipykernel, ntpath
36+-
37+-FILE_ERROR = "Can't identify the notebook {}."
38+-CONN_ERROR = "Unable to access server;\n \
39+- + ipynbname requires either no security or token based security."
40+-
41+-def _get_kernel_id():
42+- """ Returns the kernel ID of the ipykernel.
43+- """
44+- connection_file = os.path.basename(ipykernel.get_connection_file())
45+- kernel_id = connection_file.split('-', 1)[1].split('.')[0]
46+- return kernel_id
47+-
48+-
49+-def _get_sessions(srv):
50+- """ Given a server, returns sessions, or HTTPError if access is denied.
51+- NOTE: Works only when either there is no security or there is token
52+- based security. An HTTPError is raised if unable to connect to a
53+- server.
54+- """
55+- try:
56+- qry_str = ""
57+- token = srv['token']
58+- if token:
59+- qry_str = f"?token={token}"
60+- url = f"{srv['url']}api/sessions{qry_str}"
61+- req = urllib.request.urlopen(url)
62+- return json.load(req)
63+- except:
64+- raise urllib.error.HTTPError(CONN_ERROR)
65+-
66+-
67+-def _get_nb_path(sess, kernel_id):
68+- """ Given a session and kernel ID, returns the notebook path for the
69+- session, or None if there is no notebook for the session.
70+- """
71+- if sess['kernel']['id'] == kernel_id:
72+- return sess['notebook']['path']
73+- return None
74+-
75+-
76+-def get_notebook_name():
77+- """ Returns the short name of the notebook w/o the .ipynb extension,
78+- or raises a FileNotFoundError exception if it cannot be determined.
79+- """
80+- kernel_id = _get_kernel_id()
81+- for srv in notebookapp.list_running_servers():
82+- try:
83+- sessions = _get_sessions(srv)
84+- for sess in sessions:
85+- nb_path = _get_nb_path(sess, kernel_id)
86+- if nb_path:
87+- return ntpath.basename(nb_path).replace('.ipynb', '')
88+- except:
89+- pass # There may be stale entries in the runtime directory
90+- raise FileNotFoundError(FILE_ERROR.format('name'))
91+-
92+-
93+-def get_notebook_path():
94+- """ Returns the absolute path of the notebook,
95+- or raises a FileNotFoundError exception if it cannot be determined.
96+- """
97+- kernel_id = _get_kernel_id()
98+- for srv in notebookapp.list_running_servers():
99+- try:
100+- sessions = _get_sessions(srv)
101+- for sess in sessions:
102+- nb_path = _get_nb_path(sess, kernel_id)
103+- if nb_path:
104+- return os.path.join(srv['notebook_dir'], nb_path)
105+- except:
106+- pass # There may be stale entries in the runtime directory
107+- raise FileNotFoundError(FILE_ERROR.format('path'))
108+\ No newline at end of file
109+diff --git a/setup.cfg b/setup.cfg
110+index 9d9cbb0..6080ed6 100644
111+--- a/setup.cfg
112++++ b/setup.cfg
113+@@ -25,3 +25,4 @@ install_requires =
114+ tensorboard >= 1.15.0
115+ fasteners >= 0.18
116+ pyyaml >= 6.0
117++ ipynbname