the-littlest-jupyterhub icon indicating copy to clipboard operation
the-littlest-jupyterhub copied to clipboard

Some of the extension's files are not available in the notebook

Open drzamich opened this issue 5 years ago • 1 comments

Bug description

My custom Jupyter Notebook extension consist of the main.js file but also other files - JS helpers and React build artifacts. I install the package and enable the extension using the command

sudo -E jupyter nbextension install connector-jupyter --py --sys-prefix
sudo -E jupyter nbextension enable connector-jupyter --py --sys-prefix

All of the files are properly copied to the nbextensions directory:

admin@tec-l-011630:~$ ls /opt/tljh/user/share/jupyter/nbextensions/mstr_jupyter
MicroStrategy.yaml  cells-creation.js  iframe_style.css  main.js  
mstr-connector  mstr.ico  override_style.css  package-lock.json  python-code.js  utilities.js

When I run the extension in the Notebook however, only the main.js file is exposed on the server. Fetching others results in 404 error making the extension unusable.

Expected behaviour

All files are exposed on the server as it's in the case of the "desktop version" of Jupyter Notebook image

Actual behaviour

Only the main.js file is exposed on the server making the extension unusable. image

How to reproduce

  1. Install mstrio-py
sudo -E pip install mstrio-py
  1. Enable the extension
sudo -E jupyter nbextension install connector-jupyter --py --sys-prefix
sudo -E jupyter nbextension enable connector-jupyter --py --sys-prefix
  1. Run the Notebook
  2. Open browser's Developer Tools
  3. Go to Sources tab
  4. In the left panel navigate to nbextensions/mstr_jupyter directory
  5. Observe that only main.js file is there.

Your personal set up

  • OS: Ubuntu 20.04 LTS
  • Version: How do I actually check which version of TLJH do I have?
admin@tec-l-011630:~$ sudo jupyterhub --version
sudo: jupyterhub: command not found
  • Configuration:
admin@tec-l-011630:~$ sudo tljh-config show
users:
  admin:
  - admin

drzamich avatar Jun 16 '20 09:06 drzamich

Thank you @drzamich for a beautifully written issue! I think this is a symptom of something that has been observed in other context as well, but I'm not sure what is going on.

Maybe related

  • #418
  • #510
  • #585

consideRatio avatar Oct 25 '21 21:10 consideRatio