Skip to content

Commit b7aaa02

Browse files
author
Matt Roeschke
committed
Handle compat error
1 parent e67403e commit b7aaa02

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pandas/_libs/tslibs/nattype.pyx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ cpdef bint is_np_nat(x):
4646
except AttributeError:
4747
# numpy 1.12 compat
4848
return str(x) == 'NaT'
49-
except TypeError:
49+
except (TypeError, ValueError):
5050
# np.isnat only defined for datetime, timedelta
5151
return False
5252

0 commit comments

Comments
 (0)