Skip to content

Commit 98898dc

Browse files
committed
review comments
1 parent df29799 commit 98898dc

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

pandas/_libs/tslibs/timestamps.pyx

+3-3
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ cdef inline object create_timestamp_from_ts(int64_t value,
7070
return ts_base
7171

7272

73-
class RoundTo:
73+
class RoundTo(object):
7474
"""
7575
enumeration defining the available rounding modes
7676
@@ -188,8 +188,8 @@ def round_nsint64(values, mode, freq):
188188

189189
# if/elif above should catch all rounding modes defined in enum 'RoundTo':
190190
# if flow of control arrives here, it is a bug
191-
raise AssertionError("round_nsint64 called with an unrecognized "
192-
"rounding mode")
191+
raise ValueError("round_nsint64 called with an unrecognized "
192+
"rounding mode")
193193

194194

195195
# This is PITA. Because we inherit from datetime, which has very specific

0 commit comments

Comments
 (0)