Skip to content

Commit

Permalink
Merge pull request #14 from fivetran/bugfix/persist_docs_max_length
Browse files Browse the repository at this point in the history
update field descriptions
  • Loading branch information
fivetran-reneeli authored Jul 26, 2023
2 parents bf2cd66 + 8b17ba5 commit 05ad8ef
Show file tree
Hide file tree
Showing 12 changed files with 43 additions and 41 deletions.
3 changes: 2 additions & 1 deletion .buildkite/hooks/pre-command
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ export CI_SNOWFLAKE_DBT_USER=$(gcloud secrets versions access latest --secret="C
export CI_SNOWFLAKE_DBT_WAREHOUSE=$(gcloud secrets versions access latest --secret="CI_SNOWFLAKE_DBT_WAREHOUSE" --project="dbt-package-testing-363917")
export CI_DATABRICKS_DBT_HOST=$(gcloud secrets versions access latest --secret="CI_DATABRICKS_DBT_HOST" --project="dbt-package-testing-363917")
export CI_DATABRICKS_DBT_HTTP_PATH=$(gcloud secrets versions access latest --secret="CI_DATABRICKS_DBT_HTTP_PATH" --project="dbt-package-testing-363917")
export CI_DATABRICKS_DBT_TOKEN=$(gcloud secrets versions access latest --secret="CI_DATABRICKS_DBT_TOKEN" --project="dbt-package-testing-363917")
export CI_DATABRICKS_DBT_TOKEN=$(gcloud secrets versions access latest --secret="CI_DATABRICKS_DBT_TOKEN" --project="dbt-package-testing-363917")
export CI_DATABRICKS_DBT_CATALOG=$(gcloud secrets versions access latest --secret="CI_DATABRICKS_DBT_CATALOG" --project="dbt-package-testing-363917")
1 change: 1 addition & 0 deletions .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,5 +69,6 @@ steps:
- "CI_DATABRICKS_DBT_HOST"
- "CI_DATABRICKS_DBT_HTTP_PATH"
- "CI_DATABRICKS_DBT_TOKEN"
- "CI_DATABRICKS_DBT_CATALOG"
commands: |
bash .buildkite/scripts/run_models.sh databricks
10 changes: 7 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# dbt_apple_store v0.UPDATE.UPDATE
# dbt_apple_store v0.3.1

This package version includes the following updates:
## Bug Fix
- Shortened the field description for `source_type`. This was causing an error if the persist docs config was enabled because the description size exceeded warehouse constraints. This was updated upstream in the dbt_apple_store_source package ([PR #11](https://github.com/fivetran/dbt_apple_store_source/pull/11))

## Under the Hood:
[PR #13](https://github.com/fivetran/dbt_apple_store/pull/13) includes the following changes:
- Added rows to seed data `app_store_territory_source_type` to test for countries with variant spellings in the `territory` column.
- Added rows to seed data `app_store_territory_source_type` to test for countries with variant spellings in the `territory` column ([PR #13](https://github.com/fivetran/dbt_apple_store/pull/13))
- Removed/added fields in the yml file ([PR #14](https://github.com/fivetran/dbt_apple_store/pull/14))

# dbt_apple_store v0.3.0

Expand Down
2 changes: 1 addition & 1 deletion dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'apple_store'
version: '0.3.0'
version: '0.3.1'
config-version: 2
require-dbt-version: [">=1.3.0", "<2.0.0"]
vars:
Expand Down
2 changes: 1 addition & 1 deletion docs/catalog.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/manifest.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/run_results.json

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion integration_tests/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
target/
dbt_modules/
logs/
.DS_Store
.DS_Store
env/
12 changes: 6 additions & 6 deletions integration_tests/ci/sample.profiles.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ integration_tests:
pass: "{{ env_var('CI_REDSHIFT_DBT_PASS') }}"
dbname: "{{ env_var('CI_REDSHIFT_DBT_DBNAME') }}"
port: 5439
schema: apple_store_integration_tests_1
schema: apple_store_integration_tests_6
threads: 8
bigquery:
type: bigquery
method: service-account-json
project: 'dbt-package-testing'
schema: apple_store_integration_tests_1
schema: apple_store_integration_tests_6
threads: 8
keyfile_json: "{{ env_var('GCLOUD_SERVICE_KEY') | as_native }}"
snowflake:
Expand All @@ -33,7 +33,7 @@ integration_tests:
role: "{{ env_var('CI_SNOWFLAKE_DBT_ROLE') }}"
database: "{{ env_var('CI_SNOWFLAKE_DBT_DATABASE') }}"
warehouse: "{{ env_var('CI_SNOWFLAKE_DBT_WAREHOUSE') }}"
schema: apple_store_integration_tests_1
schema: apple_store_integration_tests_6
threads: 8
postgres:
type: postgres
Expand All @@ -42,13 +42,13 @@ integration_tests:
pass: "{{ env_var('CI_POSTGRES_DBT_PASS') }}"
dbname: "{{ env_var('CI_POSTGRES_DBT_DBNAME') }}"
port: 5432
schema: apple_store_integration_tests_1
schema: apple_store_integration_tests_6
threads: 8
databricks:
catalog: null
catalog: "{{ env_var('CI_DATABRICKS_DBT_CATALOG') }}"
host: "{{ env_var('CI_DATABRICKS_DBT_HOST') }}"
http_path: "{{ env_var('CI_DATABRICKS_DBT_HTTP_PATH') }}"
schema: apple_store_integration_tests_1
schema: apple_store_integration_tests_6
threads: 2
token: "{{ env_var('CI_DATABRICKS_DBT_TOKEN') }}"
type: databricks
11 changes: 8 additions & 3 deletions integration_tests/dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
config-version: 2

name: 'apple_store_integration_tests'
version: '0.3.0'
version: '0.3.1'

profile: 'integration_tests'
profile: 'integration_tests'

vars:
apple_store_schema: apple_store_integration_tests_1
apple_store_schema: apple_store_integration_tests_6
apple_store__using_subscriptions: True
apple_store_source:
app_identifier: "app"
Expand All @@ -31,6 +31,11 @@ vars:
- 'Cancel'
- 'Subscribe'

models:
+persist_docs:
relation: "{{ false if target.type in ('spark','databricks') else true }}"
columns: "{{ false if target.type in ('spark','databricks') else true }}"

seeds:
apple_store_integration_tests:
+quote_columns: "{{ true if target.type == 'redshift' else false }}"
Expand Down
32 changes: 13 additions & 19 deletions models/apple_store.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,24 @@ models:
description: '{{ doc("app_name") }}'
- name: subscription_name
description: '{{ doc("subscription_name") }}'
- name: country_name
description: '{{ doc("country_name") }}'
- name: territory_long
description: '{{ doc("territory_long") }}'
- name: territory_short
description: '{{ doc("country") }}'
- name: region
description: '{{ doc("region") }}'
- name: sub_region
description: '{{ doc("sub_region") }}'
- name: territory_long
description: '{{ doc("territory_long") }}'
- name: state
description: '{{ doc("state") }}'
- name: active_free_trial_introductory_offer_subscriptions
description: '{{ doc("active_free_trial_introductory_offer_subscriptions") }}'
- name: active_pay_as_you_go_introductory_offer_subscriptions
description: '{{ doc("active_pay_as_you_go_introductory_offer_subscriptions") }}'
- name: active_pay_up_front_introductory_offer_subscriptions
description: '{{ doc("active_pay_up_front_introductory_offer_subscriptions") }}'
- name: active_standard_price_subscriptions
description: '{{ doc("active_standard_price_subscriptions") }}'

- name: apple_store__territory_report
description: Each record represents daily subscription metrics by app_id, source_type and territory
Expand All @@ -58,7 +66,7 @@ models:
- name: territory_long
description: '{{ doc("territory_long") }}'
- name: territory_short
description: '{{ doc("territory_short") }}'
description: '{{ doc("country") }}'
- name: region
description: '{{ doc("region") }}'
- name: sub_region
Expand Down Expand Up @@ -275,20 +283,6 @@ models:
description: '{{ doc("app_version") }}'
- name: crashes
description: '{{ doc("crashes") }}'
- name: impressions
description: '{{ doc("impressions") }}'
- name: impressions_unique_device
description: '{{ doc("impressions_unique_device") }}'
- name: page_views
description: '{{ doc("page_views") }}'
- name: page_views_unique_device
description: '{{ doc("page_views_unique_device") }}'
- name: first_time_downloads
description: '{{ doc("first_time_downloads") }}'
- name: redownloads
description: '{{ doc("redownloads") }}'
- name: total_downloads
description: '{{ doc("total_downloads") }}'
- name: active_devices
description: '{{ doc("active_devices") }}'
- name: active_devices_last_30_days
Expand Down
4 changes: 0 additions & 4 deletions models/docs.md

This file was deleted.

0 comments on commit 05ad8ef

Please sign in to comment.