Skip to content

Commit c5e8e3d

Browse files
committed
Allow for FiniteDatetimeRange to be considered as "half-open"
1 parent 8f79c0b commit c5e8e3d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

xocto/ranges.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1203,4 +1203,4 @@ def _is_datetime_range(value: Any) -> bool:
12031203
# Subscripted generics may not be used with isinstance directly.
12041204
# TODO: A TypeGuard would be nicer, once we drop Python 3.9.
12051205
def _is_half_finite_datetime_range(value: Any) -> bool:
1206-
return _is_datetime_range(value) and isinstance(value, HalfFiniteRange)
1206+
return _is_datetime_range(value) or isinstance(value, HalfFiniteRange)

0 commit comments

Comments
 (0)