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

Add extraction logic to mitele for videos not based in ooyala #25827

Closed
wants to merge 1 commit into from

Conversation

DjMoren
Copy link

@DjMoren DjMoren commented Jun 28, 2020

Please follow the guide below

  • You will be asked some questions, please read them carefully and answer honestly
  • Put an x into all the boxes [ ] relevant to your pull request (like that [x])
  • Use Preview tab to see how your pull request will actually look like

Before submitting a pull request make sure you have:

In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under Unlicense. Check one of the following options:

  • 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?

  • Bug fix
  • Improvement
  • New extractor
  • New feature

Description of your pull request and other information

Mitele has done changes, and some of the videos doesn't work with the extractor logic that was present (I'm not sure if it really works with anyone). That said, I've added new logic for videos not based in ooyala. This really fixes this issue. The account-needed tag added to that issue is not correct, it's only needed if you try to enter from outside Spain or if the video belongs to mitele PLUS (premium videos), and the videos posted in that issue can be downloaded correctly with posted fix without any account. That not happens with the videos posted in another issue, where the first is unavailable and the other belongs to mitele PLUS, that is not supported for the moment by the extractor logic (I don't have an account).

content = pre_player.get('content') or {}
info = content.get('info') or {}
content = pre_player.get('content', {})
info = content.get('info', {})
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is not equivalent, do not touch.

Copy link
Author

Choose a reason for hiding this comment

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

So sorry, and I must confess that it's the second time I make the same mistake in my life 🤦‍♂️

Comment on lines 105 to 112
cerbero_data = {
'bbx': caronte['bbx'],
'gbx': gbx['gbx']
}
headers = {
'Content-Type': 'application/json;charset=UTF-8',
'Origin': 'https://www.mitele.es'
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Inline.

Copy link
Author

Choose a reason for hiding this comment

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

I made like this for improving readability from my side as I read in the documentation, but I understand your point of view.

Comment on lines 117 to 118
stream = '%s?%s' % (caronte['dls'][0]['stream'],
cerbero['tokens']['1']['cdn'])
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do not encode query into URL but pass via appropriate _extract_m3u8_formats parameter.

Copy link
Author

Choose a reason for hiding this comment

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

I've passed it through query parameter, but the result isn't very readable from my point of view. Anyway, if this is the way to go, just go ahead and if you expected something different just tell me.

@DjMoren
Copy link
Author

DjMoren commented Jul 1, 2020

Force pushed an update in my branch, let's see if this is the definitive!

@felisucoibi
Copy link

felisucoibi commented Aug 6, 2020

thanks a lot it works

@felisucoibi
Copy link

@DjMoren

Es posible descargar estas peliculas que son de pago sin ser premium como anteriormente.
https://www.mitele.es/peliculas/

NO, ahora son de pago.

@felisucoibi
Copy link

He conseguido los m3u8 de los videos de pago sin ser premium pero no permite descargarlos da error 403 ¿hay alguna forma de saltarse el error 403?

Pagando, esta protegido para que sólo alguien que pague pueda bajarlos. Pero si pagas puedes conseguir los m3u8

@bdovaz
Copy link

bdovaz commented Sep 8, 2020

Any news on this?

@dstftw dstftw force-pushed the master branch 2 times, most recently from 5e26784 to da2069f Compare September 13, 2020 13:50
@felisucoibi
Copy link

stoped working?

@bdovaz
Copy link

bdovaz commented Sep 16, 2020

@DjMoren can you make the requested change in order to merge this PR? Thanks.

@felisucoibi
Copy link

is broken again dont merge

@DjMoren
Copy link
Author

DjMoren commented Sep 26, 2020

Can you @felisucoibi or @bdovaz be more precise when you comment things? I have checked that tests are passing and done a manual test right now for Mi casa es la tuya T09x98 and everything was correct. If you find an error, please detail it, and if anyone have time to solve it will do. I only PRed this because previously it wasn't working when I needed it, but I'm not the main supporter, you should understand it.

PS: I'm not going to add support for payed videos because I'm not going to pay for an account here.

@bdovaz
Copy link

bdovaz commented Sep 26, 2020

I have simply said if you can merge this PR, nothing more.

I haven't tried it because I don't know how to test something that is not published, I only use the Windows version.

@DjMoren DjMoren requested a review from dstftw September 26, 2020 13:09
@DjMoren
Copy link
Author

DjMoren commented Sep 26, 2020

No, you said @DjMoren can you make the requested change in order to merge this PR? Thanks.. The changes were done when I commented Force pushed an update in my branch, let's see if this is the definitive!. The reviewer has to approve the PR, I have requested to re-review now.

@bdovaz
Copy link

bdovaz commented Sep 26, 2020

No, you said @DjMoren can you make the requested change in order to merge this PR? Thanks.. The changes were done when I commented Force pushed an update in my branch, let's see if this is the definitive!. The reviewer has to approve the PR, I have requested to re-review now.

I meant because of this on the bottom:

Changes requested
1 review requesting changes

@DarkZeros
Copy link
Contributor

DarkZeros commented Oct 1, 2020

Oh damm, I didn't search and ended redoing it myself from scratch on my branch -> #26757
I guess it is a duplicate now :(

@DarkZeros DarkZeros mentioned this pull request Oct 1, 2020
8 tasks
@felisucoibi
Copy link

New urls not wroking.

2020-10-23 Cuarto Milenio - /programas-tv/cuarto-milenio/temporada-15/programa-623-40_1008608575015/player/

@felisucoibi
Copy link

Is possible to make this work with session videos that needs login and a cookie?

ThirumalaiK pushed a commit to ThirumalaiK/youtube-dl that referenced this pull request Jan 28, 2021
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.

It stopped working with the domain mitele.es
5 participants