Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jupyter Lab server extension not found in binder #470

Closed
jld23 opened this issue Apr 8, 2021 · 2 comments
Closed

Jupyter Lab server extension not found in binder #470

jld23 opened this issue Apr 8, 2021 · 2 comments
Labels

Comments

@jld23
Copy link

jld23 commented Apr 8, 2021

Description

I have created a JupyterLab extension
that converts a SAS file (*.sas) to a Jupyter notebook (*.ipynb).

The extension works fine on my development systems (Ubuntu and OSX) but when I try and use it inside of binder I get 404 errors.

I had participated on an issue in January where @fcollonval referrenced issues but the links to that appear to have been merged. Which lead me to believe the issue was resolved.
I added the following line to my init.py but that didn't change the behavior
load_jupyter_server_extension = _load_jupyter_server_extension

Reproduce

  1. Launch the binder instance -- https://mybinder.org/v2/gh/jld23/sas_kernel_ext/HEAD
  2. In the root folder, right click on iris.sas
  3. The first entry in the context menu should be 'Convert SAS to ipynb' select that menu entry.
  4. Outside of binder, after a few seconds a pop-up appears saying the file was converted. Inside binder nothing happens.
  5. If you look at the browser console you'll see something similar to this:
JupyterLab extension sas2nb is activated! index.js:15
XHRGEThttps://hub.gke2.mybinder.org/user/jld23-sas_kernel_ext-6frabum6/sas2nb/convert?1617907266164
[HTTP/2 404 Not Found 649ms]

Not a JSON response body. 
Response { type: "basic", url: "https://hub.gke2.mybinder.org/user/jld23-sas_kernel_ext-6frabum6/sas2nb/convert?1617907266164", redirected: false, status: 404, ok: false, statusText: "Not Found", headers: Headers, body: ReadableStream, bodyUsed: true }
handler.js:28
The sas2nb server extension appears to be missing.
Error: <!DOCTYPE HTML>
<html>

The log states that the extension is missing but the following output doesn't support that:

jovyan@jupyter-jld23-2dsas-5fkernel-5fext-2d6frabum6:~/sas2nb$ jupyter labextension list
JupyterLab v3.0.7
/srv/conda/envs/notebook/share/jupyter/labextensions
        jupyter-offlinenotebook v0.2.1 enabled OK
        jlab-create-sas-file v0.1.0 enabled OK (python, jlab_create_sas_file)
        sas2nb v0.1.0 enabled OK
        @jupyter-server/resource-usage v0.5.0 enabled OK (python, jupyter-resource-usage)
        @jupyter-widgets/jupyterlab-manager v3.0.0 enabled OK (python, jupyterlab_widgets)
jovyan@jupyter-jld23-2dsas-5fkernel-5fext-2d6frabum6:~/sas2nb$ jupyter server extension list
Config dir: /home/jovyan/.jupyter

Config dir: /srv/conda/envs/notebook/etc/jupyter
    jupyter_resource_usage enabled
    - Validating jupyter_resource_usage...
      jupyter_resource_usage  OK
    jupyterlab enabled
    - Validating jupyterlab...
      jupyterlab 3.0.7 OK
    nbclassic enabled
    - Validating nbclassic...
      nbclassic  OK
    jupyter_offlinenotebook enabled
    - Validating jupyter_offlinenotebook...
      jupyter_offlinenotebook  OK
    sas2nb enabled
    - Validating sas2nb...
      sas2nb 0.1.0 OK

Config dir: /usr/local/etc/jupyter

Expected behavior

I expected the extension to work inside binder as it does outside of binder.

Context

  • Operating System and version: Fails on Binder but works on Ubuntu 20 and OSX
  • Browser and version: N/A
  • JupyterLab version: 3.0.7
    Here is jupyter package output from pip list inside of binder
jupyter-client                6.1.11
jupyter-core                  4.7.1
jupyter-offlinenotebook       0.2.1
jupyter-resource-usage        0.5.1
jupyter-server                1.4.0
jupyter-telemetry             0.1.0
jupyterhub                    1.3.0
jupyterlab                    3.0.7
jupyterlab-pygments           0.1.2
jupyterlab-server             2.3.0
jupyterlab-widgets            1.0.0
Troubleshoot Output
jovyan@jupyter-jld23-2dsas-5fkernel-2dob8tvtw3:~$ jupyter troubleshoot
$PATH:
        /srv/conda/envs/notebook/bin
        /srv/conda/condabin
        /home/jovyan/.local/bin
        /home/jovyan/.local/bin
        /srv/conda/envs/notebook/bin
        /srv/conda/bin
        /srv/npm/bin
        /usr/local/sbin
        /usr/local/bin
        /usr/sbin
        /usr/bin
        /sbin
        /bin

sys.path:
/srv/conda/envs/notebook/bin
/srv/conda/envs/notebook/lib/python37.zip
/srv/conda/envs/notebook/lib/python3.7
/srv/conda/envs/notebook/lib/python3.7/lib-dynload
/srv/conda/envs/notebook/lib/python3.7/site-packages

sys.executable:
/srv/conda/envs/notebook/bin/python

sys.version:
3.7.10 | packaged by conda-forge | (default, Feb 19 2021, 16:07:37)
[GCC 9.3.0]

platform.platform():
Linux-4.19.150+-x86_64-with-debian-buster-sid

which -a jupyter:
/srv/conda/envs/notebook/bin/jupyter
/srv/conda/envs/notebook/bin/jupyter

pip list:
Package Version
----------------------------- -------------------
alembic 1.5.5
anyio 2.1.0
argon2-cffi 20.1.0
async-generator 1.10
attrs 20.3.0
Babel 2.9.0
backcall 0.2.0
backports.functools-lru-cache 1.6.1
bleach 3.3.0
blinker 1.4
brotlipy 0.7.0
certifi 2020.12.5
certipy 0.1.3
cffi 1.14.5
chardet 4.0.0
cryptography 3.4.4
decorator 4.4.2
defusedxml 0.6.0
entrypoints 0.3
idna 2.10
importlib-metadata 3.4.0
ipykernel 5.5.0
ipython 7.20.0
ipython-genutils 0.2.0
ipywidgets 7.6.3
jedi 0.18.0
Jinja2 2.11.3
jlab-create-sas-file 0.1.0
json5 0.9.5
jsonschema 3.2.0
jupyter-client 6.1.11
jupyter-core 4.7.1
jupyter-offlinenotebook 0.2.1
jupyter-resource-usage 0.5.1
jupyter-server 1.4.0
jupyter-telemetry 0.1.0
jupyterhub 1.3.0
jupyterlab 3.0.7
jupyterlab-pygments 0.1.2
jupyterlab-server 2.3.0
jupyterlab-widgets 1.0.0
Mako 1.1.4
MarkupSafe 1.1.1
metakernel 0.27.5
mistune 0.8.4
nbclassic 0.2.6
nbclient 0.5.2
nbconvert 6.0.7
nbformat 5.1.2
nest-asyncio 1.4.3
notebook 6.2.0
nteract-on-jupyter 2.1.3
numpy 1.20.2
oauthlib 3.0.1
packaging 20.9
pamela 1.0.0
pandas 1.2.3
pandocfilters 1.4.2
parso 0.8.1
pexpect 4.8.0
pickleshare 0.7.5
pip 21.0.1
prometheus-client 0.9.0
prompt-toolkit 3.0.16
psutil 5.8.0
ptyprocess 0.7.0
pycparser 2.20
pycurl 7.43.0.6
Pygments 2.8.0
PyJWT 2.0.1
pyOpenSSL 20.0.1
pyparsing 2.4.7
pyrsistent 0.17.3
PySocks 1.7.1
python-dateutil 2.8.1
python-editor 1.0.4
python-json-logger 2.0.1
pytz 2021.1
pyzmq 22.0.3
requests 2.25.1
ruamel.yaml 0.16.12
ruamel.yaml.clib 0.2.2
SAS-kernel 2.3.1
sas2nb 0.1.0
saspy 3.6.6
Send2Trash 1.5.0
setuptools 49.6.0.post20210108
six 1.15.0
sniffio 1.2.0
SQLAlchemy 1.3.23
terminado 0.9.2
testpath 0.4.4
tornado 6.1
traitlets 5.0.5
typing-extensions 3.7.4.3
urllib3 1.26.3
wcwidth 0.2.5
webencodings 0.5.1
wheel 0.36.2
widgetsnbextension 3.5.1
zipp 3.4.0

conda list:
# packages in environment at /srv/conda/envs/notebook:
#
# Name Version Build Channel
_libgcc_mutex 0.1 conda_forge conda-forge
_openmp_mutex 4.5 1_gnu conda-forge
alembic 1.5.5 pyhd8ed1ab_0 conda-forge
anyio 2.1.0 py37h89c1867_0 conda-forge
argon2-cffi 20.1.0 py37h8f50634_2 conda-forge
async_generator 1.10 py_0 conda-forge
attrs 20.3.0 pyhd3deb0d_0 conda-forge
babel 2.9.0 pyhd3deb0d_0 conda-forge
backcall 0.2.0 pyh9f0ad1d_0 conda-forge
backports 1.0 py_2 conda-forge
backports.functools_lru_cache 1.6.1 py_0 conda-forge
bleach 3.3.0 pyh44b312d_0 conda-forge
blinker 1.4 py_1 conda-forge
brotlipy 0.7.0 py37hb5d75c8_1001 conda-forge
c-ares 1.17.1 h36c2ea0_0 conda-forge
ca-certificates 2020.12.5 ha878542_0 conda-forge
certifi 2020.12.5 py37h89c1867_1 conda-forge
certipy 0.1.3 py_0 conda-forge
cffi 1.14.5 py37hc58025e_0 conda-forge
chardet 4.0.0 py37h89c1867_1 conda-forge
cryptography 3.4.4 py37hf1a17b8_0 conda-forge
decorator 4.4.2 py_0 conda-forge
defusedxml 0.6.0 py_0 conda-forge
entrypoints 0.3 py37hc8dfbb8_1002 conda-forge
idna 2.10 pyh9f0ad1d_0 conda-forge
importlib-metadata 3.4.0 py37h89c1867_0 conda-forge
importlib_metadata 3.4.0 hd8ed1ab_0 conda-forge
ipykernel 5.5.0 py37h888b3d9_1 conda-forge
ipython 7.20.0 py37h888b3d9_2 conda-forge
ipython_genutils 0.2.0 py_1 conda-forge
ipywidgets 7.6.3 pyhd3deb0d_0 conda-forge
jedi 0.18.0 py37h89c1867_2 conda-forge
jinja2 2.11.3 pyh44b312d_0 conda-forge
jlab-create-sas-file 0.1.0 pypi_0 pypi
json5 0.9.5 pyh9f0ad1d_0 conda-forge
jsonschema 3.2.0 py37hc8dfbb8_1 conda-forge
jupyter-offlinenotebook 0.2.1 pyhd8ed1ab_0 conda-forge
jupyter-resource-usage 0.5.1 pyhd8ed1ab_0 conda-forge
jupyter_client 6.1.11 pyhd8ed1ab_1 conda-forge
jupyter_core 4.7.1 py37h89c1867_0 conda-forge
jupyter_server 1.4.0 py37h89c1867_0 conda-forge
jupyter_telemetry 0.1.0 pyhd8ed1ab_1 conda-forge
jupyterhub-base 1.3.0 py37h89c1867_0 conda-forge
jupyterhub-singleuser 1.3.0 py37h89c1867_0 conda-forge
jupyterlab 3.0.7 pyhd8ed1ab_0 conda-forge
jupyterlab_pygments 0.1.2 pyh9f0ad1d_0 conda-forge
jupyterlab_server 2.3.0 pyhd8ed1ab_0 conda-forge
jupyterlab_widgets 1.0.0 pyhd8ed1ab_1 conda-forge
krb5 1.17.2 h926e7f8_0 conda-forge
ld_impl_linux-64 2.35.1 hea4e1c9_2 conda-forge
libcurl 7.71.1 hcdd3856_8 conda-forge
libedit 3.1.20191231 he28a2e2_2 conda-forge
libev 4.33 h516909a_1 conda-forge
libffi 3.3 h58526e2_2 conda-forge
libgcc-ng 9.3.0 h2828fa1_18 conda-forge
libgomp 9.3.0 h2828fa1_18 conda-forge
libnghttp2 1.43.0 h812cca2_0 conda-forge
libsodium 1.0.18 h516909a_1 conda-forge
libssh2 1.9.0 hab1572f_5 conda-forge
libstdcxx-ng 9.3.0 h6de172a_18 conda-forge
mako 1.1.4 pyh44b312d_0 conda-forge
markupsafe 1.1.1 py37h5e8e339_3 conda-forge
metakernel 0.27.5 pypi_0 pypi
mistune 0.8.4 py37h5e8e339_1003 conda-forge
nbclassic 0.2.6 pyhd8ed1ab_0 conda-forge
nbclient 0.5.2 pyhd8ed1ab_0 conda-forge
nbconvert 6.0.7 py37h89c1867_3 conda-forge
nbformat 5.1.2 pyhd8ed1ab_1 conda-forge
ncurses 6.2 h58526e2_4 conda-forge
nest-asyncio 1.4.3 pyhd8ed1ab_0 conda-forge
notebook 6.2.0 py37h89c1867_0 conda-forge
nteract_on_jupyter 2.1.3 py_0 conda-forge
numpy 1.20.2 pypi_0 pypi
oauthlib 3.0.1 py_0 conda-forge
openssl 1.1.1j h7f98852_0 conda-forge
packaging 20.9 pyh44b312d_0 conda-forge
pamela 1.0.0 py_0 conda-forge
pandas 1.2.3 pypi_0 pypi
pandoc 2.11.4 h7f98852_0 conda-forge
pandocfilters 1.4.2 py_1 conda-forge
parso 0.8.1 pyhd8ed1ab_0 conda-forge
pexpect 4.8.0 py37hc8dfbb8_1 conda-forge
pickleshare 0.7.5 py37hc8dfbb8_1002 conda-forge
pip 21.0.1 pyhd8ed1ab_0 conda-forge
prometheus_client 0.9.0 pyhd3deb0d_0 conda-forge
prompt-toolkit 3.0.16 pyha770c72_0 conda-forge
psutil 5.8.0 py37h5e8e339_1 conda-forge
ptyprocess 0.7.0 pyhd3deb0d_0 conda-forge
pycparser 2.20 pyh9f0ad1d_2 conda-forge
pycurl 7.43.0.6 py37h88a64d2_1 conda-forge
pygments 2.8.0 pyhd8ed1ab_0 conda-forge
pyjwt 2.0.1 pyhd8ed1ab_0 conda-forge
pyopenssl 20.0.1 pyhd8ed1ab_0 conda-forge
pyparsing 2.4.7 pyh9f0ad1d_0 conda-forge
pyrsistent 0.17.3 py37h5e8e339_2 conda-forge
pysocks 1.7.1 py37h89c1867_3 conda-forge
python 3.7.10 hffdb5ce_100_cpython conda-forge
python-dateutil 2.8.1 py_0 conda-forge
python-editor 1.0.4 py_0 conda-forge
python-json-logger 2.0.1 pyh9f0ad1d_0 conda-forge
python_abi 3.7 1_cp37m conda-forge
pytz 2021.1 pyhd8ed1ab_0 conda-forge
pyzmq 22.0.3 py37h499b945_0 conda-forge
readline 8.0 he28a2e2_2 conda-forge
requests 2.25.1 pyhd3deb0d_0 conda-forge
ruamel.yaml 0.16.12 py37h5e8e339_2 conda-forge
ruamel.yaml.clib 0.2.2 py37h5e8e339_2 conda-forge
sas-kernel 2.3.1 pypi_0 pypi
sas2nb 0.1.0 pypi_0 pypi
saspy 3.6.6 pypi_0 pypi
send2trash 1.5.0 py_0 conda-forge
setuptools 49.6.0 py37h89c1867_3 conda-forge
six 1.15.0 pyh9f0ad1d_0 conda-forge
sniffio 1.2.0 py37h89c1867_1 conda-forge
sqlalchemy 1.3.23 py37h5e8e339_0 conda-forge
sqlite 3.34.0 h74cdb3f_0 conda-forge
terminado 0.9.2 py37h89c1867_0 conda-forge
testpath 0.4.4 py_0 conda-forge
tk 8.6.10 hed695b0_1 conda-forge
tornado 6.1 py37h5e8e339_1 conda-forge
traitlets 5.0.5 py_0 conda-forge
typing_extensions 3.7.4.3 py_0 conda-forge
urllib3 1.26.3 pyhd8ed1ab_0 conda-forge
wcwidth 0.2.5 pyh9f0ad1d_2 conda-forge
webencodings 0.5.1 py_1 conda-forge
wheel 0.36.2 pyhd3deb0d_0 conda-forge
widgetsnbextension 3.5.1 py37hc8dfbb8_4 conda-forge
xz 5.2.5 h516909a_1 conda-forge
zeromq 4.3.4 h9c3ff4c_0 conda-forge
zipp 3.4.0 py_0 conda-forge
zlib 1.2.11 h516909a_1010 conda-forge

conda env:
name: notebook
channels:
- conda-forge
- defaults
dependencies:
- _libgcc_mutex=0.1=conda_forge
- _openmp_mutex=4.5=1_gnu
- alembic=1.5.5=pyhd8ed1ab_0
- anyio=2.1.0=py37h89c1867_0
- argon2-cffi=20.1.0=py37h8f50634_2
- async_generator=1.10=py_0
- attrs=20.3.0=pyhd3deb0d_0
- babel=2.9.0=pyhd3deb0d_0
- backcall=0.2.0=pyh9f0ad1d_0
- backports=1.0=py_2
- backports.functools_lru_cache=1.6.1=py_0
- bleach=3.3.0=pyh44b312d_0
- blinker=1.4=py_1
- brotlipy=0.7.0=py37hb5d75c8_1001
- c-ares=1.17.1=h36c2ea0_0
- ca-certificates=2020.12.5=ha878542_0
- certifi=2020.12.5=py37h89c1867_1
- certipy=0.1.3=py_0
- cffi=1.14.5=py37hc58025e_0
- chardet=4.0.0=py37h89c1867_1
- cryptography=3.4.4=py37hf1a17b8_0
- decorator=4.4.2=py_0
- defusedxml=0.6.0=py_0
- entrypoints=0.3=py37hc8dfbb8_1002
- idna=2.10=pyh9f0ad1d_0
- importlib-metadata=3.4.0=py37h89c1867_0
- importlib_metadata=3.4.0=hd8ed1ab_0
- ipykernel=5.5.0=py37h888b3d9_1
- ipython=7.20.0=py37h888b3d9_2
- ipython_genutils=0.2.0=py_1
- ipywidgets=7.6.3=pyhd3deb0d_0
- jedi=0.18.0=py37h89c1867_2
- jinja2=2.11.3=pyh44b312d_0
- json5=0.9.5=pyh9f0ad1d_0
- jsonschema=3.2.0=py37hc8dfbb8_1
- jupyter-offlinenotebook=0.2.1=pyhd8ed1ab_0
- jupyter-resource-usage=0.5.1=pyhd8ed1ab_0
- jupyter_client=6.1.11=pyhd8ed1ab_1
- jupyter_core=4.7.1=py37h89c1867_0
- jupyter_server=1.4.0=py37h89c1867_0
- jupyter_telemetry=0.1.0=pyhd8ed1ab_1
- jupyterhub-base=1.3.0=py37h89c1867_0
- jupyterhub-singleuser=1.3.0=py37h89c1867_0
- jupyterlab=3.0.7=pyhd8ed1ab_0
- jupyterlab_pygments=0.1.2=pyh9f0ad1d_0
- jupyterlab_server=2.3.0=pyhd8ed1ab_0
- jupyterlab_widgets=1.0.0=pyhd8ed1ab_1
- krb5=1.17.2=h926e7f8_0
- ld_impl_linux-64=2.35.1=hea4e1c9_2
- libcurl=7.71.1=hcdd3856_8
- libedit=3.1.20191231=he28a2e2_2
- libev=4.33=h516909a_1
- libffi=3.3=h58526e2_2
- libgcc-ng=9.3.0=h2828fa1_18
- libgomp=9.3.0=h2828fa1_18
- libnghttp2=1.43.0=h812cca2_0
- libsodium=1.0.18=h516909a_1
- libssh2=1.9.0=hab1572f_5
- libstdcxx-ng=9.3.0=h6de172a_18
- mako=1.1.4=pyh44b312d_0
- markupsafe=1.1.1=py37h5e8e339_3
- mistune=0.8.4=py37h5e8e339_1003
- nbclassic=0.2.6=pyhd8ed1ab_0
- nbclient=0.5.2=pyhd8ed1ab_0
- nbconvert=6.0.7=py37h89c1867_3
- nbformat=5.1.2=pyhd8ed1ab_1
- ncurses=6.2=h58526e2_4
- nest-asyncio=1.4.3=pyhd8ed1ab_0
- notebook=6.2.0=py37h89c1867_0
- nteract_on_jupyter=2.1.3=py_0
- oauthlib=3.0.1=py_0
- openssl=1.1.1j=h7f98852_0
- packaging=20.9=pyh44b312d_0
- pamela=1.0.0=py_0
- pandoc=2.11.4=h7f98852_0
- pandocfilters=1.4.2=py_1
- parso=0.8.1=pyhd8ed1ab_0
- pexpect=4.8.0=py37hc8dfbb8_1
- pickleshare=0.7.5=py37hc8dfbb8_1002
- pip=21.0.1=pyhd8ed1ab_0
- prometheus_client=0.9.0=pyhd3deb0d_0
- prompt-toolkit=3.0.16=pyha770c72_0
- psutil=5.8.0=py37h5e8e339_1
- ptyprocess=0.7.0=pyhd3deb0d_0
- pycparser=2.20=pyh9f0ad1d_2
- pycurl=7.43.0.6=py37h88a64d2_1
- pygments=2.8.0=pyhd8ed1ab_0
- pyjwt=2.0.1=pyhd8ed1ab_0
- pyopenssl=20.0.1=pyhd8ed1ab_0
- pyparsing=2.4.7=pyh9f0ad1d_0
- pyrsistent=0.17.3=py37h5e8e339_2
- pysocks=1.7.1=py37h89c1867_3
- python=3.7.10=hffdb5ce_100_cpython
- python-dateutil=2.8.1=py_0
- python-editor=1.0.4=py_0
- python-json-logger=2.0.1=pyh9f0ad1d_0
- python_abi=3.7=1_cp37m
- pytz=2021.1=pyhd8ed1ab_0
- pyzmq=22.0.3=py37h499b945_0
- readline=8.0=he28a2e2_2
- requests=2.25.1=pyhd3deb0d_0
- ruamel.yaml=0.16.12=py37h5e8e339_2
- ruamel.yaml.clib=0.2.2=py37h5e8e339_2
- send2trash=1.5.0=py_0
- setuptools=49.6.0=py37h89c1867_3
- six=1.15.0=pyh9f0ad1d_0
- sniffio=1.2.0=py37h89c1867_1
- sqlalchemy=1.3.23=py37h5e8e339_0
- sqlite=3.34.0=h74cdb3f_0
- terminado=0.9.2=py37h89c1867_0
- testpath=0.4.4=py_0
- tk=8.6.10=hed695b0_1
- tornado=6.1=py37h5e8e339_1
- traitlets=5.0.5=py_0
- typing_extensions=3.7.4.3=py_0
- urllib3=1.26.3=pyhd8ed1ab_0
- wcwidth=0.2.5=pyh9f0ad1d_2
- webencodings=0.5.1=py_1
- wheel=0.36.2=pyhd3deb0d_0
- widgetsnbextension=3.5.1=py37hc8dfbb8_4
- xz=5.2.5=h516909a_1
- zeromq=4.3.4=h9c3ff4c_0
- zipp=3.4.0=py_0
- zlib=1.2.11=h516909a_1010
- pip:
- jlab-create-sas-file==0.1.0
- metakernel==0.27.5
- numpy==1.20.2
- pandas==1.2.3
- sas-kernel==2.3.1
- sas2nb==0.1.0
- saspy==3.6.6
prefix: /srv/conda/envs/notebook

Command Line Output
Paste the output from your command line running `jupyter lab` here, use `--debug` if possible.
Browser Output
![image](https://user-images.githubusercontent.com/3160523/114079304-07d79b00-9878-11eb-8ebe-7bdca89325f8.png)

@jld23 jld23 added the bug label Apr 8, 2021
@fcollonval
Copy link
Member

@jld23 you will find the information to make an extension compatible with the notebook server there:
https://jupyter-server.readthedocs.io/en/latest/developers/extensions.html#extensionapp-as-a-classic-notebook-server-extension

@jld23
Copy link
Author

jld23 commented Apr 9, 2021

Thank you @fcollonval!
For reference to any future users that incounter this problem.
The changes I needed to make from the cookiecutter setup are

  1. Add the following code to `init.py in the root folder
# For backward compatibility
load_jupyter_server_extension = _load_jupyter_server_extension
  1. take the extension json file (sas2nb.json in my case) and move if from jupyter-config to jupyter-config/jupyter_notebook_config.d and jupyter-config/jupyter_server_config.d. With minor changes needed in the notebook folder. Here are the respective files for my use case -- server and notebook.
  2. Add these two lines to the data_files_spec in setup.py
("etc/jupyter/jupyter_notebook_config.d", "jupyter-config/jupyter_notebook_config.d", "sas2nb.json"),
("etc/jupyter/jupyter_server_config.d", "jupyter-config/jupyter_server_config.d", "sas2nb.json"),

@jld23 jld23 closed this as completed Apr 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants