-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Open
Labels
Description
Is this your first time submitting a feature request?
- I have read the expectations for open source contributors
- I have searched the existing issues, and I could not find an existing issue for this feature
- I am requesting a straightforward extension of existing dbt functionality, rather than a Big Idea better suited to a discussion
Describe the feature
Hi all, please correct me if I'm wrong, but I believe it's currently not possible to disable on-run-start
and on-run-end
hooks defined in packages installed as dependencies. E.g. elementary
defines such hooks and they have implemented custom variables to disable them:
https://docs.elementary-data.com/oss/general/faq#can-i-disable-the-on-run-end-hooks-or-results-uploading
but it should be possible to achieve without special logic in the upstream package.
Ofc we can always disable the whole package with +enabled: false
, but it's not the real solution.
To reproduce:
-
- create
package_a
- in
pyproject.toml
defineon-run-end: "{{ print('foo') }}"
- create
-
- create
package_b
- install
package_a
as dependency - in
pyproject.toml
defineon-run-end: "{{ print('bar') }}"
- run e.g.
dbt compile
- notice both
foo
andbar
are printed in logs
- create
amirbtb, mahiki, maj6111, DT-jd, Osminkin and 2 more