flake8 fixup

config :

[flake8]
ignore = E265,W293,E303,E126,E127,E128,E129
max-line-length = 160
exclude = tests/*
max-complexity = 10

contrailplugin.py:

F811 redefinition of unused 'logging' from line 10
E122 continuation line missing indentation or outdented
E703 statement ends with a semicolon
W291 trailing whitespace
E225 missing whitespace around operator
F821 undefined name 'db'
F811 redefinition of unused 'update_security_group' from line 161
F821 undefined name '_'
E128 continuation line under-indented for visual indent
E126 continuation line over-indented for hanging indent

ctdb/config_db.py

F401 'socket' imported but unused
F841 local variable 'e' is assigned to but never used
E711 comparison to None should be 'if cond is None:'
F841 local variable 'fip_pool_uuid' is assigned to but never used
F841 local variable 'sg_uuid' is assigned to but never used
F841 local variable 'project_uuid' is assigned to but never used
E502 the backslash is redundant between brackets
E711 comparison to None should be 'if cond is None:'
W291 trailing whitespace
E231 missing whitespace after ':'
F841 local variable 'port_parent_name' is assigned to but never used
E712 comparison to True should be 'if cond is True:' or 'if cond:'
E711 comparison to None should be 'if cond is None:'
E111 indentation is not a multiple of four
F841 local variable 'rt_uuid' is assigned to but never used
F841 local variable 'si_uuid' is assigned to but never used

TODO function to check:

C901 'DBInterface.__init__' is too complex (10)
C901 'DBInterface._route_table_neutron_to_vnc' is too complex (10)
C901 'DBInterface._security_group_rule_vnc_to_neutron' is too complex (11)
C901 'DBInterface._network_neutron_to_vnc' is too complex (15)
C901 'DBInterface._network_vnc_to_neutron' is too complex (10)
C901 'DBInterface._port_neutron_to_vnc' is too complex (10)
C901 'DBInterface._port_vnc_to_neutron' is too complex (17)
C901 'DBInterface.network_list' is too complex (29)
C901 'DBInterface.subnet_create' is too complex (11)
C901 'DBInterface.subnets_list' is too complex (16)
C901 'DBInterface.router_list' is too complex (17)
C901 'DBInterface.floatingip_list' is too complex (11)
C901 'DBInterface.port_create' is too complex (12)
C901 'DBInterface.port_delete' is too complex (15)
C901 'DBInterface.port_list' is too complex (20)
C901 'DBInterface.route_table_list' is too complex (10)
C901 'DBInterface.svc_instance_list' is too complex (10)

quota/driver.py:

F401 'Http' imported but unused
F401 're' imported but unused
F401 'string' imported but unused
E302 expected 2 blank lines, found 1
E123 closing bracket does not match indentation of opening bracket's line
E703 statement ends with a semicolon
F821 undefined name 'exceptions'
E231 missing whitespace after ','

Signed-off-by: Nicolas PLANEL <nicolas.planel@enovance.com>