Chillee / coursera-dl-all

MIT License
190 stars 54 forks source link

Sidebar title with forward slash causes IOError #2

Closed joshuawn closed 8 years ago

joshuawn commented 8 years ago

As I'm currently unable to test any commits you've made since last night because I'm visiting family, I was wondering if you could look into the following crash for hetero-004 with the "Home / Announcements" sidebar link and see if your new code properly handles it.

Here's the error code using the previous night's codebase:

Traceback (most recent call last):
  File "dl_all.py", line 249, in <module>
    download_sidebar_pages(session)
  File "dl_all.py", line 190, in download_sidebar_pages
    render(session, os.getcwd()+'/'+i[1])
  File "dl_all.py", line 33, in render
    f = open(path+'.html', 'w')
IOError: [Errno 2] No such file or directory: u'/home/joshuawn/Desktop/coursera-dl-all/coursera-downloads/hetero-004/Home / Announcements.html'
Chillee commented 8 years ago

Fixed in some older commit.