Skip to content

Commit

Permalink
Use all supported_resource_types by default (#19)
Browse files Browse the repository at this point in the history
* Use all supported_resource_types by default

Signed-off-by: Robert Astel <rob.astel@gmail.com>

* Handle mutual exclusivity between resource_type and model arguments

Signed-off-by: Robert Astel <rob.astel@gmail.com>

* Pin MarkupSafe==2.0.1 for dbt-core<1.0.0 due to dbt-labs/dbt-core#4745

Signed-off-by: Robert Astel <rob.astel@gmail.com>
  • Loading branch information
robastel committed Feb 21, 2022
1 parent 77cce0d commit 7975db2
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions dbt_invoke/internal/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,9 @@ def dbt_ls(
default_arguments = list()
if not any(resource_selection_arguments.values()):
default_arguments.append(f'--select {ctx.config["project_name"]}')
# Use all supported_resource_types unless a resource_type or models
# kwarg is given
if not kwargs.get('resource_type') and not kwargs.get('models'):
if supported_resource_types:
for rt in supported_resource_types:
default_arguments.append(f'{get_cli_kwargs(resource_type=rt)}')
Expand Down
2 changes: 1 addition & 1 deletion dbt_invoke/internal/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '0.1.4'
__version__ = '0.1.5'
1 change: 1 addition & 0 deletions requirements/requirements_dbt_0.18.x.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ cryptography<3
dbt-core~=0.18.0
dbt-sqlite~=0.0.4
invoke>=1.4.1
MarkupSafe==2.0.1
PyYAML>=5.1
pyopenssl<20.0.0
pytz<2021.0
Expand Down
1 change: 1 addition & 0 deletions requirements/requirements_dbt_0.19.x.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ agate<1.6.2
dbt-core~=0.19.0
dbt-sqlite~=0.1.0
invoke>=1.4.1
MarkupSafe==2.0.1
pytz<2021.0
PyYAML>=5.1
-e .
1 change: 1 addition & 0 deletions tests/test_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ expected_dbt_ls_results:
- *orders
exclude:
customers:
- *revenue_by_daily_cohort
- *orders
- *items
- *items_snapshot
Expand Down

0 comments on commit 7975db2

Please sign in to comment.