PrefectHQ / prefect-dbt

Collection of Prefect integrations for working with dbt with your Prefect flows.

Home Page:https://prefecthq.github.io/prefect-dbt/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Block registration states 4 new block types created, but UI shows 6 new block types

discdiver opened this issue · comments

I think the the block registration message needs updated when prefect block register -m prefect_dbt is run.
I had no dbt blocks showing in the uI prior to running the registration command.

Screenshots attached.
Screen Shot 2022-11-08 at 3 01 18 PM
Screen Shot 2022-11-08 at 3 01 43 PM

I think it's because the top level __init__ has:

  1. DbtCloudCredentials
  2. DbtCliProfile
  3. SnowflakeTargetConfigs
  4. BigQueryTargetConfigs
  5. PostgresTargetConfigs (but you don't have the postgres requirements installed so it's not registered)

This results in +4.

Because it references from .cli, this makes it search the CLI directory __init__ finding the two other:

  1. TargetConfigs
  2. GlobalConfigs
  • 2 = 6 that you see on Cloud.

This is probably a "bug" or unexpected feature of Prefect's block discovery logic, not particular to prefect-dbt, but any package that has this structure.

However, I think I should expose TargetConfigs and GlobalConfigs blocks at the top level too for prefect-dbt.