From 1de22f0c5e07c39aefc382b4f6f81cc9a90238da Mon Sep 17 00:00:00 2001 From: Jacob Bieker Date: Tue, 12 Sep 2023 12:07:38 +0100 Subject: [PATCH] Set to specific assets --- sat/assets/eumetsat/common.py | 1 - sat/jobs.py | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/sat/assets/eumetsat/common.py b/sat/assets/eumetsat/common.py index ef36eae..7eff79c 100644 --- a/sat/assets/eumetsat/common.py +++ b/sat/assets/eumetsat/common.py @@ -33,7 +33,6 @@ def download_product_range(api_key: str, api_secret: str, data_dir: str, product start_date=start_date.tz_localize(None).strftime("%Y-%m-%d-%H-%M-%S"), end_date=end_date.tz_localize(None).strftime("%Y-%m-%d-%H-%M-%S"), ) - # TODO Change this to actually filter, this only works for live service filtered_datasets = [] for dataset in datasets: if dataset["id"] not in filenames_downloaded: diff --git a/sat/jobs.py b/sat/jobs.py index 3ee798e..6902ca3 100644 --- a/sat/jobs.py +++ b/sat/jobs.py @@ -2,13 +2,14 @@ from dagster import AssetSelection, define_asset_job, EnvVar from sat.assets.eumetsat.common import EumetsatConfig +from sat.assets import download_eumetsat_iodc_data base_path = "/mnt/storage_c/IODC/" asset_jobs = [] -asset_job = define_asset_job(f"download_iodc_raw_files", AssetSelection.all(), +asset_job = define_asset_job(f"download_iodc_raw_files", AssetSelection.assets(download_eumetsat_iodc_data), config={ 'ops': {"download_eumetsat_iodc_data": {"config": EumetsatConfig(api_key=EnvVar("EUMETSAT_API_KEY"), api_secret=EnvVar("EUMETSAT_API_SECRET"),