Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Error listing extensions when plotly >=6.1.2 installed #5211

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

Open
achhina opened this issue May 30, 2025 · 1 comment
Open

Error listing extensions when plotly >=6.1.2 installed #5211

achhina opened this issue May 30, 2025 · 1 comment

Comments

@achhina
Copy link

achhina commented May 30, 2025

Hey folks, after installing the most recent release I'm seeing the following error when attempting to list extensions:

KeyError: 'packageManager'  not found inside install.json
$ jupyter labextension list --debug
Searching ['/Users/achhina/venvs/plotly-test/etc/jupyter', '/Users/achhina/.config/jupyter', '/usr/local/etc/jupyter', '/etc/jupyter'] for config files
Looking for jupyter_config in /etc/jupyter
Looking for jupyter_config in /usr/local/etc/jupyter
Looking for jupyter_config in /Users/achhina/.config/jupyter
Looking for jupyter_config in /Users/achhina/venvs/plotly-test/etc/jupyter
Looking for lab_config in /etc/jupyter
Looking for lab_config in /usr/local/etc/jupyter
Looking for lab_config in /Users/achhina/.config/jupyter
Looking for lab_config in /Users/achhina/venvs/plotly-test/etc/jupyter
Yarn configuration loaded.
JupyterLab v4.4.3
/Users/achhina/venvs/plotly-test/share/jupyter/labextensions
        jupyterlab_pygments v0.3.0 enabled OK (python, jupyterlab_pygments)
Traceback (most recent call last):

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/debuglog.py", line 45, in debug_logging
    yield

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/labextensions.py", line 169, in start
    ans = self.run_task()

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/labextensions.py", line 425, in run_task
    list_extensions(
    ~~~~~~~~~~~~~~~^
        app_options=AppOptions(
        ^^^^^^^^^^^^^^^^^^^^^^^
    ...<5 lines>...
        )
        ^
    )
    ^

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/commands.py", line 580, in list_extensions
    return handler.list_extensions()
           ~~~~~~~~~~~~~~~~~~~~~~~^^

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/commands.py", line 788, in list_extensions
    self._list_federated_extensions()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^

  File "/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/commands.py", line 1759, in _list_federated_extensions
    extra += " ({}, {})".format(install["packageManager"], install["packageName"])
                                ~~~~~~~^^^^^^^^^^^^^^^^^^

KeyError: 'packageManager'

/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/debuglog.py:54: UserWarning: An error occurred.
  warnings.warn("An error occurred.")
/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/debuglog.py:55: UserWarning: KeyError: 'packageManager'
  warnings.warn(msg[-1].strip())
/Users/achhina/venvs/plotly-test/lib/python3.13/site-packages/jupyterlab/debuglog.py:56: UserWarning: See the log file for details: /var/folders/7d/6v1f4d011x7b9v6tbvw4x6480000gn/T/jupyterlab-debug-xcr2tdtu.log
  warnings.warn(f"See the log file for details: {log_path!s}")
Exiting application: lab

Looks to be related to the changes in #5096, and potentially mixing of source extensions with federated ones?

@hguturu
Copy link

hguturu commented Jun 3, 2025

I also have this issue with jupyterlab==4.2.5. For me, it appears to be happening on all 6.1.x versions. Dropping to 6.0.1 resolved the issue.

The contents of my jupyter/labextensions/jupyterlab-plotly/install.json when I have 6.1.2 installed (note the incorrect version also).

{
    "schemaVersion": 1,
    "name": "jupyterlab-plotly",
    "version": "6.0.1",
    "jupyterlab": {
      "mimeExtension": "lib/mimeExtension.js"
    }
}

Oddly enough this file is missing when 6.0.1 is installed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants