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

support for BatchHttpRequest #15

Open
thehesiod opened this issue Jan 12, 2020 · 6 comments
Open

support for BatchHttpRequest #15

thehesiod opened this issue Jan 12, 2020 · 6 comments
Labels
feature New feature or request

Comments

@thehesiod
Copy link

No description provided.

@omarryhan omarryhan added the feature New feature or request label Jan 13, 2020
@omarryhan
Copy link
Owner

omarryhan commented Sep 12, 2020

Right now BatchHttpRequest is not implemented. The way I plan to do implement it is using the Request.batch_requests class method in the Request class.

It would look something like this:

resp1, resp2 = await aiogoogle.as_user(
  Request.batch_requests(
    youtube_v3.videos.search(q="first"),
    youtube_v3.videos.search(q="second")
  )
)

After implementing the batch_requests functionality, we must make the aiogoogle sessions understand the BatchRequest object that we just created. So, tweaking the send method will be necessary.

Updates:

  • Batch requests should have max 1000 requests per batch as per Google
  • None of the requests in a batch can use media upload as per Google

@omarryhan
Copy link
Owner

I'm open to merging pull requests if you're up for the task @kshilov

@thehesiod
Copy link
Author

I ended up creating my own version of async google api that replaces the sync functionality in the core google apis, will close. I've been working to try to open source it, hopefully soon

@omarryhan
Copy link
Owner

Cool, let's keep this issue open until we've landed this feature

@omarryhan omarryhan reopened this Sep 16, 2020
@sumankn314e
Copy link

@omarryhan when can we expect this to be implemented? Since it's more than 3 years already

@omarryhan
Copy link
Owner

Hey @sumankn314e I'm currently only maintaining the current features provided and I have no plans to add more features. However, I'd be happy to review your work and merge it in if you're interested in adding this feature

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

No branches or pull requests

4 participants
@thehesiod @omarryhan @sumankn314e and others