qizhiyi / sqlalchemy-migrate

Automatically exported from code.google.com/p/sqlalchemy-migrate
MIT License
0 stars 0 forks source link

manage.py should use the "if __name__=='__main__'" trick #121

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
using 0.7.1 i created a repository within the base directory of my application 
package. so when nosetests was run looking for doctests - thereby importing all 
modules - a somewhat confusing message appeared in the output: the usage info 
of migrate but using "nosetests" as command name.
This behaviour could be supressed, by simply putting the content of manage.py 
behind a "if __name__=='__main__'" condition.

Original issue reported on code.google.com by xrotw...@googlemail.com on 22 Jun 2011 at 10:20

GoogleCodeExporter commented 8 years ago
Same for pydoc.

Original comment by jvant...@gmail.com on 6 Jul 2011 at 11:02

GoogleCodeExporter commented 8 years ago
I'll take care of this

Original comment by jan.ditt...@gmail.com on 28 Oct 2011 at 10:46

GoogleCodeExporter commented 8 years ago
manage.py_tmpl uses if __name__ == '__main__' since changeset 255c9e2274d6 by 
iElectric from Fri Aug 20 15:40:14 2010 +0200

Original comment by jan.ditt...@gmail.com on 28 Oct 2011 at 10:52

GoogleCodeExporter commented 8 years ago
This issue was closed by revision 1c9c64d89c7a.

Original comment by jan.ditt...@gmail.com on 28 Oct 2011 at 11:46