Skip to content

Commit

Permalink
Fix pep8 E741 errors
Browse files Browse the repository at this point in the history
  • Loading branch information
rabi committed Aug 19, 2020
1 parent 389077b commit f519a9d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
8 changes: 4 additions & 4 deletions gnocchiclient/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,15 @@ def list2cols(cols, objs):
for o in objs]


def format_string_list(l):
return ", ".join(l)
def format_string_list(li):
return ", ".join(li)


def format_dict_list(l):
def format_dict_list(li):
return "\n".join(
"- " + ", ".join("%s: %s" % (k, v)
for k, v in elem.items())
for elem in l)
for elem in li)


def format_dict_dict(value):
Expand Down
6 changes: 3 additions & 3 deletions gnocchiclient/v1/resource_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,10 +198,10 @@ def _resource_from_args(self, parsed_args, update=False):
resource['metrics'][name] = value
for metric in parsed_args.create_metric:
name, _, value = metric.partition(":")
if value is "":
resource['metrics'][name] = {}
else:
if value:
resource['metrics'][name] = {'archive_policy_name': value}
else:
resource['metrics'][name] = {}

return resource

Expand Down

0 comments on commit f519a9d

Please sign in to comment.