Skip to content

Commit de66535

Browse files
author
MarcoGorelli
committed
exhaust match
1 parent 7d27066 commit de66535

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pandas/_libs/tslibs/conversion.pyx

+2
Original file line numberDiff line numberDiff line change
@@ -173,6 +173,8 @@ cpdef inline (int64_t, int) precision_from_unit(
173173
multiplier = 1_000
174174
elif out_reso == NPY_DATETIMEUNIT.NPY_FR_s:
175175
multiplier = 1
176+
else:
177+
raise ValueError(f"Invalid out_reso: {out_reso}")
176178

177179
if reso == NPY_DATETIMEUNIT.NPY_FR_Y:
178180
# each 400 years we have 97 leap years, for an average of 97/400=.2425

0 commit comments

Comments
 (0)