I want to webscraping multiple urls and parse quick as possible but the for loop is not too faster for me, have a way to do this maybe with asynchronous or multiprocessing or multithreading?
import grequests
from bs4 import BeautifulSoup
links1 = [] #multiple links
while True:
try:
reqs = (grequests.get(link) for link in links1)
resp = grequests.imap(reqs, size=25, stream=False)
for r in resp: # I WANT TO RUN THIS FOR LOOP QUICK AS POSSIBLE ITS POSSIBLE?
soup = BeautifulSoup(r.text, 'lxml')
parse = soup.find('div', class_='txt')