json-repair 0.30.3__py3-none-any.whl → 0.31.0__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.
- json_repair/json_parser.py +14 -1
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/METADATA +1 -1
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/RECORD +7 -7
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/LICENSE +0 -0
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/WHEEL +0 -0
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/entry_points.txt +0 -0
- {json_repair-0.30.3.dist-info → json_repair-0.31.0.dist-info}/top_level.txt +0 -0
json_repair/json_parser.py
CHANGED
@@ -322,11 +322,24 @@ class JSONParser:
|
|
322
322
|
else:
|
323
323
|
# OK but this could still be some garbage at the end of the string
|
324
324
|
# So we need to check if we find a new lstring_delimiter afterwards
|
325
|
-
# If we do, this is a missing delimiter
|
325
|
+
# If we do, maybe this is a missing delimiter
|
326
326
|
i = self.skip_to_character(character=lstring_delimiter, idx=i)
|
327
|
+
if doubled_quotes:
|
328
|
+
i = self.skip_to_character(
|
329
|
+
character=lstring_delimiter, idx=i
|
330
|
+
)
|
327
331
|
next_c = self.get_char_at(i)
|
328
332
|
if not next_c:
|
329
333
|
rstring_delimiter_missing = False
|
334
|
+
else:
|
335
|
+
# But again, this could just be something a bit stupid like "lorem, "ipsum" sic"
|
336
|
+
# Check if we find a : afterwards (skipping space)
|
337
|
+
i = self.skip_whitespaces_at(
|
338
|
+
idx=i + 1, move_main_index=False
|
339
|
+
)
|
340
|
+
next_c = self.get_char_at(i)
|
341
|
+
if next_c and next_c != ":":
|
342
|
+
rstring_delimiter_missing = False
|
330
343
|
else:
|
331
344
|
# There could be a case in which even the next key:value is missing delimeters
|
332
345
|
# because it might be a systemic issue with the output
|
@@ -1,13 +1,13 @@
|
|
1
1
|
json_repair/__init__.py,sha256=c4L2kZrHvWEKfj_ODU2naliNuvU6FlFVxtF0hbLe6s8,178
|
2
2
|
json_repair/__main__.py,sha256=EsJb-y89uZEvGQQg1GdIDWzfDwfOMvVekKEtdguQXCM,67
|
3
3
|
json_repair/json_context.py,sha256=mm6dOyrPJ1sDskTORZSXCW7W9-5veMlUKqXQ3Hw3EG4,971
|
4
|
-
json_repair/json_parser.py,sha256=
|
4
|
+
json_repair/json_parser.py,sha256=8q81FKLqHlsL8BsLCn5gAYvHnHLgZw3HXc8DyHMYYZc,29867
|
5
5
|
json_repair/json_repair.py,sha256=LINLSJBs3cJMfs1YRDaIpfWR5PJLs87Oe06G5yQjY18,9729
|
6
6
|
json_repair/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
7
7
|
json_repair/string_file_wrapper.py,sha256=EHLhNBWoyUitzT08thytYJiNZh_klEFwfT8zutPSdb4,3905
|
8
|
-
json_repair-0.
|
9
|
-
json_repair-0.
|
10
|
-
json_repair-0.
|
11
|
-
json_repair-0.
|
12
|
-
json_repair-0.
|
13
|
-
json_repair-0.
|
8
|
+
json_repair-0.31.0.dist-info/LICENSE,sha256=wrjQo8MhNrNCicXtMe3MHmS-fx8AmQk1ue8AQwiiFV8,1076
|
9
|
+
json_repair-0.31.0.dist-info/METADATA,sha256=_pBYrJ8pfhe0NNivTg1oUVyt0t9P3NCqFcV8n1cGgJg,11794
|
10
|
+
json_repair-0.31.0.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
11
|
+
json_repair-0.31.0.dist-info/entry_points.txt,sha256=SNfge3zPSP-ASqriYU9r3NAPaXdseYr7ciPMKdV2uSw,57
|
12
|
+
json_repair-0.31.0.dist-info/top_level.txt,sha256=7-VZwZN2CgB_n0NlSLk-rEUFh8ug21lESbsblOYuZqw,12
|
13
|
+
json_repair-0.31.0.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|