PyChecker must execute script?

Geoff Gerrietts geoff at
Wed Feb 5 21:44:25 CET 2003

Quoting Afanasiy (abelikov72 at
> I was hoping to find a typo/syntax checking solution so a
> long running script did not fail when it encountered them.
> I spent the time to get the suggested PyChecker utility installed
> and have run it on one of the above-mentioned script files. Shortly
> thereafter, I killed it because it was just executing my script...
> Is this simply how PyChecker works? That seems a little odd to me.

I believe PyChecker imports the modules, and analyzes the resulting

If you have not included an "if __name__ == '__main__':" conditional,
then it is likely that importing the module and running it will be
fundamentally identical.


Geoff Gerrietts        <geoff at gerrietts dot net>
"Ordinarily he was insane, but he had lucid moments 
when he was merely stupid."        --Heinrich Heine

More information about the Python-list mailing list