Skip to content

Commit 0f9969d

Browse files
authored
FIX: Add end_date to query to restrict future file searches (#258)
We only passed in start_date to our query before, but this does a >= search into the future, which meant that during our I&T testing when more files are uploaded and in the future, we can accidentally match on them. We only want the specific day of this file, so add the end_date parameter as well.
1 parent b76c7b3 commit 0f9969d

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

imap_data_access/webpoda.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,8 @@ def _get_latest_version_file_path(
528528
data_level="l0",
529529
descriptor="raw",
530530
start_date=start_time.strftime("%Y%m%d"),
531+
# start_date is >= so we need to add an end_date to restrict the query
532+
end_date=start_time.strftime("%Y%m%d"),
531533
repointing=repointing,
532534
)
533535
if len(current_files):

0 commit comments

Comments
 (0)