Vinnie
02/24/2023, 3:25 PMTried to access partition_key for a non-partitioned run
. It seems like testing the schedules correctly sets tags and configuration in the results (see screenshot) but those aren’t passed on to the launchpad, which then launches an unpartitioned run.
I’d assume it’s also the case for partitioned non-asset jobs, but haven’t tested that.
Minimal code example:
@asset(partitions_def=StaticPartitionsDefinition(["1", "2"]))
def my_asset(context):
return context.partition_key
my_job = define_asset_job(
"my_job",
"my_asset",
partitions_def=StaticPartitionsDefinition(["1", "2"]),
)
@schedule("* * * * *", job=my_job)
def my_schedule():
return my_job.run_request_for_partition(partition_key="1")
claire
02/24/2023, 5:57 PMchris
02/24/2023, 7:39 PMchris
03/06/2023, 5:41 PM