How to play Youtube livestream on Chromecast with media_extractor?

I’m running into a new problem with casting live streams, it looks like the underlying pythin library casttube is not setting the correct Length header on one of its API calls resuling in the following erorr:

requests.exceptions.HTTPError: 411 Client Error: Length Required for url: https://www.youtube.com/api/lounge/pairing/get_lounge_token_batch

Is anyone else seeing this or have a way around it?
I filed a bug here just in case: https://github.com/ur1katz/casttube/issues/13

The solution used to work for me, but now it no longer works. Not sure what changed. Would love to play live streams again

it’s not media extractor but it does work with live streams. using the Android TV Remote integration.

1 Like