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

Add a HEAD method to DelayedRequester #1579

Closed
1 task
AetherUnbound opened this issue Sep 30, 2022 · 2 comments · Fixed by WordPress/openverse-catalog#865
Closed
1 task

Add a HEAD method to DelayedRequester #1579

AetherUnbound opened this issue Sep 30, 2022 · 2 comments · Fixed by WordPress/openverse-catalog#865
Assignees
Labels
💻 aspect: code Concerns the software code in the repository 🧰 goal: internal improvement Improvement that benefits maintainers, not users good first issue New-contributor friendly help wanted Open to participation from the community 🟨 priority: medium Not blocking but should be addressed soon 🐍 tech: python Involves Python

Comments

@AetherUnbound
Copy link
Collaborator

Description

The DelayedRequester has a lot of machinery around making requests & handling errors that would be useful for alternate request methods (such as HEAD or POST). We have a use-case for HEAD already in #1493.

I think an ideal implementation would have one request inner method that is wrapped by the various methods, e.g.:

def make_request(method, **kwargs):
    ...

def get(**kwargs):
    make_request(requests.get, **kwargs):

def head(**kwargs):
    make_request(requests.head, **kwargs):

...

Implementation

  • 🙋 I would be interested in implementing this feature.
@AetherUnbound AetherUnbound added 🐍 tech: python Involves Python 💻 aspect: code Concerns the software code in the repository 🟩 priority: low Low priority and doesn't need to be rushed 🧰 goal: internal improvement Improvement that benefits maintainers, not users labels Sep 30, 2022
@AetherUnbound AetherUnbound added good first issue New-contributor friendly help wanted Open to participation from the community labels Oct 19, 2022
@krysal krysal added 🟨 priority: medium Not blocking but should be addressed soon and removed 🟩 priority: low Low priority and doesn't need to be rushed labels Oct 27, 2022
@krysal
Copy link
Member

krysal commented Oct 27, 2022

Raising the priority to medium given this is blocking other issues.

@twstokes
Copy link
Contributor

twstokes commented Nov 9, 2022

👋 I'll try to implement this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💻 aspect: code Concerns the software code in the repository 🧰 goal: internal improvement Improvement that benefits maintainers, not users good first issue New-contributor friendly help wanted Open to participation from the community 🟨 priority: medium Not blocking but should be addressed soon 🐍 tech: python Involves Python
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants