diff --git a/chaineTV.py b/chaineTV.py index 6a473a1..223fd86 100644 --- a/chaineTV.py +++ b/chaineTV.py @@ -6,9 +6,9 @@ import webbrowser import urllib.request import re import io -from PIL import Image,ImageTk +from PIL import ImageTk from bs4 import BeautifulSoup -from tkinter import Label,Button,Frame,Tk,Entry,StringVar,LEFT,RIGHT,PhotoImage,Image,Scrollbar,VERTICAL,Canvas,Y,BOTH,NW +from tkinter import Label,Button,Frame,Tk,Entry,StringVar,LEFT,RIGHT,Scrollbar,VERTICAL,Canvas,Y,BOTH,NW @@ -239,10 +239,10 @@ def parse_emmission(URL): parse=BeautifulSoup(html,"html.parser") divcasting=parse.select_one(".descriptif") casting=divcasting.find_all(href=re.compile("biographie")) - i=0 + count=0 for actor in casting: casting[i]=actor.text - i+=1 + count+=1 divsynopsis=parse.select_one(".episode-synopsis") img=divsynopsis.find_next('img')['data-src'] synopsis=divsynopsis.select_one(".d-b").text