in prompts/khanacademy/khan_dl/khan_dl.py [0:0]
def get_course_unit_urls(self):
"""Retrieves course unit urls"""
self.course_unit_urls = []
self.nested_courses = []
for url in self.course_page.find_all(attrs=COURSE_UNIT_TITLE):
if int(url["href"].count("/")) > 2:
self.course_unit_urls.append(url["href"])
else:
self.nested_courses.append(url["href"])
logging.debug("course_unit_urls:{}".format(self.course_unit_urls))
logging.debug("nested_courses:{}".format(self.nested_courses))
logging.info("Course unit urls retrieved")