from bs4 import BeautifulSoup def main(): html = open('index.html').read() soup = BeautifulSoup(html, 'lxml') find = soup.find(class_="animace") print(find) if __name__ == '__main__': main() Код from bs4 import BeautifulSoup def main(): html = open('index.html').read() soup = BeautifulSoup(html, 'lxml') find = soup.find(class_="animace") print(find) if __name__ == '__main__': main()
Точно не помню , но сделай find = soup.find(class_="animace").text Код find = soup.find(class_="animace").text