fix: inconsistent ids

This commit is contained in:
2026-07-26 17:51:46 +02:00
parent 11b805b627
commit 29acd9594d
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -138,7 +138,7 @@ def generateBernAsianHornetFeed(ASSETS, CACHE):
for start, end in weeklyRangesFrom(arbitraryStartDate): # arbitrary start date
weeklyEntry = {}
weeklyEntry["id"] = datetime.combine(start, time(12, 0)).timestamp() # we use epoch time as the id
weeklyEntry["id"] = f"asian-hornets-bern-{start.isoformat()}-{end.isoformat()}" # we use epoch time as the id EDIT: NO THIS BROKE MULTIPLE TIMES MAKING SOME ID CHANGES. WE CHANGE THAT
weeklyEntry["creationDate"] = end.isoformat()
weeklyEntry["date"] = end.isoformat() # there is no point of updating it later, as (I think) data isn't retroactively put
weeklyEntry["source"] = "opendata.swiss"