Easy Concurrency

Passing an array of links

You can pass an array/iterator of links to the request methods to send them concurrently:

>>> hrequests.get(['https://google.com/', 'https://github.com/'])
(<Response [200]>, <Response [200]>)

This wraps around hrequests.map.


This also works with nohup:

>>> resps = hrequests.get(['https://google.com/', 'https://github.com/'], nohup=True)
>>> resps
(<LazyResponse[Pending]>, <LazyResponse[Pending]>)
>>> # Sometime later...
>>> resps
(<Response [200]>, <Response [200]>)

Last updated