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

Fixed mediastream when hls uses extra arguments #8657

Merged
merged 6 commits into from Dec 6, 2023

Conversation

NickCis
Copy link
Contributor

@NickCis NickCis commented Nov 24, 2023

IMPORTANT: PRs without the template will be CLOSED

Description of your pull request and other information

This PR fixes the mediastream extractor for sites that uses access_token or extra arguments in the HLS link.

The fix targets particularly to the iframe link of these two sites (the iframe link has to be extracted using the browser, it'll be the url passed to yt-dlp):

  • https://www.tvn.cl/en-vivo
  • https://www.mega.cl/senal-en-vivo/

These streams have a geo restriction and can only be accessed from Chile.

I have not made any new test, what would be the recommended way to test these changes?.

Fixes #

Template

Before submitting a pull request make sure you have:

In order to be accepted and merged into yt-dlp each piece of code must be in public domain or released under Unlicense. Check all of the following options that apply:

  • I am the original author of this code and I am willing to release it under Unlicense
  • I am not the original author of this code but it is in public domain or released under Unlicense (provide reliable evidence)

What is the purpose of your pull request?

@bashonly bashonly added the site-bug Issue with a specific website label Nov 25, 2023
@bashonly bashonly self-requested a review November 25, 2023 03:59
yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
@seproDev seproDev added the pending-fixes PR has had changes requested label Nov 28, 2023
@NickCis
Copy link
Contributor Author

NickCis commented Nov 28, 2023

@seproDev I have applied your suggestions and also the "walrus operator" change that @pukkandan suggested (I didn't know that it existed!, Thanks for the lesson 👏 )

yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
Co-authored-by: sepro <4618135+seproDev@users.noreply.github.com>
@seproDev seproDev added pending-review PR needs a review and removed pending-fixes PR has had changes requested labels Nov 28, 2023
@NickCis
Copy link
Contributor Author

NickCis commented Nov 28, 2023

@seproDev Done!

yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
yt_dlp/extractor/mediastream.py Outdated Show resolved Hide resolved
@bashonly bashonly removed the pending-review PR needs a review label Dec 6, 2023
@seproDev seproDev merged commit b03c893 into yt-dlp:master Dec 6, 2023
15 checks passed
aalsuwaidi pushed a commit to aalsuwaidi/yt-dlp that referenced this pull request Apr 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
site-bug Issue with a specific website
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants