Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bugfix/country-long-test-addition #16

Merged
merged 7 commits into from
Jun 21, 2023

Conversation

fivetran-joemarkiewicz
Copy link
Collaborator

@fivetran-joemarkiewicz fivetran-joemarkiewicz commented May 19, 2023

PR Overview

This PR will address the following Issue/Feature:

Issue #12 from the Apple Store package.

This PR will result in the following new package version: v0.3.1

This change is only adjusting a unique combination of columns test to capture the nuance of the source data. This will not be a breaking change for existing users.

Please detail what change(s) this PR introduces and any additional information that should be known during the review of this PR:

This PR adds the country_long field in the unique combination of columns test for the app_reporting__country_report. It has been identified that Google and Apple will sometimes provide records with different country_long names; however, they will be the same country_short. This is due to some countries having a multiple country_long spelling variations. Please see the issue linked above for an example of this scenario and why the test is needed to account for the source data nuance.

PR Checklist

Basic Validation

Please acknowledge that you have successfully performed the following commands locally:

  • dbt compile
  • dbt run –full-refresh
  • dbt run
  • dbt test
  • [n/a] dbt run –vars (if applicable)

Before marking this PR as "ready for review" the following have been applied:

  • The appropriate issue has been linked and tagged
  • You are assigned to the corresponding issue and this PR
  • BuildKite integration tests are passing

Detailed Validation

Please acknowledge that the following validation checks have been performed prior to marking this PR as "ready for review":

  • You have validated these changes and assure this PR will address the respective Issue/Feature.
  • You are reasonably confident these changes will not impact any other components of this package or any dependent packages.
  • You have provided details below around the validation steps performed to gain confidence in these changes.

To test these changes I ran the tests on our existing data and noticed the original test passed. This was as expected since we do not have any double countries in our data. That being said, I was able to modify some seed data to create a double record and saw the test pass as expected following the new entry.

Standard Updates

Please acknowledge that your PR contains the following standard updates:

  • Package versioning has been appropriately indexed in the following locations:
    • indexed within dbt_project.yml
    • indexed within integration_tests/dbt_project.yml
  • CHANGELOG has individual entries for each respective change in this PR
  • [n/a] README updates have been applied (if applicable)
  • [n/a] DECISIONLOG updates have been updated (if applicable)
  • [n/a] Appropriate yml documentation has been added (if applicable)

dbt Docs

Please acknowledge that after the above were all completed the below were applied to your branch:

  • docs were regenerated (unless this PR does not include any code or yml updates)

If you had to summarize this PR in an emoji, which would it be?

👯

@fivetran-joemarkiewicz
Copy link
Collaborator Author

This branch may be tested by using the following config in your local package.yml

packages:
  - git: https://github.com/fivetran/dbt_app_reporting.git
    revision: bugfix/country-long-test-addition
    warn-unpinned: false 

@fivetran-joemarkiewicz fivetran-joemarkiewicz marked this pull request as ready for review May 19, 2023 17:48
@fivetran-catfritz fivetran-catfritz self-assigned this Jun 20, 2023
@fivetran-catfritz fivetran-catfritz linked an issue Jun 20, 2023 that may be closed by this pull request
4 tasks
Copy link
Contributor

@fivetran-catfritz fivetran-catfritz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to recreate the test error, which was resolved with the new branch. I also tested Apple and Google individually, and I confirm their corresponding tests do not cause any issues. Lgtm!

CHANGELOG.md Outdated
Comment on lines 4 to 5
- Included the `country_long` field in the unique combination of columns test for the `app_reporting__country_report`. It has been identified that Apple will sometimes provide records with different country_long names; however, they will be the same country_short. This is due to some countries having multiple country_long spelling variations.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a quick note here--I updated the changelog to only mention Apple data since the Google data comes in only as a short code. We add in the long name later, so the same issue does not occur.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] Test fail on duplicate found
2 participants