Adding TypeError handling to try_parse_datetime_from_json_string