fix: Properly count the unparsable files

pull/12/head
Raphaël Vinot 2018-06-11 19:07:03 +02:00
parent c8089ae140
commit 94cacc5b8b
1 changed files with 1 additions and 1 deletions

View File

@ -59,7 +59,7 @@ class RawFilesParser():
def parse_raw_files(self): def parse_raw_files(self):
set_running(f'{self.__class__.__name__}-{self.source}') set_running(f'{self.__class__.__name__}-{self.source}')
self.logger.warning('Was unable to parse {} files.'.format(len([self.unparsable_dir.iterdir()]))) self.logger.warning('Was unable to parse {} files.'.format(len([f for f in self.unparsable_dir.iterdir() if f.is_file()])))
try: try:
for filepath in self.files_to_parse: for filepath in self.files_to_parse:
self.logger.debug('Parsing {}, {} to go.'.format(filepath, len(self.files_to_parse) - 1)) self.logger.debug('Parsing {}, {} to go.'.format(filepath, len(self.files_to_parse) - 1))