We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9d22a77 commit 5a7b312Copy full SHA for 5a7b312
pandas/core/arrays/datetimes.py
@@ -775,6 +775,9 @@ def _add_offset(self, offset) -> DatetimeArray:
775
def _sub_datetimelike_scalar(self, other):
776
# subtract a datetime from myself, yielding a ndarray[timedelta64[ns]]
777
assert isinstance(other, (datetime, np.datetime64))
778
+ # error: Non-overlapping identity check (left operand type: "Union[datetime,
779
+ # datetime64]", right operand type: "NaTType") [comparison-overlap]
780
+ assert other is not NaT # type: ignore[comparison-overlap]
781
other = Timestamp(other)
782
# error: Non-overlapping identity check (left operand type: "Timestamp",
783
# right operand type: "NaTType")
0 commit comments