Open dmozh opened 8 months ago
Hi @dmozh, thanks for opening this issue and thanks for your kind words! Supporting asynchronous requests is absolutely something this library should support, especially given that httpx
supports this. It wasn't implemented from the start mostly due to a lack of knowledge of asynchronous Python on my end in all honesty.
I'd definitely be interested in a PR if you're able to spare the time, and will add async support to my roadmap for innertube
!
That good news!
I have already prepared changes and tests, but i cant to push them.
Awesome! To contribute your changes, you should be able to fork this repository, cut a branch on your fork with your changes, then open a PR from that branch into this repository.
GitHub has a guide on this here and DigitalOcean has a good write-up on this process too here. Hope that helps! :slightly_smiling_face:
Hi, thank for this lib, its amazing. I want to create wrapper for this lib to my custom sdk, but I noticed that innertube does not have an asynchronous interface. I have researched the code, and I see that httpx supports async interface with AsyncClient. After small modification (which not affect main codebase) i wrote async interface with usage AsyncClient which allows to work in async.
For example:
This sync client in async usage
and result
Here we see that event loop is blocked on every request, because every request is synchronous.
And example with async client
and result
So, what do you think about it? If you intresting, i can create PR with include async interface.