using ipdb to debug python code in one cell (jupyter or Ipython)
<p>I'm using jupyter (or Ipython) notebook with firefox, and want to debug some python code in the cell. I am using 'import ipdb; ipdb.set_trace()' as kind of breakpoint, for example my cell has the following code: </p>

<pre><code>a=4
import ipdb; ipdb.set_trace()
b=5
print a
print b
</code></pre>

<p>which after execution with Shift+Enter gives me this error:</p>

<pre><code>--------------------------------------------------------------------------
MultipleInstanceError                     Traceback (most recent call last)
&lt;ipython-input-1-f2b356251c56&gt; in &lt;module&gt;()
      1 a=4
----&gt; 2 import ipdb; ipdb.set_trace()
      3 b=5
      4 print a
      5 print b

/home/nnn/anaconda/lib/python2.7/site-packages/ipdb/__init__.py in &lt;module&gt;()
     14 # You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
     15 
---&gt; 16 from ipdb.__main__ import set_trace, post_mortem, pm, run, runcall, runeval, launch_ipdb_on_exception
     17 
     18 pm                       # please pyflakes

/home/nnn/anaconda/lib/python2.7/site-packages/ipdb/__main__.py in &lt;module&gt;()
     71         # the instance method will create a new one without loading the config.
     72         # i.e: if we are in an embed instance we do not want to load the config.
---&gt; 73         ipapp = TerminalIPythonApp.instance()
     74         shell = get_ipython()
     75         def_colors = shell.colors

/home/nnn/anaconda/lib/python2.7/site-packages/traitlets/config/configurable.pyc in instance(cls, *args, **kwargs)
    413             raise MultipleInstanceError(
    414                 'Multiple incompatible subclass instances of '
--&gt; 415                 '%s are being created.' % cls.__name__
    416             )
    417 

MultipleInstanceError: Multiple incompatible subclass instances of TerminalIPythonApp are being created.
</code></pre>

<p>The same error appears if I use this code not in the jupyter notebook in the browser, but in jupyter qtconsole. 
What does this error mean and what to do to avoid it? 
Is it possible to debug code in the cell step-by-step, using next, continue, etc commands of pdb debugger?</p>