import requests from bs4 import BeautifulSoup r = requests.get(url) soup = BeautifulSoup(r.content, \'lxml\') image = soup.select_one(\'#productImage > li > a >