diff --git a/combo/data/dataset.py b/combo/data/dataset.py index 9aabe1912896b8990bacea6d36699a5f3a4839f6..870659fe27857d157e5061f77690f61f166330a7 100644 --- a/combo/data/dataset.py +++ b/combo/data/dataset.py @@ -82,8 +82,8 @@ class UniversalDependenciesDatasetReader(allen_data.DatasetReader): for conllu_file in file_path: file = pathlib.Path(conllu_file) assert conllu_file and file.exists(), f"File with path '{conllu_file}' does not exists!" - with file.open("r"): - for annotation in conllu.parse_incr(file, fields=self.fields, field_parsers=self.field_parsers): + with file.open("r") as f: + for annotation in conllu.parse_incr(f, fields=self.fields, field_parsers=self.field_parsers): yield self.text_to_instance(annotation) @overrides diff --git a/setup.py b/setup.py index 0779eaf0c59862932225cf13dacdeab079810994..0c8c371d4db9021d32d7bc8acd01c90a3c6e9bb5 100644 --- a/setup.py +++ b/setup.py @@ -20,7 +20,7 @@ REQUIREMENTS = [ setup( name='combo', - version='1.0.0b3', + version='1.0.0b4', author='Mateusz Klimaszewski', author_email='M.Klimaszewski@ii.pw.edu.pl', install_requires=REQUIREMENTS,