Giter Site home page Giter Site logo

coursera-downloader's People

Contributors

serejkus avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

coursera-downloader's Issues

AttributeError: 'NoneType' object has no attribute 'strip'

Hi, Siddhartha.

Unfortunately I don't know python yet to help fix this error:

python coursera.py progfun-2012-001

Downloading progfun-2012-001 to coursera/functional-programming-principles-in-sala for [email protected]
Getting downloads list...
Logging in... Submitting form... Login successful!
Downloads list obtained!

### 1.getting started

*** 1. course introduction ***
File: 1.1-course-introduction.txt
Downloaded 0.00 / 0.00 MiB (100.00% at 6459 kbps)
File: 1.1-course-introduction.srt
Downloaded 0.00 / 0.00 MiB (100.00% at 8244 kbps)
File: 1.1-course-introduction.mp4
Downloaded 7.31 / 7.31 MiB (100.00% at 147 kbps)

*** 2. tools setup for linux ***
File: 1.2-tools-setup-for-linux.txt
Downloaded 0.01 / 0.01 MiB (100.00% at 13877 kbps)
File: 1.2-tools-setup-for-linux.srt
Traceback (most recent call last):
File "coursera.py", line 227, in
main()
File "coursera.py", line 219, in main
if c.downloadcontents() == -1:
File "coursera.py", line 183, in downloadcontents
ret = self.downloadfile(url, filename)
File "coursera.py", line 113, in downloadfile
total_size = int(response.info().getheader('Content-Length').strip())
AttributeError: 'NoneType' object has no attribute 'strip'

login form error

hi, login procedure return an error when try to submit form.
thanks

HTTP Error 400: Bad Request

Getting downloads list...
Logging in... Submitting form... Could not submit login form HTTP Error 400: Bad Request
Traceback (most recent call last):
File "coursera.py", line 66, in login
handle = urllib2.urlopen(req)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 437, in open
response = meth(req, response)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 550, in http_response
'http', request, response, code, msg, hdrs)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 475, in error
return self._call_chain(_args)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 409, in _call_chain
result = func(_args)
File "F:\Program Files (x86)\python2.7.9\lib\urllib2.py", line 558, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
HTTPError: HTTP Error 400: Bad Request

meet an error

โžœ coursera-downloader-master python coursera.py sna-002

Downloading sna-002 to ~/coursera/sna-002 for [email protected]
Getting downloads list...
Logging in... Submitting form...
Traceback (most recent call last):
File "coursera.py", line 222, in
main()
File "coursera.py", line 218, in main
c.downloadContents()
File "coursera.py", line 96, in downloadContents
data = self.getDownloadData()
File "coursera.py", line 69, in getDownloadData
self.login()
File "coursera.py", line 52, in login
raise Exception("Could not submit login form: "+e.reason)
AttributeError: 'HTTPError' object has no attribute 'reason'

And then I printed out e.code.
e.code == 403

Is there any ways to solve this problem?
Thank you very much for your work.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.