Skip to content

Asset support for prefect-dbt run_dbt_cloud_job #19606

@robfreedy

Description

@robfreedy

Describe the current behavior

Currently, automatic asset generation for dbt nodes is only supported in prefect-dbt for dbt Core projects (see docs here. Asset generation for dbt Cloud jobs has to be done by manually adding the materialize decorator

Describe the proposed behavior

Utilizing the dbt Mesh patterns/features, automatically materialize dbt Cloud jobs as Prefect Assets.

Example Use

result = await run_dbt_cloud_job(
        dbt_cloud_job = await DbtCloudJob.load("JOB-BLOCK-NAME-PLACEHOLDER"),
        targeted_retries = 0,
       create_assets=True
    )

### Additional context

_No response_

Metadata

Metadata

Assignees

Labels

enhancementAn improvement of an existing feature

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions