Bulk autopep8 (modules)

As agreed in 2017-12-07 Core meeting bulk fix pep8 issues

Generated using:
autopep8 1.3.3 (pycodestyle: 2.3.1)
autopep8 -r  --max-line-length 160 --in-place --ignore E305,E402,E722,E741 lib/ansible/modules

Manually fix issues that autopep8 has introduced
This commit is contained in:
John Barker
2017-12-07 16:27:06 +00:00
committed by John R Barker
parent d13d7e9404
commit c57a7f05e1
314 changed files with 3462 additions and 3383 deletions

View File

@@ -151,6 +151,7 @@ def get_acl_config(module, acl_name):
return NetworkConfig(indent=1, contents='\n'.join(filtered_config))
def parse_acl_name(module):
first_line = True
for line in module.params['lines']:
@@ -168,6 +169,7 @@ def parse_acl_name(module):
return acl_name
def main():
argument_spec = dict(

View File

@@ -187,7 +187,6 @@ def main():
msg = 'One or more conditional statements have not be satisfied'
module.fail_json(msg=msg, failed_conditions=failed_conditions)
result.update({
'changed': False,
'stdout': responses,

View File

@@ -201,7 +201,6 @@ from ansible.module_utils.network.common.config import NetworkConfig, dumps
from ansible.module_utils._text import to_native
def get_candidate(module):
candidate = NetworkConfig(indent=1)
if module.params['src']:
@@ -211,6 +210,7 @@ def get_candidate(module):
candidate.add(module.params['lines'], parents=parents)
return candidate
def run(module, result):
match = module.params['match']
replace = module.params['replace']
@@ -251,6 +251,7 @@ def run(module, result):
run_commands(module, 'write mem')
result['changed'] = True
def main():
""" main entry point for module execution
"""
@@ -293,7 +294,6 @@ def main():
config = None
if module.params['backup']:
result['__backup__'] = get_config(module)