This project has moved. For the latest updates, please go here.

Run w/o Resetting execution engine

Apr 15, 2012 at 3:15 AM
Edited Apr 15, 2012 at 2:28 PM

Is there any way to "Execute File in Python Interactive" without first resetting the execution engine?

Our workflow has a lot of live data in the Interactive interpreter namespace that we use various scripts to work with on the fly. The fact that executing the scripts resets and clears all the active objects  makes PTVS incompatible with our workflow.

I found that I can select all, right-click then send to interactive, this seems to be a bit of a kludge however.

(If I can get this last piece figured out, I think I can finally switch over to PTVS from Pyscripter ;-)



Apr 20, 2012 at 9:53 PM


Apr 20, 2012 at 10:19 PM

Nope, there's currently no way to do this...  You can either open a feature request, or of course we'd always welcome a change to add the feature!  It's probably not too hard of a feature to add, and if you have any questions we'd be glad to help.

Apr 20, 2012 at 10:38 PM

Perhaps the $load interactive window command will provide a workaround. 

>>> $help
  load              Loads commands from file and executes until complete

>>> $load g:\tmp\
>>> import sys
>>> foo = 1
>>> bar = 2
>>> class Foo(object):
...     pass
Apr 23, 2012 at 4:12 PM

Okay, thanks for the responses.

Maybe I'll see if I can tackle and add this in....

Apr 23, 2012 at 10:04 PM

Just learned that I can't work on the code w/o VS Ultimate.... so it seems I've been defeated on adding this feature.

joxn,, thanks for the option, but having to use this workaround isn't viable enough to convince the change over from PyScripter.


I'll add a feature request to the tracker.