Skip to content

Commit

Permalink
Fix rueckstiess#688: mplotqueries with --group-limit throws error in …
Browse files Browse the repository at this point in the history
…Python 3.x (rueckstiess#689)
  • Loading branch information
stennie authored and savinay-vijay committed Jul 16, 2019
1 parent 77dde63 commit 0443da3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mtools/util/grouping.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,10 @@ def sort_by_size(self, group_limit=None, discard_others=False,

# now group together all groups that did not make the limit
if not discard_others:
group_keys = self.groups.keys()[group_limit - 1:]
group_keys = list(self.groups.keys())[group_limit - 1:]
self.groups.setdefault(others_label, list())
else:
group_keys = self.groups.keys()[group_limit:]
group_keys = list(self.groups.keys())[group_limit:]

# only go to second last (-1), since the 'others' group is now last
for g in group_keys:
Expand Down

0 comments on commit 0443da3

Please sign in to comment.