Skip to content

Commit

Permalink
Merge 361d6ba into 39cca97
Browse files Browse the repository at this point in the history
  • Loading branch information
arnebef committed Apr 5, 2018
2 parents 39cca97 + 361d6ba commit 2a371cb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions edx_dl/edx_dl.py
Original file line number Diff line number Diff line change
Expand Up @@ -1019,12 +1019,11 @@ def main():
_display_selections(selections)

# Extract the unit information (downloadable resources)
# This parses the HTML of all the subsection.url and extracts
# This parses the HTML of one page in each section and extracts
# the URLs of the resources as Units.
all_urls = [subsection.url
all_urls = [selected_section.subsections[0].url
for selected_sections in selections.values()
for selected_section in selected_sections
for subsection in selected_section.subsections]
for selected_section in selected_sections]

extractor = extract_all_units_in_parallel
if args.sequential:
Expand Down
2 changes: 1 addition & 1 deletion edx_dl/parsing.py
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ def _make_url(section_soup): # FIXME: Extract from here and test

def _get_section_name(section_soup): # FIXME: Extract from here and test
try:
return section_soup.button.h3.string.strip()
return section_soup.find('span',class_='subsection-title').string.strip()
except AttributeError:
return None

Expand Down

0 comments on commit 2a371cb

Please sign in to comment.