NavpreetDevpuri / LyndaDownloader

Python script for downloading video courses from Lynda.com.
23 stars 5 forks source link

Im getting a new issue - KeyError: 'content-length' #7

Closed sim44m closed 3 years ago

sim44m commented 3 years ago

Getting error while downloading a learning path https://www.lynda.com/learning-paths/IT/become-an-ethical-hacker

11. Ethical Hacking Evading IDS Firewalls and Honeypots (1h 52m)

`Downloading...

  1. Introduction: [540p: 3.4Mb] 1. Find weaknesses in the perimeter (1m 37s).mp4 [540p: 0.9Mb] 2. What you should know (43s).mp4 [540p: 1.49Mb] 3. Course disclaimer (1m 10s).mp4
  2. Firewalls: [540p: 1.31Mb] 1. Understanding Firewalls (1m 2s).mp4 [540p: 10.4Mb] 2. Apply the basics of the Windows firewall (5m 17s).mp4 [540p: 14.58Mb] 3. Use advanced features in the Windows Firewall (8m 18s).mp4 [540p: 6.02Mb] 4. Review firewall logs (3m 22s).mp4 [540p: 7.16Mb] 5. Understand Linux IPTables (4m 14s).mp4 [540p: 4.68Mb] 6. Set up an IPTables firewall (2m 52s).mp4 [540p: 12.45Mb] 7. Manage rules with Firewall Builder (8m 24s).mp4 [540p: 1.45Mb] 8. Port testing (1m 7s).mp4
  3. Hardware Firewalls: [540p: 5.91Mb] 1. Set up a Cisco PIX firewall (3m 15s).mp4 100.00% (5.91Mb/5.91Mb) Allover:53.93% (109.62Mb/203.27Mb)
    Traceback (most recent call last): File "/content/LyndaDownloader/LyndaDownloaderLearningPaths.py", line 412, in download() File "/content/LyndaDownloader/LyndaDownloaderLearningPaths.py", line 136, in download 'https://www.lynda.com/ajax/player/transcript?courseId=' + courseId + '&videoId=' + data[i][1][j][1][0], header=h, showOutput=False) File "/content/LyndaDownloader/LyndaDownloaderLearningPaths.py", line 160, in dowloadFile size = int(r.headers['Content-length']) File "/usr/local/lib/python3.6/dist-packages/requests/structures.py", line 54, in getitem return self._store[key.lower()][1] KeyError: 'content-length'`
NavpreetDevpuri commented 3 years ago

It seems like a network error.

NavpreetDevpuri commented 3 years ago

did you try again?

sim44m commented 3 years ago

Well yeah, it still persisted the last time I tried, well will try again tomorrow.

On Sun, Jan 24, 2021, 20:11 Navpreet Singh Devpuri notifications@github.com wrote:

did you try again?

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/NavpreetDevpuri/LyndaDownloader/issues/7#issuecomment-766358785, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASQCK3D3TNUCIV6QKBXGM6DS3QWQRANCNFSM4WG5YFIQ .