Skip to content

Commit

Permalink
Added length to status output for group filter
Browse files Browse the repository at this point in the history
Previously ended up not showing the length of corpora that were grouped
on the fly by this filter.
  • Loading branch information
markgw committed Aug 5, 2020
1 parent 3e64300 commit 42440a5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/python/pimlico/modules/corpora/group/info.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,9 @@ def process_setup(self):
def __len__(self):
return len(self.input_reader)

def get_detailed_status(self):
return super(CorpusGroupReader, self).get_detailed_status() + ["Length: {:,}".format(len(self))]

def extract_file(self, archive_name, filename):
raise TypeError("cannot extract files from filter: it's not an actual corpus")

Expand Down

0 comments on commit 42440a5

Please sign in to comment.