Skip to content

Commit

Permalink
style(api): Update AutomizationPolicy -> AutomationCondition
Browse files Browse the repository at this point in the history
  • Loading branch information
devsjc committed Sep 10, 2024
1 parent ccba065 commit 9a2112b
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions cloud_archives/pv/passiv/passiv_monthly.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def get_monthly_passiv_data(start_date: datetime, upload_to_hf: bool = True, ove

@dg.asset(
key=["pv", "passiv", "monthly_30min"],
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=dg.TimeWindowPartitionsDefinition(
fmt="%Y-%m",
start="2010-01",
Expand All @@ -104,7 +104,7 @@ def pv_passiv_monthly_30min(context: dg.AssetExecutionContext):

@dg.asset(
key=["pv", "passiv", "monthly_5min"],
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=dg.TimeWindowPartitionsDefinition(
fmt="%Y-%m",
start="2018-01",
Expand Down
4 changes: 2 additions & 2 deletions cloud_archives/pv/passiv/passiv_year.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def get_yearly_passiv_data(start_date: datetime, upload_to_hf: bool = True, over

@dg.asset(
key=["pv", "passiv", "yearly_5min"],
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=dg.TimeWindowPartitionsDefinition(
fmt="%Y",
start="2018",
Expand All @@ -86,7 +86,7 @@ def pv_passiv_yearly_5min(context: dg.AssetExecutionContext):

@dg.asset(
key=["pv", "passiv", "yearly_30min"],
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=dg.TimeWindowPartitionsDefinition(
fmt="%Y",
start="2010",
Expand Down
4 changes: 2 additions & 2 deletions local_archives/nwp/_generic_definitions_factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def make_definitions(
@dg.asset(
name="raw_archive",
key_prefix=opts.key_prefix(),
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=opts.partitions,
check_specs=[
dg.AssetCheckSpec(
Expand Down Expand Up @@ -168,7 +168,7 @@ def _raw_archive(
name="zarr_archive",
key_prefix=opts.key_prefix(),
partitions_def=opts.partitions,
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
ins={"raw_paths": dg.AssetIn(key=_raw_archive.key)},
io_manager_key="nwp_xr_zarr_io",
compute_kind="process",
Expand Down
2 changes: 1 addition & 1 deletion local_archives/nwp/gfs/gfs.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
name="zarr_daily_archive",
description="Daily archive of GFS global NWP data",
key_prefix=["nwp", "gfs", "global"],
auto_materialize_policy=dg.AutoMaterializePolicy.eager(),
auto_materialize_policy=dg.AutomationCondition.eager(),
partitions_def=dg.DailyPartitionsDefinition(
start_date="2015-01-15",
end_offset=-2,
Expand Down

0 comments on commit 9a2112b

Please sign in to comment.