Skip to content

Commit

Permalink
Cleaning up legacy behavior section (#5071)
Browse files Browse the repository at this point in the history
## What are you changing in this pull request and why?

Cleaning up the legacy behavior source freshness section

## Checklist
<!--
Uncomment when publishing docs for a prerelease version of dbt:
- [ ] Add versioning components, as described in [Versioning
Docs](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-entire-pages)
- [ ] Add a note to the prerelease version [Migration
Guide](https://github.com/dbt-labs/docs.getdbt.com/tree/current/website/docs/docs/dbt-versions/core-upgrade)
-->
- [ ] Review the [Content style
guide](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/content-style-guide.md)
so my content adheres to these guidelines.
- [ ] For [docs
versioning](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#about-versioning),
review how to [version a whole
page](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#adding-a-new-version)
and [version a block of
content](https://github.com/dbt-labs/docs.getdbt.com/blob/current/contributing/single-sourcing-content.md#versioning-blocks-of-content).
- [ ] Add a checklist item for anything that needs to happen before this
PR is merged, such as "needs technical review" or "change base branch."

Adding or removing pages (delete if not applicable):
- [ ] Add/remove page in `website/sidebars.js`
- [ ] Provide a unique filename for new pages
- [ ] Add an entry for deleted pages in `website/vercel.json`
- [ ] Run link testing locally with `npm run build` to update the links
that point to deleted pages
  • Loading branch information
matthewshaver authored Mar 13, 2024
2 parents 33e1ac0 + 30160df commit 0551e80
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions website/docs/reference/global-configs/legacy-behaviors.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,17 @@ These flags can _only_ be set in `dbt_project.yml`. They configure behaviors clo
## Behaviors

### `source_freshness_run_project_hooks`
- Should the 'dbt source freshness' command include [on-run-start / on-run-end hooks](/reference/project-configs/on-run-start-on-run-end)?
- Planned introduction in v1.8, with default 'True'
- Planned removal in v1.9

If you have specific project `on-run-start` / `on-run-end` hooks that should not run before/after `source freshness` command, you can add a conditional check to those hooks:
```yaml
# dbt_project.yml
If you have specific project [`on-run-start` / `on-run-end`](/reference/project-configs/on-run-start-on-run-end) hooks that should not run before/after `source freshness` command, you can add a conditional check to those hooks:

<File name='dbt_project.yml'>

```yaml
on-run-start:
- '{{ ... if flags.WHICH != 'freshness' }}'
```
</File>
You can configure the `dbt source freshness` command to include on-run-start / on-run-end hooks in v1.8 with a planned removal in v1.9. The default value is `True`.

In the meantime, you can set `source_freshness_run_project_hooks: False` to preserve the legacy behavior.

0 comments on commit 0551e80

Please sign in to comment.