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

Code editor settings can only be enabled, not disabled in Notebook #15246

Open
krassowski opened this issue Oct 10, 2023 · 3 comments
Open

Code editor settings can only be enabled, not disabled in Notebook #15246

krassowski opened this issue Oct 10, 2023 · 3 comments
Labels
bug pkg:codemirror pkg:notebook tag:Regression Behavior that had been broken, was fixed, and is broken again
Milestone

Comments

@krassowski
Copy link
Member

Description

Checking a setting like Auto Closing Brackets, Highlight the active line, Highlight white spaces and others in notebook enables it but unchecking does not disable it afterwards.

Reproduce

  1. Open a notebook and Settings → Notebook
  2. Enable Highlight the active line
  3. Click on the cell, see active line highlighted
  4. Disable Highlight the active line
  5. Click on the same cell, see active line remains hihglighted
  6. Create a new cell, see that the settings are ok in newly created cells

many-settings-do-not-deactivate

Expected behavior

Settings get reflected in the existing cells

Context

  • Browser and version: Chrome
  • JupyterLab version: 4.0.6 and 4.1.0a1
@krassowski krassowski added bug pkg:notebook pkg:codemirror status:Needs Triage Applied to new issues that need triage tag:Regression Behavior that had been broken, was fixed, and is broken again labels Oct 10, 2023
@krassowski krassowski added this to the 4.0.x milestone Oct 10, 2023
@JasonWeill
Copy link
Contributor

Does the "disabled" setting show up as enabled in the settings editor after you reload your JupyterLab session?

@krassowski
Copy link
Member Author

Yes. The issue is that existing cells do not ever get extensions de-registered, not that the settings system is not saving. I had included step 6. Create a new cell, see that the settings are ok in newly created cells to hint at it.

@firai
Copy link
Contributor

firai commented Oct 15, 2023

I'm not sure if it's the same issue, but I'm noticing that changes to CodeMirror settings only update CM instances when the new value is different from the default. When they are changed back to the default value, the behavior sticks to the previous value. You can see this by changing the cursor blinking rate in the notebook settings. I'm also experiencing this with settings for a new CM extension as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug pkg:codemirror pkg:notebook tag:Regression Behavior that had been broken, was fixed, and is broken again
Projects
None yet
Development

No branches or pull requests

3 participants