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

Bad UX when disabling a server extension with a misspelled or non-existent name #1507

Open
Darshan808 opened this issue Mar 24, 2025 · 1 comment
Labels

Comments

@Darshan808
Copy link
Contributor

Original Issue:

This issue was initially reported in JupyterLab repository jupyterlab/jupyterlab#17422 , where a similar behavior occurs when disabling a frontend extension with a misspelled name.

Description

When attempting to disable a Jupyter Server extension with a misspelled or non-existent name using:

  • jupyter server extension disable <extension_spelled_wrong>

Even if the extension is not present, the command does not show an error but instead lists the wrongly spelled extension as disabled. Later, when trying to enable the extension and running jupyter server extension list, a cross mark appears, indicating that the extension is not present.

Reproduce

  1. Disable an extension with a misspelling, such as:
jupyter labextension disable jupyter-server-nbmodel  # (should be jupyter_server_nbmodel)
  1. The command incorrectly lists jupyter-server-nbmodel as disabled, even though it's not valid. Run jupyter server extension list to see
 jupyter-server-nbmodel disabled
    - Validating jupyter-server-nbmodel...
      jupyter-server-nbmodel  OK
  1. After running jupyter server extension enable jupyter-server-nbmodel, it shows a cross mark, indicating the extension isn't present.
jupyter-server-nbmodel enabled
    - Validating jupyter-server-nbmodel...
       X The module 'jupyter-server-nbmodel' could not be found (No module named 'jupyter-server-nbmodel'). Are you sure the extension is installed?

Expected behavior

When the extension is misspelled (i.e., not present), a message should be shown, such as:

No extension named 'jupyter-server-nbmodel' found.

Context

  • Operating System and version: Linux Ubuntu 24.04 LTS
  • Jupyter_server version : 2.15.0
@Darshan808 Darshan808 added the bug label Mar 24, 2025
@Zsailer
Copy link
Member

Zsailer commented Apr 2, 2025

Yes, you're right @Darshan808. This is, indeed, some bad UX 😅.

I think I originally authored this CLI, so I can fully admit there are gaps—it's never been a major priority; more of a minimal viable solution.

If you're interested in improving this, I'd be happy to review PRs. Feel free to request me on any and I'm happy to help.

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