Graham Wetzler
02/08/2023, 10:11 PMop
that is automatically run downstream of a dbt model based on the presence of a meta tag?Nicolas Parot Alvarez
02/09/2023, 3:23 PMcontext.instance.get_runs(
RunsFilter(
job_name=your_job.name,
tags={"your_tag_name": your_tag_value},
statuses=[DagsterRunStatus.SUCCESS],
),
)
So you could have a sensor that will monitor the refresh of your DBT model (job status sensor or asset sensor) and if there's a new run for the specific tag, request a run for the job that contains your op.
I think you could use the run's run_id
as the RunRequest run_key
so you don't request your op to run more than once for the same run.Graham Wetzler
02/09/2023, 3:42 PMNicolas Parot Alvarez
02/09/2023, 4:46 PM