I'm trying to get a inner text inside of a html tag with bs4 but i'm not familiar with the library. would be appreciated you guys help me .
html:
<span class="course-time"> Duration<i> 3:1:00 </i></span>
for example I'm using this code to get the text inside of i tag:
duration = soup.findAll("span" , attrs = {"class" : {"course-time"}})[0].decode_contents()
when I use this code, i get the text but with i tag.
i just want the text.
how can i do so?