🎨 Format Python code with Black

This commit is contained in:
alexAubin 2021-08-27 20:14:09 +00:00 committed by GitHub
parent 55774ef8fc
commit fe84eba4ab
3 changed files with 4 additions and 0 deletions

View file

@ -379,6 +379,7 @@ class ExtraArgumentParser(object):
# Main class ----------------------------------------------------------
class ActionsMap(object):
"""Validate and process actions defined into an actions map

View file

@ -24,6 +24,7 @@ for key in env.keys():
env["NAMESPACES"] = env["NAMESPACES"].split()
def during_unittests_run():
return "TESTS_RUN" in os.environ

View file

@ -31,6 +31,7 @@ from moulinette.utils import log
# But it display instead:
# Error: unable to parse arguments 'firewall' because: sequence item 0: expected str instance, NoneType found
def monkey_get_action_name(argument):
if argument is None:
return None
@ -502,6 +503,7 @@ class Interface:
if output_as:
if output_as == "json":
import json
print(json.dumps(ret, cls=JSONExtendedEncoder))
else:
plain_print_dict(ret)