dbt-labs / dbt-external-tables

dbt macros to stage external sources
https://hub.getdbt.com/dbt-labs/dbt_external_tables/latest/
Apache License 2.0
288 stars 116 forks source link

doc macro doesn't work on partitions #207

Closed ghost closed 1 year ago

ghost commented 1 year ago

Describe the bug

In the dbt source yaml file, a source model's external partitions' descriptions don't recognize the doc macro.

Steps to reproduce

Create a yml file with source table, add the external key, add a partition and set the description as `{{ doc("something") }}'

Expected results

doc macro should be called and the description will be replaced by the corresponding doc.

Actual results

Could not render {{ doc("something") }}: 'doc' is undefined

Screenshots and log output

System information

The contents of your packages.yml file:

  - package: dbt-labs/dbt_utils
    version: 0.9.6
  - package: dbt-labs/dbt_external_tables
    version: 0.8.2
  - package: dbt-labs/metrics
    version: 1.3.1
  - package: elementary-data/elementary
    version: 0.7.4
  - package: brooklyn-data/dbt_artifacts
    version: 2.2.1
  - package: dbt-labs/dbt_project_evaluator
    version: 0.2.1

Which database are you using dbt with?

The output of dbt --version:

Core:
  - installed: 1.3.1
  - latest:    1.5.0 - Update available!

  Your version of dbt-core is out of date!
  You can find instructions for upgrading here:
  https://docs.getdbt.com/docs/installation

Plugins:
  - databricks: 1.3.2 - Update available!
  - spark:      1.3.1 - Update available!

  At least one plugin is out of date or incompatible with dbt-core.
  You can find instructions for upgrading here:
  https://docs.getdbt.com/docs/installation

The operating system you're using: MacOS

The output of python --version: Python 3.10.7

Additional context