We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 696e9bd commit 903237aCopy full SHA for 903237a
pandas/_libs/tslibs/timestamps.pyx
@@ -400,10 +400,14 @@ cdef class _Timestamp(ABCTimestamp):
400
new_value = int(self.value) + int(nanos)
401
402
try:
403
- result = type(self)._from_value_and_reso(new_value, reso=self._reso, tz=self.tzinfo)
+ result = type(self)._from_value_and_reso(
404
+ new_value, reso=self._reso, tz=self.tzinfo
405
+ )
406
except OverflowError as err:
407
# TODO: don't hard-code nanosecond here
- raise OutOfBoundsDatetime(f"Out of bounds nanosecond timestamp: {new_value}") from err
408
+ raise OutOfBoundsDatetime(
409
+ f"Out of bounds nanosecond timestamp: {new_value}"
410
+ ) from err
411
412
if result is not NaT:
413
result._set_freq(self._freq) # avoid warning in constructor
0 commit comments