Skip to content

Commit c06b73f

Browse files
author
AnthonyMalRivett
committed
FINAL FIX BBY
1 parent 407b521 commit c06b73f

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

backend/ingestion/arxiv_to_db.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ def parse_date(d: Optional[str]) -> Optional[date]:
3838
return None
3939
try:
4040
return datetime.strptime(d, "%Y-%m-%d").date()
41-
except Exception:
41+
except ValueError:
4242
return None
4343

4444

@@ -59,7 +59,7 @@ def authors_to_json(x: Any) -> str:
5959
"""Convert author list structure into JSON string."""
6060
try:
6161
return json.dumps(to_plain(x))
62-
except Exception:
62+
except (TypeError, ValueError):
6363
return "[]"
6464

6565

0 commit comments

Comments
 (0)