Iron Python Tools and Code Model

Sep 4, 2011 at 1:47 PM

I'd like to have DPack (www.usysware.com/dpack/) support Iron Python Tools *if* it were to implement DTE code model. It doesn't seem to support that at the moment but I'd love to see that implemented in the future. Please consider this a feature request. Thanks.

Coordinator
Sep 8, 2011 at 4:48 AM

Thanks for the suggestion - I've opened this feature request: http://pytools.codeplex.com/workitem/510, feel free to vote it up.

I don't think this is an immediate priority for us right now simply because we don't get much feature wise from it.  OTOH this has largely been implemented for Python once already (I should know, I wrote it) in the VS SDK IronPython integration sample.  That could potentailly be ported forward but there may be some significant differences as that's using IronPython 1.x.  But if someone were to port this forward and contribute it we'd likely accept it.

Sep 9, 2011 at 4:25 AM

If the code model were implemented, would that give sensible breakpoint support (i.e. don't allow breakpoints on non-code lines) and autos window support?

From my brief glance at it, that's would it looked like those features would require to be implemented.

Coordinator
Sep 9, 2011 at 4:35 AM

Implementing VS's code model isn't necessary for those features - instead we can just go straight to the Python parser w/o an extra layer. 

For both of them the debugger would just need to open the source files, run the parser on them, and then provide VS w/ the appropriate info.  For breakpoints that's delivering an event on whether or not the breakpoint failed or succeeded - something we already do (at least for success).  For the autos I think it's a request to the stack frame object. 

We already use the parser to get the exception handling information so all 3 of these should probably be tied together as far as parsing goes.

There could be some tricky cases for validating breakpoints as CPython at least doesn't deliver line events for multiple pass statements in a row, I'm not sure how many other odd corner cases there would be.