1
Vote

Can't set breakpoints in python files

description

I have a C# program that executes IronPython python scripts using Microsoft.Scripting. With an older version of Python Tools for VS 2012 I was able to attach to my program in Visual Studio and break on a line in an IronPython file. I am no longer able to do so. I have verified that the python script does get executed.

I am currently running VS 2013 with IronPython 2.74 and Python tools for Visual Studio 2013 (2.0.11016.0). It doesn't work for this configuration either.

comments

JohnMajerle wrote Jun 4 at 10:11 PM

Shortly after filing this issue I found my mistake. I had inadvertently commented out the last 4 lines in the code snippet below that enable debugging:
                var setup = ScriptRuntimeSetup.ReadConfiguration();
                setup.HostType = typeof(DlrScriptHost);
                setup.HostArguments = new object[] { "DlrScriptHostInit.py" };  

                setup.DebugMode = true;
                setup.Options.Add("Debug", true);
                setup.Options["Frames"] = true;
                setup.Options["FullFrames"] = true;