Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to parse JSON on Lynda.com #20513

Closed
Bewinxed opened this issue Mar 31, 2019 · 1 comment
Closed

Failed to parse JSON on Lynda.com #20513

Bewinxed opened this issue Mar 31, 2019 · 1 comment

Comments

@Bewinxed
Copy link

@Bewinxed Bewinxed commented Mar 31, 2019

Please follow the guide below

  • You will be asked some questions and requested to provide some information, please read them carefully and answer honestly
  • Put an x into all the boxes [ ] relevant to your issue (like this: [x])
  • Use the Preview tab to see what your issue will actually look like

Make sure you are using the latest version: run youtube-dl --version and ensure your version is 2019.03.18. If it's not, read this FAQ entry and update. Issues with outdated version will be rejected.

  • I've verified and I assure that I'm running youtube-dl 2019.03.18

Before submitting an issue make sure you have:

  • At least skimmed through the README, most notably the FAQ and BUGS sections
  • Searched the bugtracker for similar issues including closed ones
  • Checked that provided video/audio/playlist URLs (if any) are alive and playable in a browser

What is the purpose of your issue?

  • Bug report (encountered problems with youtube-dl)
  • Site support request (request for adding support for a new site)
  • Feature request (request for a new functionality)
  • Question
  • Other

The following sections concretize particular purposed issues, you can erase any section (the contents between triple ---) not applicable to your issue


If the purpose of this issue is a bug report, site support request or you are not completely sure provide the full verbose output as follows:

Add the -v flag to your command line you run youtube-dl with (youtube-dl -v <your command line>), copy the whole output and insert it here. It should look similar to one below (replace it with your log inserted between triple ```):

youtube-dl --cookies cookies.txt "https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289-2.html" -o "Lynda.com - %(playlist)s/%(chapter_number)s - %(chapter)s/%(playlist_index)s - %(title)s.%(ext)s" --add-metadata --write-sub -v
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['--cookies', 'cookies.txt', 'https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289-2.html', '-o', 'Lynda.com - %(playlist)s/%(chapter_number)s - %(chapter)s/%(playlist_index)s - %(title)s.%(ext)s', '--add-metadata', '--write-sub', '-v']
[debug] Encodings: locale cp1252, fs utf-8, out utf-8, pref cp1252
[debug] youtube-dl version 2018.08.28
[debug] Python version 3.7.2 (CPython) - Windows-10-10.0.17763-SP0
[debug] exe versions: ffmpeg 4.1.1, ffprobe 4.1.1
[debug] Proxy map: {}
[lynda:course] 784289: Downloading course JSON
[download] Downloading playlist: Illustrator CC 2019 One-on-One: Fundamentals
[lynda:course] playlist Illustrator CC 2019 One-on-One: Fundamentals: Collected 198 video ids (downloading 198 of them)
[download] Downloading video 1 of 198
[lynda] 3502034: Downloading video JSON
[lynda] 3502034: Checking 0-720 video format URL
[lynda] 3502034: 0-720 video format URL is invalid, skipping
[lynda] 3502034: Checking 0-540 video format URL
[lynda] 3502034: 0-540 video format URL is invalid, skipping
[lynda] 3502034: Checking 0-360 video format URL
[lynda] 3502034: 0-360 video format URL is invalid, skipping
[lynda] 3502034: Checking 1-720 video format URL
[lynda] 3502034: Checking 1-540 video format URL
[lynda] 3502034: Checking 1-360 video format URL
[debug] Default format spec: bestvideo+bestaudio/best
[info] Writing video subtitles to: Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\001 - The most comprehensive Illustrator training.en.srt
[debug] Invoking downloader on 'https://files3.lynda.com/secure/courses/784289/VBR_MP4h264_main_HD720/784289_00_01_WL30_Welcome.mp4?g4wB1rhE2Hoe_n0AuOgtO8kqNdWU5GWoG4JFMQ0DwG3K4lr8WDqoQ1zye-xMrEMeJUPgLfRHUfK9UuzLr40I_NiwHb_5hoH7vxFV2jB1kvzpqxhQAbw6kISt9APqoEuF_6fuE22Fa0K1QT4q0jcoJGxIJF8xXpeOueGHJRDM99EajWNE6tZYUnKjcm2a26c&c3.ri=3775082968747793560'
[download] Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\001 - The most comprehensive Illustrator training.mp4 has already been downloaded
[download] 100% of 66.98MiB
[ffmpeg] Adding metadata to 'Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\001 - The most comprehensive Illustrator training.mp4'
[debug] ffmpeg command line: ffmpeg -y -i "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\001 - The most comprehensive Illustrator training.mp4" -c copy -metadata "title=The most comprehensive Illustrator training" -metadata "purl=https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289/3502034-4.html" "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\001 - The most comprehensive Illustrator training.temp.mp4"
[download] Downloading video 2 of 198
[lynda] 3500046: Downloading video JSON
[lynda] 3500046: Checking 0-720 video format URL
[lynda] 3500046: 0-720 video format URL is invalid, skipping
[lynda] 3500046: Checking 0-540 video format URL
[lynda] 3500046: 0-540 video format URL is invalid, skipping
[lynda] 3500046: Checking 0-360 video format URL
[lynda] 3500046: 0-360 video format URL is invalid, skipping
[lynda] 3500046: Checking 1-720 video format URL
[lynda] 3500046: Checking 1-540 video format URL
[lynda] 3500046: Checking 1-360 video format URL
[debug] Default format spec: bestvideo+bestaudio/best
[info] Writing video subtitles to: Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\002 - A few important items before you begin.en.srt
[debug] Invoking downloader on 'https://files3.lynda.com/secure/courses/784289/VBR_MP4h264_main_HD720/784289_00_02_XR30_importantbeforebegin.mp4?YxHxbE5SLJMzLKa0q-AjRVm93E6iE2cx3qVQSHLp0WUZAk8Iv8IIIm-S3_Rz6SZ0VlhH_lDhz8t7_vmqEe0EIdWHbuaZIqAVbjLfhn_LCHw6-Rkt5JHyz6mWb5mItLlzT0qXzGQy_DKLr5ApUrABH8j55M3ZbLRxhajyFJ3R1FGMZTdTY29bW6HjflFR6dVSf1xxYKKkxnyESj6f&c3.ri=3775082968747793571'
[download] Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\002 - A few important items before you begin.mp4 has already been downloaded
[download] 100% of 15.93MiB
[ffmpeg] Adding metadata to 'Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\002 - A few important items before you begin.mp4'
[debug] ffmpeg command line: ffmpeg -y -i "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\002 - A few important items before you begin.mp4" -c copy -metadata "title=A few important items before you begin" -metadata "purl=https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289/3500046-4.html" "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\1 - Introduction\002 - A few important items before you begin.temp.mp4"
[download] Downloading video 3 of 198
[lynda] 3400038: Downloading video JSON
[lynda] 3400038: Checking 0-720 video format URL
[lynda] 3400038: 0-720 video format URL is invalid, skipping
[lynda] 3400038: Checking 0-540 video format URL
[lynda] 3400038: 0-540 video format URL is invalid, skipping
[lynda] 3400038: Checking 0-360 video format URL
[lynda] 3400038: 0-360 video format URL is invalid, skipping
[lynda] 3400038: Checking 1-720 video format URL
[lynda] 3400038: Checking 1-540 video format URL
[lynda] 3400038: Checking 1-360 video format URL
[debug] Default format spec: bestvideo+bestaudio/best
[info] Writing video subtitles to: Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\003 - A first look at Illustrator.en.srt
[debug] Invoking downloader on 'https://files3.lynda.com/secure/courses/784289/VBR_MP4h264_main_HD720/784289_01_01_MM30_Documents.mp4?7IhjOg4JyhTb2Ck1soZriu6CbxbHMR5bTdAk3RdtWguG-gNHcbFNb3f3nYzO8t5PMM6wgVOxg0eGkl5AKy1pcLjnCGrHKC62V-lByCp3P-T1Xjmx7oY5ZNns7dM14gV4ESM0vaFAVOrS5GipA4iKTYd6QoU58GLTy7oFXv7SHPbNRSWQLZ7bVsQ7zNTj8nizLA&c3.ri=3775082968747793585'
[download] Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\003 - A first look at Illustrator.mp4 has already been downloaded
[download] 100% of 8.30MiB
[ffmpeg] Adding metadata to 'Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\003 - A first look at Illustrator.mp4'
[debug] ffmpeg command line: ffmpeg -y -i "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\003 - A first look at Illustrator.mp4" -c copy -metadata "title=A first look at Illustrator" -metadata "purl=https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289/3400038-4.html" "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\003 - A first look at Illustrator.temp.mp4"
[download] Downloading video 4 of 198
[lynda] 3501047: Downloading video JSON
[lynda] 3501047: Checking 0-720 video format URL
[lynda] 3501047: 0-720 video format URL is invalid, skipping
[lynda] 3501047: Checking 0-540 video format URL
[lynda] 3501047: 0-540 video format URL is invalid, skipping
[lynda] 3501047: Checking 0-360 video format URL
[lynda] 3501047: 0-360 video format URL is invalid, skipping
[lynda] 3501047: Checking 1-720 video format URL
[lynda] 3501047: Checking 1-540 video format URL
[lynda] 3501047: Checking 1-360 video format URL
[debug] Default format spec: bestvideo+bestaudio/best
[info] Writing video subtitles to: Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\004 - Opening from the Windows desktop.en.srt
[debug] Invoking downloader on 'https://files3.lynda.com/secure/courses/784289/VBR_MP4h264_main_HD720/784289_01_02_XR30_openfromwindowsdesk.mp4?pyF9PwyU_BapeSeqRwz0gfSeCQAHGmlR-e0NMsf2tVGAa3uFUmCAQl0zz8ZbEYdjgvYAquMiKoMGC5XFRNtWfY9OMuyb9vXfY27DBBpojlZ_IN_n0avQMVY5QuHP3z1KImiO2l4Q6Rxhe89b3eACtq6e2vzLbhGETFrxDWT-DfNjp5L3Gof_OjycObSOphZig72WGuXaCRz-HcQ&c3.ri=3775082968747793594'
[download] Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\004 - Opening from the Windows desktop.mp4 has already been downloaded
[download] 100% of 25.23MiB
[ffmpeg] Adding metadata to 'Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\004 - Opening from the Windows desktop.mp4'
[debug] ffmpeg command line: ffmpeg -y -i "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\004 - Opening from the Windows desktop.mp4" -c copy -metadata "title=Opening from the Windows desktop" -metadata "purl=https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289/3501047-4.html" "file:Lynda.com - Illustrator CC 2019 One-on-One - Fundamentals\2 - 01. Working with Documents\004 - Opening from the Windows desktop.temp.mp4"
[download] Downloading video 5 of 198
[lynda] 3500047: Downloading video JSON
[lynda] 3500047: Checking 0-720 video format URL
[lynda] 3500047: 0-720 video format URL is invalid, skipping
[lynda] 3500047: Checking 0-540 video format URL
[lynda] 3500047: 0-540 video format URL is invalid, skipping
[lynda] 3500047: Checking 0-360 video format URL
[lynda] 3500047: 0-360 video format URL is invalid, skipping
[lynda] 3500047: Checking 1-720 video format URL
[lynda] 3500047: Checking 1-540 video format URL
[lynda] 3500047: Checking 1-360 video format URL
ERROR: None: Failed to parse JSON  (caused by JSONDecodeError('Expecting property name enclosed in double quotes: line 1 column 3 (char 2)')); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 866, in _parse_json
    return json.loads(json_string)
  File "c:\python37\lib\json\__init__.py", line 348, in loads
    return _default_decoder.decode(s)
  File "c:\python37\lib\json\decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "c:\python37\lib\json\decoder.py", line 353, in raw_decode
    obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 3 (char 2)
Traceback (most recent call last):
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 866, in _parse_json
    return json.loads(json_string)
  File "c:\python37\lib\json\__init__.py", line 348, in loads
    return _default_decoder.decode(s)
  File "c:\python37\lib\json\decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "c:\python37\lib\json\decoder.py", line 353, in raw_decode
    obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 3 (char 2)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "c:\python37\lib\site-packages\youtube_dl\YoutubeDL.py", line 792, in extract_info
    ie_result = ie.extract(url)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 502, in extract
    ie_result = self._real_extract(url)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\lynda.py", line 217, in _real_extract
    subtitles = self.extract_subtitles(video_id)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 2767, in extract_subtitles
    return self._get_subtitles(*args, **kwargs)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\lynda.py", line 250, in _get_subtitles
    subs = self._download_json(url, None, False)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 859, in _download_json
    expected_status=expected_status)
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 843, in _download_json_handle
    fatal=fatal), urlh
  File "c:\python37\lib\site-packages\youtube_dl\extractor\common.py", line 870, in _parse_json
    raise ExtractorError(errmsg, cause=ve)
youtube_dl.utils.ExtractorError: None: Failed to parse JSON  (caused by JSONDecodeError('Expecting property name enclosed in double quotes: line 1 column 3 (char 2)')); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see  https://yt-dl.org/update  on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

If the purpose of this issue is a site support request please provide all kinds of example URLs support for which should be included (replace following example URLs by yours):

Note that youtube-dl does not support sites dedicated to copyright infringement. In order for site support request to be accepted all provided example URLs should not violate any copyrights.


Description of your issue, suggested solution and other information

I tried to download the course here:

https://www.lynda.com/Illustrator-tutorials/Illustrator-CC-2019-One-One-Fundamentals-Revision/784289-2.html

Using a cookie.txt file, using powershell in admin mode, on windows 10 latest update, and at the end it gives me an error about JSONDecoding, As in the log above, and does not continue past that.

It is a library login method with a downloaded cookie.txt using the chrome extension.

@Bewinxed
Copy link
Author

@Bewinxed Bewinxed commented Mar 31, 2019

Apparently if I remove the --write-subs it downloads without issues.

However no subtitles are downloaded

@dstftw dstftw closed this in d89a0a8 Jul 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant
You can’t perform that action at this time.