intellisense works but variable hover inspection does not

Aug 22, 2012 at 2:31 PM

Just installed IronPython and PTVS. I have a simple python app that accesses a C# dll. I had to add the C# dll path to the 'search path' options box before intellisense would work.

Intellisense works fine, I get the member methods for the C# stuff no problem.

BUT when I hit a breakpoint in the python app, say on a line of code x = 42, any variable that I hover over or add to a watch window says "the name 'x' does not exist in current context".

Arggh...

Coordinator
Aug 22, 2012 at 4:31 PM

This is probably because you are using the .NET debugger.

IronPython can be debugged in two ways. You can use the .NET debugger, which supports stepping into other managed code such as C#, but loses some Python-specific information that makes debugging Python code not as nice. Alternatively, you can use the pure Python debugger, which will be much better for Python code but will step over all non-Python code. Unfortunately, we don't support mixed-mode debugging with the Python debugger, so using the .NET debugger may be best for you.

To switch between them, open Project Properties, select the Debug tab and choose a different launcher. At the moment, you probably have "IronPython (.NET) launcher" selected, since this is the default. "Standard Python launcher" will use the pure Python debugger. (If this is already selected then you've found a bug, so we'll be interested in more details about your app.)

Aug 22, 2012 at 10:46 PM

Alas, you are correct! I would have sworn I'd tried this option. Guess the brain isn't turned on completely today.

 

Thanks !

 

- John