Closed stari4ek closed 7 years ago
I doubt we'll be gracefully handling the transition to play the MPEG-TS stream any time soon, but we should figure out the data isn't an HLS playlist and bail out with an error, rather than consuming the stream until we OOM.
Proper Exception (with resolved url?) would be nice. It will help to switch to proper MediaSource on player level, where source type is identified
It looks like it would be straightforward to include the resolved URL in the exception. The exception type will be some kind of "unexpected content" exception. Note that it wont tell you what the content is, only that it's not an HLS playlist. That should be sufficient though. You can try ExtractorMediaSource
with the resolved URL. If you get an UnrecognizedInputFormatException
when you try that then something else has happened (e.g. you've probably hit a paywall rather than media content).
HlsPlaylistParser.parse
) with OOM in the end