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

XML parse error on phoenix media center #29057

Closed
5 tasks done
Bachsau opened this issue May 16, 2021 · 0 comments
Closed
5 tasks done

XML parse error on phoenix media center #29057

Bachsau opened this issue May 16, 2021 · 0 comments

Comments

@Bachsau
Copy link

Bachsau commented May 16, 2021

Checklist

  • I'm reporting a broken site support
  • I've verified that I'm running youtube-dl version 2021.04.26
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar issues including closed ones

Verbose log

[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-v', 'https://www.phoenix.de/sendungen/gespraeche/phoenix-persoenlich/buergermeister-dirk-neubauer-zu-gast-bei-michael-krons-a-2114890.html']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2021.04.26
[debug] Python version 3.7.10 (CPython) - Darwin-18.7.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.4, ffprobe 4.4, rtmpdump 2.4
[debug] Proxy map: {}
ERROR: 2155795: Failed to parse XML  (caused by ParseError('not well-formed (invalid token): line 1, column 0')); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
Traceback (most recent call last):
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 856, in _parse_xml
    return compat_etree_fromstring(xml_string.encode('utf-8'))
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/compat.py", line 2542, in compat_etree_fromstring
    return etree.XML(text, parser=etree.XMLParser(target=_TreeBuilder()))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/xml/etree/ElementTree.py", line 1315, in XML
    parser.feed(text)
  File "<string>", line None
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 0
Traceback (most recent call last):
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 856, in _parse_xml
    return compat_etree_fromstring(xml_string.encode('utf-8'))
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/compat.py", line 2542, in compat_etree_fromstring
    return etree.XML(text, parser=etree.XMLParser(target=_TreeBuilder()))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/xml/etree/ElementTree.py", line 1315, in XML
    parser.feed(text)
  File "<string>", line None
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 0

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 806, in wrapper
    return func(self, *args, **kwargs)
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 827, in __extract_info
    ie_result = ie.extract(url)
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 534, in extract
    ie_result = self._real_extract(url)
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/phoenix.py", line 88, in _real_extract
    'profile': 'player2',
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 849, in _download_xml
    expected_status=expected_status)
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 833, in _download_xml_handle
    fatal=fatal), urlh
  File "/Users/XXX/.local/bin/youtube-dl/youtube_dl/extractor/common.py", line 860, in _parse_xml
    raise ExtractorError(errmsg, cause=ve)
youtube_dl.utils.ExtractorError: 2155795: Failed to parse XML  (caused by ParseError('not well-formed (invalid token): line 1, column 0')); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.

Description

youtube-dl fails to download this url, seemingly just because of a missing or malformed xml intro. Maybe you could apply some simple sanitization on XMLs to avoid parsing errors.

@dstftw dstftw closed this as completed in eb50802 May 16, 2021
fossdd pushed a commit to ex-dl/ex-dl that referenced this issue May 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant