[IronPython] Debugging in VS Expermental Hive

Dino Viehland dinov at microsoft.com
Tue Oct 28 17:22:08 CET 2008

Currently you can't see module globals in the debugger but we are working on improving the VS experience.  You should be able to see locals that are defined in a function though today.

From: users-bounces at lists.ironpython.com [mailto:users-bounces at lists.ironpython.com] On Behalf Of mikhail.osadnik at realtimeworlds.com
Sent: Tuesday, October 28, 2008 7:40 AM
To: users at lists.ironpython.com
Subject: [IronPython] Debugging in VS Expermental Hive


  A was hoping to get any help on ironpython scripts debugging under Visual Studio 2008 Experimental Hive. The problem is it appears impossible to watch variables in VS IDE .NET debugger apart from the line number ($line) which is somewhat redundant. The setup code is as follows:

        ScriptRuntime Runtime = ScriptRuntime.Create ();
Runtime.GlobalOptions.DebugMode = true;
Runtime.ExecuteFile ( PyFile );

        import System.Diagnostics
        System.Diagnostics.Debugger.Break ()
somevar = 'some string'
print somevar

  So when a breakpoint fires I can go through the IronPython script feeded to ExecuteFile in VS IDE with the debugger. However it appears that plain script's variables in the watch window cannot be resolved. I'd hoped to examine the scope of a script but it turned out that the scope is available only after the ExecuteFile call is done.
  So the question is - could it be possible to access scope's variables while debugging with VS IDE debugger?

IronPython's version I am using is


Mikhail Osadnik, Senior Software Engineer
Realtime Worlds Ltd


This message and any attachments contain privileged and confidential information intended for the use of the addressee named above. If you are not the intended recipient of this message, you are hereby notified that any use, dissemination, distribution or reproduction of this message is prohibited. Please note that we cannot guarantee that this message or any attachment is virus free or that it has not been intercepted and amended. The views of the author may not necessarily reflect those of Realtime Worlds Ltd.

Realtime Worlds Ltd is registered in Scotland, number 225628. Registered Office: 152 West Marketgait, Dundee, DD1 1NJ.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20081028/cbcf17a7/attachment.html>

More information about the Ironpython-users mailing list