Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demonstrate and explain config meta key nesting #3710

Open
1 task done
dbeatty10 opened this issue Jul 11, 2023 · 0 comments
Open
1 task done

Demonstrate and explain config meta key nesting #3710

dbeatty10 opened this issue Jul 11, 2023 · 0 comments
Labels
content Improvements or additions to content improvement Use this when an area of the docs needs improvement as it's currently unclear

Comments

@dbeatty10
Copy link
Contributor

dbeatty10 commented Jul 11, 2023

Contributions

  • I have read the contribution docs, and understand what's expected of me.

Link to the page on docs.getdbt.com requiring updates

https://docs.getdbt.com/reference/resource-configs/meta

What part(s) of the page would you like to see updated?

1. Update examples in meta docs

We want to update all the examples within the meta docs to nest the meta key under the config key in the all right places.

2. Update "general configurations" examples for each resource type

Not all of the following pages includes the usage of meta underneath the Project file, Property file and Config block tabs:

i.e., Both snapshots and sources need to have meta added to all the relevant tabs, but the rest of the resource types have meta included already.

Side note: these resource types don't have config documentation pages, and meta may or may not be relevant for each:

3. Add more explanation

In order for meta dictionaries to merge with a more specific key-value pair replacing a less specific value with the same key:

  • For all* resource types in _properties.yml files:
    • put meta under config:
      config:
          meta:
              ...
  • Within dbt_project.yml don't use config:
    • use a top-level meta key instead.

* For models only - meta also works as a top-level key (but better to use consistent syntax across resource types).

Additional information

For some background, see here (and the preceding thread).

See also:

@dbeatty10 dbeatty10 added content Improvements or additions to content improvement Use this when an area of the docs needs improvement as it's currently unclear labels Jul 11, 2023
mirnawong1 added a commit that referenced this issue Aug 22, 2023
[Preview](https://deploy-preview-3954--docs-getdbt-com.netlify.app/reference/resource-configs/meta)

## What are you changing in this pull request and why?

This PR is related to
#3710. It handles the
"update examples" part but doesn't handle the "add more explanation"
part.

It fixes two things in particular:
1. Aligns the example for `sources` with the recommended usage (that is
most likely to behave correctly)
1. Removes part of the example for `macros` that raises a Parsing Error

## Checklist
- [x] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
and [About
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
so my content adheres to these guidelines.
@dbeatty10 dbeatty10 changed the title Demonstrate and explain and config meta key nesting Demonstrate and explain config meta key nesting Oct 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Improvements or additions to content improvement Use this when an area of the docs needs improvement as it's currently unclear
Projects
None yet
Development

No branches or pull requests

1 participant