1

I can run my pygame project fine in either of the IDEs I use (Spyder and IEP), but then I try makes changes to some of the .py files and when I run the project again, the changes don't show up. I think this has something to do with the IDEs running .py files as scripts, but I can't figure out a good solution. I tried deleting the compiled files but the same problem still occurs.

2
  • Whenever you make a change to your .py files, you need to save them and restart the python session. You're saying that when you do that, nothing changes? Commented Apr 20, 2013 at 22:40
  • No, that works, but I was hoping to not have to restart the python session every time I make a change Commented Apr 20, 2013 at 22:52

1 Answer 1

1

You can use the reload function to update the running python instance with the updated files.

Sign up to request clarification or add additional context in comments.

3 Comments

So do I call reload(MyModuleName) or reload(ModulesMyCodeUses)?
@zergylord You'd need to reload the modules that have changed since your last save.
anyway to just reset all modules? My project has alot of files in it :-/

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.