Brendan Jackson
06/29/2023, 4:24 PMif context.has_partition_key:
time_window = context.asset_partitions_time_window
start_date = time_window.start.date()
end_date = time_window.end.date()
But when I test this:
context = build_output_context(
asset_key=AssetKey(("test", "test_table")),
partition_key="2022-01-02",
)
I get an error accessing that time window via `context.asset_partitions_time_window`:
dagster._core.errors.DagsterInvariantViolationError: Attempting to access step_context, but it was not provided when constructing the OutputContext