rara-tools 0.4.1__py3-none-any.whl → 0.4.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of rara-tools might be problematic. Click here for more details.

@@ -39,11 +39,17 @@ class EMSMARCParser(BaseMARCParser):
39
39
  f"from MARC dump '{self.marc_file_path}'."
40
40
  )
41
41
  for record in self.marc_record_generator():
42
- ems_record = EMSRecord(
43
- record=record,
44
- add_variations=self.add_variations
45
- )
46
- if ems_record.keyword_type == KeywordType.LOC:
42
+ try:
43
+ ems_record = EMSRecord(
44
+ record=record,
45
+ add_variations=self.add_variations
46
+ )
47
+ if ems_record.keyword_type == KeywordType.LOC:
48
+ continue
49
+ else:
50
+ yield ems_record.full_record
51
+ except Exception as e:
52
+ LOGGER.warning(
53
+ f"Error while parsing record {record}: {e}"
54
+ )
47
55
  continue
48
- else:
49
- yield ems_record.full_record
@@ -38,9 +38,15 @@ class LocationMARCParser(BaseMARCParser):
38
38
  f"from MARC dump '{self.marc_file_path}'."
39
39
  )
40
40
  for record in self.marc_record_generator():
41
- ems_record = EMSRecord(
42
- record=record,
43
- add_variations=self.add_variations
44
- )
45
- if ems_record.keyword_type == KeywordType.LOC:
46
- yield ems_record.full_record
41
+ try:
42
+ ems_record = EMSRecord(
43
+ record=record,
44
+ add_variations=self.add_variations
45
+ )
46
+ if ems_record.keyword_type == KeywordType.LOC:
47
+ yield ems_record.full_record
48
+ except Exception as e:
49
+ LOGGER.warning(
50
+ f"Error while parsing record {record}: {e}"
51
+ )
52
+ continue
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rara-tools
3
- Version: 0.4.1
3
+ Version: 0.4.2
4
4
  Summary: Tools to support Kata's work.
5
5
  Classifier: Programming Language :: Python :: 3
6
6
  Classifier: Programming Language :: Python :: 3.10
@@ -18,8 +18,8 @@ rara_tools/normalizers/base.py,sha256=taOboGURQF_ACPVWHX_wMsaDEo8gYdAkiOw0yT0zzR
18
18
  rara_tools/normalizers/bibs.py,sha256=4DTS6k37z8qR5B3n7aiCXsT5Z49rLTvQ60lKKr5dyLs,2352
19
19
  rara_tools/normalizers/viaf.py,sha256=9uTyEadSaoFedUbUfY_iWPJtgrt04jP71i_6MLPM08I,6919
20
20
  rara_tools/parsers/marc_parsers/base_parser.py,sha256=wzCccZaiN4p2iUms3PAOfXihNgEeg1cGRzRx26ytJeA,1661
21
- rara_tools/parsers/marc_parsers/ems_parser.py,sha256=70WdxnbxZmOqla7EAUapCiCWZl0zRPwghKy25sSKFiY,1801
22
- rara_tools/parsers/marc_parsers/location_parser.py,sha256=18HExO2BLs1ZJodjNF8YOkB5CJ7bd6_zmyIIzALL7aI,1658
21
+ rara_tools/parsers/marc_parsers/ems_parser.py,sha256=LFuhZcVwmHMcJknX9p4ZkO8RdjPdQZ4APGbw8KV6BIs,2024
22
+ rara_tools/parsers/marc_parsers/location_parser.py,sha256=dSU9dQoGV5z0ajhLI1bn3AAghkOr79qKIrX7sO0_4lA,1873
23
23
  rara_tools/parsers/marc_parsers/organization_parser.py,sha256=faqQEYsut_ZF3kX1QycTnbRIqC7W8sULxmG75ICfya8,1629
24
24
  rara_tools/parsers/marc_parsers/person_parser.py,sha256=iMycHSlgfvgB0axE_rneB5sImVlc920FcBnTsUsmVW4,1582
25
25
  rara_tools/parsers/marc_parsers/title_parser.py,sha256=0FnX1kl9InELlSqMGECjswEbhP-sKl55TuhV05RhWSw,14
@@ -31,8 +31,8 @@ rara_tools/parsers/marc_records/title_record.py,sha256=0FnX1kl9InELlSqMGECjswEbh
31
31
  rara_tools/parsers/tools/entity_normalizers.py,sha256=afOMqJoL4aeq0cfsohIuxkxzvqNdZ_ba7U32eyogbzk,8722
32
32
  rara_tools/parsers/tools/marc_converter.py,sha256=PUbggzJ_wHfke_bHTF2LOZyzX1t0wRM8qIFL36Dl3AI,414
33
33
  rara_tools/parsers/tools/russian_transliterator.py,sha256=5ZU66iTqAhr7pmfVqXPAI_cidF43VqqmuN4d7H4_JuA,9770
34
- rara_tools-0.4.1.dist-info/licenses/LICENSE.md,sha256=hkZVnIZll7e_KNEQzeY94Y9tlzVL8iVZBTMBvDykksU,35142
35
- rara_tools-0.4.1.dist-info/METADATA,sha256=sFfkDsn8uqkP4VpSBerftW9zrC0GLCbkCSiMmgwcdxI,4054
36
- rara_tools-0.4.1.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
37
- rara_tools-0.4.1.dist-info/top_level.txt,sha256=JwfB5b8BAtW5OFKRln2AQ_WElTRyIBM4nO0FKN1cupY,11
38
- rara_tools-0.4.1.dist-info/RECORD,,
34
+ rara_tools-0.4.2.dist-info/licenses/LICENSE.md,sha256=hkZVnIZll7e_KNEQzeY94Y9tlzVL8iVZBTMBvDykksU,35142
35
+ rara_tools-0.4.2.dist-info/METADATA,sha256=U1kkRCHyi5F--mlc9Vs9qEGihWDIDxtxd0YhgmFoSAg,4054
36
+ rara_tools-0.4.2.dist-info/WHEEL,sha256=CmyFI0kx5cdEMTLiONQRbGQwjIoR1aIYB7eCAQ4KPJ0,91
37
+ rara_tools-0.4.2.dist-info/top_level.txt,sha256=JwfB5b8BAtW5OFKRln2AQ_WElTRyIBM4nO0FKN1cupY,11
38
+ rara_tools-0.4.2.dist-info/RECORD,,