Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
aysim319 committed Sep 13, 2024
1 parent 670bf04 commit 2f94d15
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions google_symptoms/delphi_google_symptoms/date_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,13 @@ def generate_num_export_days(params: Dict, logger) -> [int]:
if num_export_days is None and not custom_run:
# Generate a list of signals we expect to produce
sensor_names = set(
"_".join([metric, smoother, "search"])
for metric, smoother in product(COMBINED_METRIC, SMOOTHERS)
"_".join([metric, smoother, "search"]) for metric, smoother in product(COMBINED_METRIC, SMOOTHERS)
)
Epidata.auth = ("epidata", params["indicator"]["api_credentials"])
# Fetch metadata to check how recent each signal is
metadata = Epidata.covidcast_meta()
# Filter to only those we currently want to produce, ignore any old or deprecated signals
gs_metadata = metadata[(metadata.data_source == "google-symptoms") &
(metadata.signal.isin(sensor_names))]
gs_metadata = metadata[(metadata.data_source == "google-symptoms") & (metadata.signal.isin(sensor_names))]

if sensor_names.difference(set(gs_metadata.signal)):
# If any signal not in metadata yet, we need to backfill its full history.
Expand Down

0 comments on commit 2f94d15

Please sign in to comment.