Добрый вечер, помогите. Выдает ошибку prox = bs.find("table").find("tbody").find_all("tr")
AttributeError: 'NoneType' object has no attribute 'find'
import requests
from bs4 import BeautifulSoup
def html(urls):
r = requests.get(urls)
return r.text
def html_proxy(htmle):
bs = BeautifulSoup(htmle, 'lxml')
prox = bs.find("table").find("tbody").find_all("tr")
for i in prox:
a = i.find_all('td')
ip = a[0].text
port = a[1].text
data = {
'ip':ip,
'port':port
}
print(data)
def main():
url = "https://hidemy.name/ru/proxy-list/"
html_proxy(html(url))
if __name__ == "__main__":
main()