Skip to content

Commit

Permalink
Fix parsing (#305)
Browse files Browse the repository at this point in the history
* The date parsing has started to fail with date-looking things. Only allow if actually allowing.

* Suppress all exceptions so only work when it works.
  • Loading branch information
wtgee authored Dec 6, 2023
1 parent 06531a9 commit 1020576
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/panoptes/utils/serializers.py
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ def deserialize_all_objects(obj):
return u.Quantity(obj)

# Try to parse a ISO-8061 datetime string.
with suppress(TypeError, ValueError):
with suppress(Exception):
return date_parse(obj)

return obj
Expand Down

0 comments on commit 1020576

Please sign in to comment.