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

🐛 Source Facebook Marketing: Removed validation that blocked personal ad accounts during check #32731

Merged

Conversation

tolik0
Copy link
Contributor

@tolik0 tolik0 commented Nov 22, 2023

What

Removed the validation that previously blocked personal ad accounts during the 'check' process.

How

Deleted the validation step for personal accounts and replaced it with a procedure to retrieve information about the ad account to validate credentials.

🚨 User Impact 🚨

This change allows users with personal accounts to use the Facebook Marketing connector.

Copy link

vercel bot commented Nov 22, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
airbyte-docs ⬜️ Ignored (Inspect) Visit Preview Nov 23, 2023 11:31am

@octavia-squidington-iii octavia-squidington-iii added area/connectors Connector related issues area/documentation Improvements or additions to documentation labels Nov 22, 2023
Copy link
Contributor

github-actions bot commented Nov 22, 2023

Before Merging a Connector Pull Request

Wow! What a great pull request you have here! 🎉

To merge this PR, ensure the following has been done/considered for each connector added or updated:

  • PR name follows PR naming conventions
  • Breaking changes are considered. If a Breaking Change is being introduced, ensure an Airbyte engineer has created a Breaking Change Plan.
  • Connector version has been incremented in the Dockerfile and metadata.yaml according to our Semantic Versioning for Connectors guidelines
  • You've updated the connector's metadata.yaml file any other relevant changes, including a breakingChanges entry for major version bumps. See metadata.yaml docs
  • Secrets in the connector's spec are annotated with airbyte_secret
  • All documentation files are up to date. (README.md, bootstrap.md, docs.md, etc...)
  • Changelog updated in docs/integrations/<source or destination>/<name>.md with an entry for the new version. See changelog example
  • Migration guide updated in docs/integrations/<source or destination>/<name>-migrations.md with an entry for the new version, if the version is a breaking change. See migration guide example
  • If set, you've ensured the icon is present in the platform-internal repo. (Docs)

If the checklist is complete, but the CI check is failing,

  1. Check for hidden checklists in your PR description

  2. Toggle the github label checklist-action-run on/off to re-run the checklist CI.

@tolik0 tolik0 marked this pull request as ready for review November 22, 2023 14:33
@tolik0 tolik0 requested a review from a team November 22, 2023 14:33
@octavia-squidington-iv octavia-squidington-iv requested a review from a team November 22, 2023 14:34
)
return False, message
# Get Ad Account to check creds
ad_account = api.account
Copy link
Collaborator

Choose a reason for hiding this comment

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

isn't api.account a lazy attribute? if it is, let's add a small unit test for this change because if we'll somehow drop the log line, we can miss connectivity check at all

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Based on our tests and the documentation, the lazy property is indeed evaluated on first access. I've added a test to ensure that credentials validation is consistently checked.

cached_property docs:

The cached_property decorator only runs on lookups and only when an attribute of the same name doesn’t exist. When it does run, the cached_property writes to the attribute with the same name. Subsequent attribute reads and writes take precedence over the cached_property method and it works like a normal attribute.

@tolik0 tolik0 self-assigned this Nov 23, 2023
@tolik0 tolik0 merged commit d81ae88 into dev Nov 23, 2023
27 of 29 checks passed
@tolik0 tolik0 deleted the tolik0/source-facebook-marketing/delete-personal-account-check branch November 23, 2023 13:19
git-phu pushed a commit that referenced this pull request Nov 28, 2023
git-phu pushed a commit that referenced this pull request Nov 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants