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

Switch from zdesk to zenpy in ZendeskHook #21349

Merged
merged 4 commits into from
Feb 6, 2022

Conversation

pierrejeambrun
Copy link
Member

@pierrejeambrun pierrejeambrun commented Feb 5, 2022

closes: #8937

This pull request changes ZendeskHook to use zenpy package instead of zdesk.

I tried to introduce as little breaking changes as possible. We keep the ability to make 'custom' get request via the call method.

Starting from here we can then add specific methods for each resource using dedicated zenpy APIs. (accessible trough zenpy's client e.g: users, tickets, organizations etc.). But I think this goes beyond the scope of this PR.

Let me know what you think.

Note: Zenpy is now taking care of the rate limiting for us

@pierrejeambrun pierrejeambrun force-pushed the 8937-switch-zdesk-to-zenpy branch from e2e031c to b012842 Compare February 5, 2022 23:25
Copy link
Contributor

@eladkal eladkal left a comment

Choose a reason for hiding this comment

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

over all LGTM
left some comments to address

airflow/providers/zendesk/CHANGELOG.rst Outdated Show resolved Hide resolved
airflow/providers/zendesk/hooks/zendesk.py Outdated Show resolved Hide resolved
airflow/providers/zendesk/hooks/zendesk.py Outdated Show resolved Hide resolved
@pierrejeambrun
Copy link
Member Author

pierrejeambrun commented Feb 6, 2022

@eladkal Thank you for your review.

I updated the PR accordingly and added the ticket resource as an example. I tested all the methods, it's working fine.

For now the hook is just a wrapper around zenpy and is not doing much but we could imagine more sophisticated use case.

Copy link
Contributor

@eladkal eladkal left a comment

Choose a reason for hiding this comment

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

just one little comment
after that we are good to merge

airflow/providers/zendesk/hooks/zendesk.py Outdated Show resolved Hide resolved
@github-actions github-actions bot added the full tests needed We need to run full set of tests for this PR to merge label Feb 6, 2022
@github-actions
Copy link

github-actions bot commented Feb 6, 2022

The PR most likely needs to run full matrix of tests because it modifies parts of the core of Airflow. However, committers might decide to merge it quickly and take the risk. If they don't merge it quickly - please rebase it to the latest main at your convenience, or amend the last commit of the PR, and push it with --force-with-lease.

@potiuk
Copy link
Member

potiuk commented Feb 6, 2022

You should also update provider.yaml for zendesk to set the 3.0.0 version :).

@pierrejeambrun
Copy link
Member Author

@potiuk thank you, I just updated it :)

@potiuk
Copy link
Member

potiuk commented Feb 6, 2022

Just docker-tests failing (which we need to fix). merging.

@potiuk potiuk merged commit 1d170f8 into apache:main Feb 6, 2022
@pierrejeambrun pierrejeambrun deleted the 8937-switch-zdesk-to-zenpy branch February 6, 2022 21:48
@eladkal
Copy link
Contributor

eladkal commented Feb 6, 2022

thanks @pierrejeambrun !

@jedcunningham jedcunningham added the changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) label Mar 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:providers changelog:skip Changes that should be skipped from the changelog (CI, tests, etc..) full tests needed We need to run full set of tests for this PR to merge kind:documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

change from zdesk to zenpy in ZendeskHook
4 participants