Skip to content

Conversation

@bastimeyer
Copy link
Member

Fixes #4074

What's broken is the regex for removing the namespace data, which expects a leading space or tab character, which doesn't work when a new-line or a different whitespace character is used in the serialized XML content. I've added another test for that.

There's probably a better solution for stripping default namespace information than using a dirty regex substitution, but this simple fix should work for now (and I don't want to re-implement the parse_xml method).
https://lxml.de/parsing.html#parsers

@gravyboat gravyboat merged commit b311b2c into streamlink:master Oct 7, 2021
@bastimeyer bastimeyer deleted the utils/parse/xml branch October 7, 2021 00:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

dash plugin: MPDParsingError: root tag did not match the expected tag: MPD

2 participants