Skip to content

Conversation

@back-to
Copy link
Collaborator

@back-to back-to commented May 22, 2021

plugins.onetv

  • uses API v1 which is only 1tv.ru
  • remove broken VOD support

plugins.mediavitrina

  • uses API v2

closes #3587
closes #3669

@back-to back-to added plugin issue A Plugin does not work correctly plugin enhancement A new feature for a working Plugin labels May 22, 2021
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.

Just commenting on the code, not the actual implementation, as it's geo-blocked and I don't have access.

Comment on lines +14 to +24
_re_url_1 = re.compile(r'https?://(?P<channel>ctc(?:love)?|chetv|domashniy|5-tv)\.ru/(?:online|live)')
_re_url_2 = re.compile(r'https?://(?P<channel>ren)\.tv/live')
_re_url_3 = re.compile(r'https?://player\.mediavitrina\.ru/(?P<channel>[^/?]+.)(?:/[^/]+)?/[\w_]+/player\.html')

@classmethod
def can_handle_url(cls, url):
return (
cls._re_url_1.match(url) is not None
or cls._re_url_2.match(url) is not None
or cls._re_url_3.match(url) is not None
)
Copy link
Member

Choose a reason for hiding this comment

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

Not sure if this should be changed to a single regex.

If we ever switch the plugin matching system and load plugins on demand with a list of regexes extracted from the plugin modules during build time, then we need to implement a system that can take multiple regexes into account for a single plugin. There are only a handful of plugins currently (5 or so) that use "extended" logic in the can_handle_url method.

Shouldn't be too much of an issue though, so feel free to ignore.

back-to added 2 commits May 24, 2021 12:48
- remove broken VOD support
- remove other domains which use API V2, 1TV uses API V1
- re-added removed domains from onetv plugin
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.

Code looks good now, hence the approval. Can't test the sites though due to geolocking

@back-to back-to merged commit 4c90291 into streamlink:master May 26, 2021
@back-to back-to deleted the MediaVitrina branch May 26, 2021 17:30
Billy2011 added a commit to Billy2011/streamlink-27 that referenced this pull request May 27, 2021
- remove broken VOD support
- remove other domains which use API V2, 1TV uses API V1
Billy2011 added a commit to Billy2011/streamlink-27 that referenced this pull request May 27, 2021
- re-added removed domains from onetv plugin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

plugin enhancement A new feature for a working Plugin plugin issue A Plugin does not work correctly

Projects

None yet

Development

Successfully merging this pull request may close these issues.

plugins.onetv: All channels except 1tv don't work

3 participants