Issue
I know this question has been asked previously, but the questions I have found were asked several years ago and so I suspect Spyder has undergone updates in this period.
Is it possible yet to view the call-stack for recursive programs in Spyder (for python) as it is in VS Code, for example?
If so, please can someone guide me as to how this is done
Thank you
Solution
Yes you can do it thanks to python debugger (pbd) inside Spyder. At least this works from Spyder 2.7 but maybe earlier. In Spyder (checked for Spyder 2.7; and Spyder 3.3.3. with Python 3.6.8., 64bits, PyQt5 5.12, Windows 7) you can use ipbd in debugging mode in the ipython console. There are 3 commands to navigate in the stack:
w(here): it returns the call stack on iPython console with all levels
u(p): it goes one level up in the stack debugging, and updates the variables explorer, so you see now only the variables that apply to that stack level. It also updates the arrow debug pointer in the script editor.
d(own): the same than "up" but down
Answered By - José Crespo Barrios
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.