In most programming environments it's clear how the code is distributed into several parts and how everything interacts. In Python I seem to be completely lost.
How should the layout of a Python application look?
Currently I have:
setup.py application_name/ __main__.py __init__.py views/ controllers/ model/ resources/ <- images, videos, ...
How does one execute the application?
I've got a runner script with the following content
#!/usr/bin/env python -m "application_name"
Should one even use
__main__.py
for this purpose? Is a runner script necessary?How should one import parts of the application? (Python 2.6)
For example in
application_name/__main__.py
from . import controllers.MainWindow
How do you layout your applications?