0

When I write Python code in a Jupyter Lab cell, often a small window pops up automatically like shown in the screenshot below. When I press enter, it prepends "abs" to "array", so that instead of creating a line break, I get np.absarray([]). As you can imagine, it is a real pain to wait one second for the window to pop up, press Esc, and then insert a linebreak.

enter image description here

I initially thought that this was the "code completion" feature. In the Jupyter Lab settings, under "Code Completion", I set "kernelResponseTimeout": 0, which should disable kernel completion. Unfortunately, this did not change anything. Also, as far as I understood the code completion window should only pop up when I press Tab, which I don't do; it comes up automatically.

My question is therefore: what is this annoying "feature" and how do I get rid of it?

MPA
  • 1,878
  • 2
  • 26
  • 51
  • What version of JupyterLab are you using? Mine isn't quite looking like yours, unless I haven't triggered exactly what you are activating. It automatically comes up or you have to press tab? – Wayne Mar 11 '22 at 18:27
  • @Wayne I have version 3.0.14. It comes up automatically after some delay (less than 1 second), but not systematically – MPA Mar 12 '22 at 08:46
  • That version is [nearly a year old now](https://github.com/jupyterlab/jupyterlab/releases/tag/v3.0.14). JupyterLab is still in a phase where the development is very active & so it's best to update your version and see if that improves your experience. Conda and pip both offer version 3.3.1 at this time. – Wayne Mar 13 '22 at 18:44
  • @Wayne I updated to version 3.3.1, but the problem persists – MPA Mar 13 '22 at 19:43
  • 1
    @Wayne I just noticed that version 3.3.1 has a "Disable" option under "Code completion" that seems to correctly disable this feature. This solves my problem – MPA Mar 13 '22 at 19:46
  • In a certain sense this is a duplicate of https://stackoverflow.com/questions/67669843/jupyterlab-3-0-14-how-to-disable-code-style-highlights-pycodestyle/67671347#67671347. This is not a built-in feature of JupyterLab, this is an extension, [jupyterlab-lsp](https://github.com/jupyter-lsp/jupyterlab-lsp) which you must have installed (or someone else installed it for you). As noted, disabling is possible from settings is possible, but what you describe looks like an error. Would you mind reporting it on GitHub: https://github.com/jupyter-lsp/jupyterlab-lsp, please? – krassowski Mar 14 '22 at 15:25
  • @krassowski thanks for the clarification. I will investigate a bit further and report the issue (when I have time) – MPA Mar 14 '22 at 16:15

0 Answers0