TGTGInsighttelegram intelligenceLIVE / telegram public index
← djangoproject
djangoproject avatar

TGINSIGHT POST

Post #196

@djangoproject

djangoproject

Views89Post view count
PostedNov 2811/28/2016, 03:42 AM
Post content

Post content

http://asyncio.readthedocs.io/en/latest/webscraper.html #Web#scraping means downloading multiple web pages, often from different #servers. Typically, there is a considerable waiting time between sending a request and receiving the answer. Using a client that always waits for the server to answer before sending the next request, can lead to spending most of time waiting. Here asyncio can help to send many requests without waiting for a response and collecting the answers later. The following examples show how a synchronous client spends most of the time waiting and how to use asyncio to write asynchronous client that can handle many requests concurrently.