Skip to content

Commit c4f2e3a

Browse files
fix: handle AirbyteDateTime objects in DatetimeBasedCursor
Co-Authored-By: Aaron <AJ> Steers <[email protected]>
1 parent e4d281f commit c4f2e3a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

airbyte_cdk/sources/declarative/incremental/datetime_based_cursor.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,8 @@ def _evaluate_next_start_date_safely(
294294
would have broken anyway.
295295
"""
296296
try:
297+
if hasattr(start, "to_datetime"):
298+
start = start.to_datetime()
297299
return start + step
298300
except OverflowError:
299301
return datetime.datetime.max.replace(tzinfo=datetime.timezone.utc)

0 commit comments

Comments
 (0)