Skip to content

plugins.mdstrm: new plugin for mdstrm.com livestreams #4395

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

Merged
merged 2 commits into from
Mar 14, 2022

Conversation

back-to
Copy link
Collaborator

@back-to back-to commented Mar 13, 2022

https://www.mediastre.am/en/about-us

closes #4389
ref #4269

$ streamlink https://mdstrm.com/live-stream/5a7b1e63a8da282c34d65445
[cli][info] Found matching plugin mdstrm for URL https://mdstrm.com/live-stream/5a7b1e63a8da282c34d65445
[plugins.mdstrm][debug] iframe=https://mdstrm.com/live-stream/5a7b1e63a8da282c34d65445
[cli][info] Available streams: 240p (worst), 360p, 480p, 720p (best)
[cli][info] Opening stream: 720p (hls)
$ streamlink https://www.latina.pe/tvenvivo
[cli][info] Found matching plugin mdstrm for URL https://www.latina.pe/tvenvivo
[plugins.mdstrm][debug] iframe=https://mdstrm.com/live-stream/5ce7109c7398b977dc0744cd?autoplay=false&player=
[plugins.mdstrm][debug] programmatic_url=https://mdstrm.com/programmatic/5ce7109c7398b977dc0744cd?autoplay=false
[cli][info] Available streams: 240p (worst), 360p, 480p, 720p (best)
[cli][info] Opening stream: 720p (hls)

@malvinas2
Copy link
Contributor

It works here with no problems. Thank you @back-to !

Copy link
Member

@bastimeyer bastimeyer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The plugin implementation is looking fine and should be good to be merged apart from the missing metadata.

I'm not a fan of the trailing closing parenthesis and indentation style though which makes it unnecessarily more difficult to read and edit later on for the sake of being more compact. I don't want to complain, but if we decide to add a more strict linting config in the future (like python-black for example), then this will most certainly generate unnecessary diffs. For now this is valid coding style though.

validate.any(None, str))
error_msg = validate.validate(schema, root)
if error_msg:
log.error(f"{error_msg}")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this intentional that there's no return statement here? If the content is unavailable / geo-blocked, then it should stop here (I guess), because otherwise it'll log

[plugins.mdstrm][debug] Failed to find window.MDSTRM.OPTIONS

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it is intended,
i don't know if ".//div[@id='message']/text()" is used for other messages

Co-authored-by: Sebastian Meyer <mail@bastimeyer.de>
@bastimeyer bastimeyer merged commit a8b2ddc into streamlink:master Mar 14, 2022
@back-to back-to deleted the mdstrm branch April 9, 2022 16:24
light4 pushed a commit to light4/streamlink that referenced this pull request Dec 9, 2022
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.

Re-add Latina.pe
3 participants