Skip to main content

All Questions

Tagged with
1 vote
0 answers
64 views

ipdb *** SyntaxError: multiple statements found while compiling a single statement

When using ipython debugger (ipdb), sometimes I just want to paste something in the debugger to see if it works. This works for single line stuff and loops but if I paste something more that one line, ...
curious's user avatar
  • 730
0 votes
0 answers
199 views

Enter Python debugger on an exception ignored by a library

I have introduced a bug in some complicated code which is noisily swallowed by some library code I don't want to learn about: In [212]: start = time() ; result = big_messy_thing() ; stop = time() ; ...
rob's user avatar
  • 393
2 votes
2 answers
809 views

PyCharm: Use python console for debugging [duplicate]

I just wanted to know if there is a way in PyCharm to use the debug console as an "all-rounder". I.e. try out commands, create variables and debug Python scripts so that the debug console ...
a-python-script's user avatar
0 votes
0 answers
245 views

Issue with List Expressions or Debugger: NameError: name is not defined

I am using the following code to figure out if an Edge definition is existing already and either get a NameError or a False where should be a True. The code is the following: @staticmethod def ...
Qohelet's user avatar
  • 1,634
3 votes
2 answers
3k views

How can I debug a dieing jupyter notebook ipython kernel?

When running my jupyter notebooks, the ipython kernel (Python 3.8, Anaconda) keeps dieing and being restarted. I want to find what causes it to misbehave. Sadly, I can find no debugging information ...
abukaj's user avatar
  • 2,712
4 votes
1 answer
397 views

How to change IPython %pdb and %debug debugger?

By default, ipython uses ipdb as debugger with %pdb or %debug magics. However, I much prefer pdb++... Is there a way of changing the debugger called with these magics ? (I am aware I can simply use ...
hl037_'s user avatar
  • 3,907
2 votes
1 answer
795 views

Using IPython with breakpoint()

How to do a set up that when I call breakpoint(), IPython shell is invoked instead pdb? Currently, Python uses pdb, which has no completion.
kolypto's user avatar
  • 35.7k
1 vote
1 answer
457 views

Break when variable is a certain value when debugging with IPython?

Can I ask IPython to break when it encounters a variable at a specific value? myloop.py for myvar in range(1, 10): print("myvar: {}".format(myvar)) this does not work, but I envision something ...
Stuber's user avatar
  • 477
1 vote
1 answer
1k views

Why does import pdb; pdb.set_trace trigger two different debugging scenarios when called differently in Spyder?

This is a follow-up question to Stepwise debugging of selected Python code. Why does import pdb; pdb.set_trace trigger two different debugging scenarios when called differently in Spyder? Here's the ...
vestland's user avatar
  • 61.5k
0 votes
1 answer
955 views

PyCharm + IPython debug in external terminal

I am wondering is it possible to attach process of debugging in PyCharm IDE to external IPython terminal. Here is a picture which would describe this scenario: Here are steps how I would like to ...
noctreik's user avatar
1 vote
0 answers
198 views

debugging ipyparallel applications

Thinking of using ipyparallel to develop a machine learning algorithm on a cluster, mainly using pandas, scikit-learn and numpy. What are the recommended debugging techniques. Is it possible to ...
Emre Tezel's user avatar
1 vote
1 answer
2k views

Ipython console not returning output of summary()

so i am trying a multiple linear regression model,when i call for the command to see the summary of the model.Using this command. #backward elimination x_opt=x[:,[0,1,2,3,4,5]] reg_ols=sm.OLS(endog=...
danishxr's user avatar
4 votes
1 answer
770 views

IPython-style ipdb debugging in Jupyter notebook?

To debug in Jupyter notebook, I use: from IPython.core.debugger import set_trace; set_trace() However, it only shows a command input box with no support for command history, autocomplete, or color... ...
THN's user avatar
  • 3,631
1 vote
1 answer
800 views

IPython embed breakpoint - How can I see the code around the breakpoint?

Say I've got some python code with an embed breakpoint like so: from IPython import embed def my_func(self): some_var = 'awesome sauce' embed() # other stuff happens when I run my test runner.....
daino3's user avatar
  • 4,566
5 votes
0 answers
604 views

Issue Debugging Jupyter Notebook Using ipdb & Tracer

I have been running into issues when using the debugger within Jupyter Notebook, Specifically this command: from IPython.core.debugger import Tracer Tracer()() #this one triggers the debugger ...
joshf's user avatar
  • 251

15 30 50 per page
1
2 3 4 5