Feature: Add excluded_packages
configuration to prevent specific nested packages from being injected
#94
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description and Motivation
In some circumstances, a user may want to prevent a package imported into an upstream project from being injected into a downstream project. One example of this is
dbt_project_evaluator
, which provides valuable test results about project health and architectural soundness. It's not uncommon for teams to import thedbt_project_evaluator
package in all of their projects.Unfortunately,
dbt-core
's access control model is namespaced on project name and not lineage, soproject_b
will incidentally injectdbt_project_evaluator
models fromproject_a
despite the models being marked asprotected
.To work around this issue, this PR adds an
excluded_packages
configuration in theManifestReference
to informdbt-loom
to exclude all resources from a specific upstream project that come from a given package.For example, the follow configuration will exclude all
dbt_project_evaluator
resources from therevenue
project, clearing the way for this downstream project's version of the package.Resolves: #93