question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Spyder 5.1.5 debugging does not work in new environnements (Anaconda3-2021.11-Windows-x86_64.exe)

See original GitHub issue

Hello, First thanks for the excellent work of the contributors!

Anaconda3-2021.11-Windows-x86_64.exe Windows 10

In the context of specific development, after reinstallation of anaconda, I am facing a problem with spyder that I reproduce here in a simpler situation.

I have installed anaconda from Anaconda3-2021.11-Windows-x86_64.exe on Windows 10. The base environment has spyder 5.1.5 installed. I have written a few line script importing numpy (1.20.3) and matplotlib (3.4.3), with a breakpoint (at “x=”).

import numpy as np
import matplotlib.pyplot as plt
if __name__ == '__main__':
	x=np.linspace(1,10,10)
	plt.hist(x**2)

The script runs, debugging works fine. Same after conda update --all.

I create an environment either from the Navigator or by hand from a conda shell (conda env create –n test_from_shell, that then appears in the Navigator).

In both created environments I install spyder (conda install spyder, and spyder 5.1.5 gets installed, like in the base), numpy (1.21.5) and matplotlib (3.5.0), not the same version. spyder-kernels version is 2.1.3 in all cases, ipykernel versions are the same.

In the created environment the script runs correctly, but the debugging does not work, i.e. it starts, does not stop at nor reach the breakpoint and cannot be interrupted. The symptoms are the same as in issue #17314, and the steps are similar to the ones described in the attached pdf of that issue (C__Users_jandre_Desktop_Problem_20220208_1900.pdf

I have cloned the base environment through a yaml file and I have checked that in the cloned environment the script and the debugging run fine.

  1. What is/are the guilty module(s) in the test environments leading to the debugger bug ? How can I find it ? How can this be solved?

  2. Could you explain what are the default scripts installed when a new environment is created and why it is not the ones found in the base environment ? Is that expected ?

Thanks a lot

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:13 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
kikazahncommented, Feb 16, 2022

This worked for me. To avoid conflicts I had to do conda uninstall spyder spyder-kernels in my old environment Also install spyder-kernels from conda-forge: conda install spyder-kernels -c conda-forge Otherwise spyder-kernels 2.2.0 will be installed and they are incompatible with spyder 5.2.2

1reaction
Davo36commented, Jun 12, 2022

@ccordoba12 Yes I just installed the stand alone version, I’m using Windows. It works fine. Thanks.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spyder Debugger hangs (not debugging) - Stack Overflow
If you are not using Anaconda, you can update Spyder with the following command pip install -U spyder. If not, please close Spyder,...
Read more >
Getting the Debugger to work (5.1.5) - Google Groups
Hi everyone, I'm a new user on a Windows 10 machine, using Anaconda. ... When I first encountered this problem Anaconda had installed...
Read more >
Product Help - Anaconda Community
I have been using Spyder 4.2 for roughly a year without issue. Upon opening and coding for roughly 15 ... Spyder 5.1.5/Spyder 4.2...
Read more >
Debugger — Spyder 5 documentation
Spyder's debugger offers syntax highlighting, code completion and command history, which work exactly like they do in the normal interactive interpreter.
Read more >
Python LSP never starts so debugging won't work. (Spyder)
No issues, install seemed to go successfully. Pro 3.0. Python 3.9.11. Spyder 5.1.5. Windows Server 2012. Thanks for any tips,.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found