According to the Python Enhancement Proposal 8 naming conventions, some concerns include: p>
Avoid certain names
Never use the 'l', 'O', or 'I' characters as variable names because in some fonts they are indistinguishable from numbers one and zero.
Package and module names
Modules should have small names, which are written in lowercase in full.
Ex: package
Class Names
Class names have the first letter of each capitalized word (CamelCase).
Ex: ClassName
Function and method names
Function names and methods should be in lowercase letters, with words separated by underscores as useful for readability.
Ex: name_of_a_function
Note: the mixed case (all uppercase, except the first one) is only allowed in contexts where this is already the prevailing style, to maintain compatibility with previous versions.
Constants
Constants are usually defined at a module level and written in uppercase with underscores separating the words. Examples include MAX_OVERFLOW and TOTAL.
Variable names and function and method parameters
Generally, they follow the same function rule, and should be in lowercase letters with words separated by underscores as useful for readability.
Note: Use self as the first parameter of a method.
Ex: name of a method (self):
Identation
The indentation should be done using four spaces per level.
Blank lines
Blank lines are recommended to separate functions and class definitions (two lines), plus method definitions (one line).
Blanks
White space should be used to separate math, binary, comparison, and assignment operators from other elements.
Ex:
if variavel == False:
print 2 * 3
You should avoid using white space between parentheses and parameters in the declaration of a function, as well as between a function call and the first parenthesis of your argument list.
Ex: function (first_parameter, second_parameter)