Coding standards is not only to avoid ugly code. It is very useful to get responses quickly.

You can see the python coding standards in PEP8

There are many third party packages to test standards you used in your modules. Especially pylint package is very simple to use.

To install pylint follow the link http://pypi.python.org/pypi/pylint.

Examples:

Here I write two modules having same logic. First one(ws.py) is written with standards and another one(wos.py) is not having standards.

#### With Standards (ws.py) ####

"""
Test the coding standards

"""

from datetime import datetime, timedelta
 
def with_standard():
    """

    Test the coding standards

    """

    st_time = datetime.\
                now()
    data = {'los':30,
            'san':60,
            'can':80,
            'New':20}
    for city, provider_count in data.\
                                iteritems():
        if (city != \[code\] and \
            provider_count < 100):
            pass
    end_time = (datetime.\
                now() - timedelta(hours=st_time.hour,
                                  seconds=st_time.second,
                                  microseconds=st_time.microsecond))
    print "To get response the script took %s \
(Hour:Minutes:Seconds MicroSeconds)" % (end_time.\
                                            strftime('%H:%M:%S %f'))
    return ()

if __name__ == '__main__':
    with_standard()

### End of Module ###

### Without standards (wos.py) ###

from datetime import datetime,timedelta
 
def without_standard():
    st_time = datetime.now()
    data = {'los':30,'san':60,'can':80,'New':20}
    for key,value in data.iteritems():
        if key != \[/code\] and value < 100:
            pass
    end_time = datetime.now() - timedelta(hours=st_time.hour,seconds=st_time.second,microseconds=st_time.microsecond)
    print "To get response the script took %s (Hour:Minutes:Seconds MicroSeconds)" %(end_time.strftime('%H:%M:%S %f'))
    return ()
   
if __name__ == '__main__':
    without_standard()

### End of Module ###

Test standards:

If we execute pylint ws.py command from command line, it will give 10.00/10 as the standards rate.

When we execute pylint wos.py command, it will give 3.85/10 as the rate. 

Now you can see a huge difference between standards' rate.

So try to follow standards in your future modules :)