Richard, could you specify which version you are using of Windows, Python and IPython? Do you get the exact same problem described above? I do not see this problem on my system, using the Enthough Python Distribution (EPD) with Python 2.5.2 and IPython 0.9.1 under Windows XP SP3.
Example: I put the following in c:\temp\temp.py
x = 2 + 2
y = 3 + 3
Then start IPython (with the "Pylab" shortcut installed with EPD).
In [3]: run -d temp.py
Breakpoint 1 at c:\temp\temp.py:1
NOTE: Enter 'c' at the ipdb> prompt to start your script.
> <string>(1)<module>()
ipdb> s
--Call--
> c:\temp\temp.py(1)<module>()
0 y = 3 + 3
ipdb> n
...and this works fine.
However, the pydb solution also worked. I had already installed Mingw and Msys (www.mingw.org), downloaded the pydb tar.gz file, extracted it to c:\msys\1.0\home\jonvi, started msys, navigated to the pydb installation directory, and ran
$ ./configure
$ make
$ make install
I discovered that the HOME environment variable needed to be set before pydb would work (otherwise, I got KeyError: HOME). Fhe Windows command line (Start menu > Run > cmd), I did:
set HOME=c:\msys\1.0\home\jonvi
(you'll need to adjust this to your system).
Then, running
C:\Python25\Scripts\ipython.exe -pydb
worked fine:
In [3]: cd c:\temp
c:\temp
In [4]: run -d temp.py
No stack.
NOTE: Enter 'c' at the ipydb> prompt to start your script.
(<string>:1): <module>
ipydb> s
----------------Call level 7 > c:\temp\temp.py(1)<module>()
0 y = 3 + 3
(c:\temp\temp.py:1): <module>
1 x = 2 + 2
ipydb> n
(c:\temp\temp.py:1): <module>
1 x = 2 + 2
ipydb>
(c:\temp\temp.py:2): <module>
2 y = 3 + 3
ipydb>
----------------Return from level 7 (<type 'NoneType'>)
--------------Return from level 6 (<type 'NoneType'>)
Richard, could you specify which version you are using of Windows, Python and IPython? Do you get the exact same problem described above? I do not see this problem on my system, using the Enthough Python Distribution (EPD) with Python 2.5.2 and IPython 0.9.1 under Windows XP SP3.
Example: I put the following in c:\temp\temp.py
x = 2 + 2
y = 3 + 3
Then start IPython (with the "Pylab" shortcut installed with EPD). (1)<module> () temp.py( 1)<module> ()
In [3]: run -d temp.py
Breakpoint 1 at c:\temp\temp.py:1
NOTE: Enter 'c' at the ipdb> prompt to start your script.
> <string>
ipdb> s
--Call--
> c:\temp\
0 y = 3 + 3
ipdb> n
...and this works fine.
However, the pydb solution also worked. I had already installed Mingw and Msys (www.mingw.org), downloaded the pydb tar.gz file, extracted it to c:\msys\ 1.0\home\ jonvi, started msys, navigated to the pydb installation directory, and ran
$ ./configure
$ make
$ make install
I discovered that the HOME environment variable needed to be set before pydb would work (otherwise, I got KeyError: HOME). Fhe Windows command line (Start menu > Run > cmd), I did: \msys\1. 0\home\ jonvi
set HOME=c:
(you'll need to adjust this to your system).
Then, running Scripts\ ipython. exe -pydb ------- --Call level 7 > c:\temp\ temp.py( 1)<module> () temp.py: 1): <module> temp.py: 1): <module> temp.py: 2): <module> ------- --Return from level 7 (<type 'NoneType'>) ------- Return from level 6 (<type 'NoneType'>)
C:\Python25\
worked fine:
In [3]: cd c:\temp
c:\temp
In [4]: run -d temp.py
No stack.
NOTE: Enter 'c' at the ipydb> prompt to start your script.
(<string>:1): <module>
ipydb> s
-------
0 y = 3 + 3
(c:\temp\
1 x = 2 + 2
ipydb> n
(c:\temp\
1 x = 2 + 2
ipydb>
(c:\temp\
2 y = 3 + 3
ipydb>
-------
-------
Hope this helps,
Jon Olav