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

Shift+Enter fails to execute cells #477

Open
TSAstron opened this issue Oct 30, 2024 · 6 comments
Open

Shift+Enter fails to execute cells #477

TSAstron opened this issue Oct 30, 2024 · 6 comments

Comments

@TSAstron
Copy link

Description

What steps will reproduce the problem?

In a jupyter notebook, selecting any cell (but not entering edit mode), holding shift and pressing enter does nothing.
The cell is executed normally when that combination is pressed from edit mode.

Versions

  • Spyder version: 5.5.1 (pip)
  • Python version: 3.10.12 64-bit
  • Qt version: 5.15.2
  • PyQt5 version: 5.15.9
  • Operating System: Linux-5.19.0-1010-nvidia-lowlatency-x86_64-with-glibc2.35

Dependencies

# Mandatory:
atomicwrites >=1.2.0                 :  1.4.1 (OK)
chardet >=2.0.0                      :  5.2.0 (OK)
cloudpickle >=0.5.0                  :  2.2.1 (OK)
cookiecutter >=1.6.0                 :  2.3.0 (OK)
diff_match_patch >=20181111          :  20230430 (OK)
intervaltree >=3.0.2                 :  3.1.0 (OK)
IPython >=8.13.0,<9.0.0,!=8.17.1     :  8.14.0 (OK)
jedi >=0.17.2,<0.20.0                :  0.18.2 (OK)
jellyfish >=0.7                      :  1.0.0 (OK)
jsonschema >=3.2.0                   :  4.18.6 (OK)
keyring >=17.0.0                     :  24.2.0 (OK)
nbconvert >=4.0                      :  7.7.3 (OK)
numpydoc >=0.6.0                     :  1.2 (OK)
parso >=0.7.0,<0.9.0                 :  0.8.3 (OK)
pexpect >=4.4.0                      :  4.8.0 (OK)
pickleshare >=0.4                    :  0.7.5 (OK)
psutil >=5.3                         :  5.9.5 (OK)
pygments >=2.0                       :  2.15.1 (OK)
pylint >=2.5.0,<3.1                  :  2.17.5 (OK)
pylint_venv >=3.0.2                  :  3.0.2 (OK)
pyls_spyder >=0.4.0                  :  0.4.0 (OK)
pylsp >=1.10.0,<1.11.0               :  1.10.0 (OK)
pylsp_black >=2.0.0,<3.0.0           :  2.0.0 (OK)
qdarkstyle >=3.2.0,<3.3.0            :  3.2.3 (OK)
qstylizer >=0.2.2                    :  0.2.2 (OK)
qtawesome >=1.2.1                    :  1.2.3 (OK)
qtconsole >=5.5.1,<5.6.0             :  5.5.1 (OK)
qtpy >=2.1.0                         :  2.4.1 (OK)
rtree >=0.9.7                        :  1.0.1 (OK)
setuptools >=49.6.0                  :  68.0.0 (OK)
sphinx >=0.6.6                       :  7.1.2 (OK)
spyder_kernels >=2.5.0,<2.6.0        :  2.5.0 (OK)
textdistance >=4.2.0                 :  4.5.0 (OK)
three_merge >=0.1.1                  :  0.1.1 (OK)
watchdog >=0.10.3                    :  3.0.0 (OK)
xdg >=0.26                           :  0.28 (OK)
zmq >=22.1.0                         :  25.1.0 (OK)

# Optional:
cython >=0.21                        :  0.29.28 (OK)
matplotlib >=3.0.0                   :  3.7.2 (OK)
numpy >=1.7                          :  1.24.4 (OK)
pandas >=1.1.1                       :  2.0.2 (OK)
scipy >=0.17.0                       :  1.12.0 (OK)
sympy >=0.7.3                        :  1.9 (OK)

# Spyder plugins:
spyder_notebook.notebookplugin 0.5.1 :  0.5.1 (OK)
@ccordoba12
Copy link
Member

Hey @TSAstron, thanks for reporting. I have a quick question for you: is this a problem you're experiencing in Spyder-notebook? Or in Spyder?

@TSAstron
Copy link
Author

TSAstron commented Nov 1, 2024

Hey @TSAstron, thanks for reporting. I have a quick question for you: is this a problem you're experiencing in Spyder-notebook? Or in Spyder?

The application I launch is Spyder itself, but I do have the spyder-notebook installed in order to open the jupyter (.ipynb) files. I'm guessing Spyder runs/uses spyder-notebook as one of its panes.

The problem is not with cells in ordinary python scripts, but with enhanced cells of jupyter notebooks. As you see on the screenshot, the cell is selected, but the cursor is not blinking inside - this is when shift+enter does not work.
Screenshot from 2024-11-02 00-12-49

@ccordoba12
Copy link
Member

Ok, I see, thanks for the clarification. I'm going to move this issue to the Spyder-notebook repository then because it's a bug with that plugin.

But I don't when it's maintainer will have time to take a look at it, sorry.

@ccordoba12 ccordoba12 removed their assignment Nov 2, 2024
@ccordoba12 ccordoba12 transferred this issue from spyder-ide/spyder Nov 2, 2024
@jitseniesen
Copy link
Member

Hi @TSAstron , I tried to reproduce this bug but I did not manage, neither with the latest version of Spyder nor with the version 5.5.1 that you are using. However, I have seen several reports of all kinds of issues when people use pip to install the spyder-notebook plugin. Whenever I try to use pip with spyder-notebook, it does not work well for me, but I have never had the time and energy to find out where the problem lies (I suspect it has to do with the packaging of Qt WebEngine). So my suggestion would be to install everything with conda instead of pip.

@TSAstron
Copy link
Author

TSAstron commented Nov 3, 2024

Hi @jitseniesen , it's good to know there's at least some workaround, but conda is unfortunately not an option for me. I remember that the cell execution worked fine in an earlier version (4?) with pip installation, but that was quite some time ago (over a year). I haven't been using spyder since then, and recently decided to compare it with VS Code and jupyterlab again.
So are you saying this will have to wait for some developer to find time, or is pip an officially deprecated method of instillation, and there is no hope?

@jitseniesen
Copy link
Member

Pip is not deprecated. We know that using conda is impossible or very difficult for some users. For Spyder itself, pip is viable but needs some experience and we don't provide individual support. As developers we are concentrating on conda because that is the mechanism that we use for the Spyder installer and because conda works better with compiled libraries such as numpy and Qt (though pip is catching up in this aspect). The notebook integration in Spyder is still experimental, which means it has rough edges, one of them is that pip installations do not work well. I do want this to be fixed but I don't expect that I'll be able to find time to fix it myself any time soon.

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

3 participants