Live code edits when running script (or web server) in PyCharm

Can I configure PyCharm to pick up and re-compile code changes while I'm running a script in the IDE?

For example, let's say I have two files, and In I simply have a while loop that calls a function in foo.

import foo
import time

while True:

And the function in is simple.

def foo():

When I run in PyCharm, as expected "hello" is printed over and over again, once per second. While the script is running, I want to edit and change the printed message to "goodbye". Upon making this change I want PyCharm to automatically detect and process this change, so that the console starts showing "goodbye" instead of "hello".

Is this possible, without stopping and restarting the script?

Please sign in to leave a comment.