Skip to content

Commit

Permalink
atualiza filtro data
Browse files Browse the repository at this point in the history
  • Loading branch information
eng-rodrigocunha committed Oct 11, 2023
1 parent e178231 commit 2dd0158
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pipelines/rj_smtr/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -989,7 +989,7 @@ def get_recapture_timestamps(
dates = dates.strftime("%Y-%m-%d").to_list()

for date in dates:
datetime_filter = datetime.now(tz=timezone(constants.TIMEZONE.value)).replace(
datetime_filter = datetime.fromisoformat(f"{date} 23:59:00").replace(
second=0, microsecond=0
)

Expand All @@ -998,6 +998,8 @@ def get_recapture_timestamps(
minute=(datetime_filter.minute // interval_minutes) * interval_minutes
)

datetime_filter = datetime_filter.strftime("%Y-%m-%d %H:%M:%S")

if datetime_filter > current_timestamp:
flag_break = True

Expand Down

0 comments on commit 2dd0158

Please sign in to comment.