MarkTransell/masterscode — Issue #2: Use the if __name__=="__main__": pattern
Author: alchemyst
Created: 2012-02-09 18:17:28+00:00
State: open

Almost every file in your project has code that runs when you run the file. Unfortunately, this code will also run when you import the files as a module. This is mostly not what you want.

Wrap the "running" lines of your code like this:

if __name__=="__main__":
runnable code here

Take care not to delete that code as some of it seems a lot like tests.