Skip to content

Commit

Permalink
0.6.24
Browse files Browse the repository at this point in the history
  • Loading branch information
joocer committed Jun 27, 2024
1 parent 081dd26 commit 1d3cd24
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
11 changes: 3 additions & 8 deletions mabel/utils/dates.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,6 @@
except ImportError:
numpy = None

try:
import pandas
except ImportError:
pandas = None

TIMEDELTA_REGEX = (
r"((?P<days>-?\d+)d)?"
r"((?P<hours>-?\d+)h)?"
Expand Down Expand Up @@ -79,9 +74,9 @@ def parse_iso(
if isinstance(value, numpy.datetime64):
value = value.astype(datetime.datetime)
input_type = type(value)
if pandas:
if hasattr(value, "to_pydatetime"):
return value.to_pydatetime()

if hasattr(value, "to_pydatetime"):
return value.to_pydatetime()

if input_type == datetime.datetime:
return value
Expand Down
2 changes: 1 addition & 1 deletion mabel/version.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Store the version here so:
# 1) we don't load dependencies by storing it in __init__.py
# 2) we can import it in setup.py for the same reason
__version__ = "0.6.23"
__version__ = "0.6.24"

# nodoc - don't add to the documentation wiki

0 comments on commit 1d3cd24

Please sign in to comment.