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

Enable remote sreaming using ISP credentials #60

Merged
merged 2 commits into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,18 @@
# 2.x

## [2.2.0](https://github.com/f-lawe/plugin.video.orange.fr/releases/tag/v2.2.0) - 2024-10-03

### Added
- Support remote authentication to Orange live and catchup streams ([#22](https://github.com/f-lawe/plugin.video.orange.fr/issues/22))

## [2.1.4](https://github.com/f-lawe/plugin.video.orange.fr/releases/tag/v2.1.4) - 2024-08-08

## Changed
### Changed
- Better UI items management

### Fixed
- InputStream Helper is now called properly ([#50](https://github.com/f-lawe/plugin.video.orange.fr/issues/50))
- Avoid plugin to be runned twice on catchup TV videos ([#55](https://github.com/f-lawe/plugin.video.orange.fr/issues/55))
- Avoid plugin to be run twice on catchup TV videos ([#55](https://github.com/f-lawe/plugin.video.orange.fr/issues/55))

## [2.1.3](https://github.com/f-lawe/plugin.video.orange.fr/releases/tag/v2.1.3) - 2024-07-21

Expand Down
2 changes: 1 addition & 1 deletion addon.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="plugin.video.orange.fr" name="Orange TV France" version="2.1.4" provider-name="Flawe">
<addon id="plugin.video.orange.fr" name="Orange TV France" version="2.2.0" provider-name="Flawe">
<requires>
<import addon="xbmc.python" version="3.0.1"/>
<import addon="script.module.routing" version="0.2.3"/>
Expand Down
26 changes: 25 additions & 1 deletion resources/language/resource.language.en_gb/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ msgid "Help 30102"
msgstr ""

msgctxt "#30103"
msgid "Enable IPTV Manager integration"
msgid "Enable Kodi live TV"
msgstr ""

msgctxt "#30104"
Expand Down Expand Up @@ -64,6 +64,30 @@ msgctxt "#30204"
msgid "Help 30204"
msgstr ""

msgctxt "#30205"
msgid "Use login credentials"
msgstr ""

msgctxt "#30206"
msgid "Help 30206"
msgstr ""

msgctxt "#30207"
msgid "Login"
msgstr ""

msgctxt "#30208"
msgid "Help 30208"
msgstr ""

msgctxt "#30209"
msgid "Password"
msgstr ""

msgctxt "#30210"
msgid "Help 30210"
msgstr ""

# Proxy settings (from 30300 to 30399)

msgctxt "#30300"
Expand Down
34 changes: 29 additions & 5 deletions resources/language/resource.language.fr_fr/strings.po
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@ msgstr "Installer IPTV Manager…"

msgctxt "#30102"
msgid "Help 30102"
msgstr ""
msgstr "IPTV Manager est requis pour la TV en direct dans Kodi"

msgctxt "#30103"
msgid "Enable IPTV Manager integration"
msgstr "Activer l'intégration avec IPTV Manager"
msgid "Enable Kodi live TV"
msgstr "Activer la TV en direct dans Kodi"

msgctxt "#30104"
msgid "Help 30104"
msgstr ""
msgstr "Activer cette option pour accéder à vos chaînes en direct depuis Kodi"

msgctxt "#30105"
msgid "Go to IPTV Manager settings…"
Expand All @@ -54,14 +54,38 @@ msgstr "Pays"

msgctxt "#30202"
msgid "Help 30202"
msgstr ""
msgstr "Sélectionner le pays de votre fournisser d'accès à internet"

msgctxt "#30203"
msgid "Internet service provider"
msgstr "Fournisseur d'accès à internet"

msgctxt "#30204"
msgid "Help 30204"
msgstr "Sélectionner votre fournisser"

msgctxt "#30205"
msgid "Use login credentials"
msgstr "Utiliser des identifiants de connexion"

msgctxt "#30206"
msgid "Help 30206"
msgstr "Certains fournisseurs peuvent demander une authentification, particulièrement si vous accéder au service depuis une connexion différente."

msgctxt "#30207"
msgid "Login"
msgstr "Identifiant"

msgctxt "#30208"
msgid "Help 30208"
msgstr ""

msgctxt "#30209"
msgid "Password"
msgstr "Mot de passe"

msgctxt "#30210"
msgid "Help 30210"
msgstr ""

# Proxy settings (from 30300 to 30399)
Expand Down
9 changes: 6 additions & 3 deletions resources/lib/managers/stream_manager.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
"""Video stream manager."""

import inputstreamhelper
import xbmc
import xbmcplugin

from lib.providers import get_provider
from lib.router import router
from lib.utils.gui import create_play_item
from lib.utils.kodi import localize, ok_dialog
from lib.utils.kodi import localize, log, ok_dialog


class StreamManager:
Expand All @@ -29,8 +30,9 @@ def load_chatchup_stream(self, stream_id: str) -> None:
def _load_stream(self, stream_info: dict = None) -> None:
"""Load stream."""
if stream_info is None:
log("Stream not included in subscription", xbmc.LOGERROR)
ok_dialog(localize(30900))
xbmcplugin.setResolvedUrl(router.handle, False)
xbmcplugin.setResolvedUrl(router.handle, False, create_play_item())
return

is_helper = inputstreamhelper.Helper(stream_info["manifest_type"], drm=stream_info["license_type"])
Expand All @@ -40,5 +42,6 @@ def _load_stream(self, stream_info: dict = None) -> None:
xbmcplugin.setResolvedUrl(router.handle, True, play_item)
return

log("Cannot load InputStream", xbmc.LOGERROR)
ok_dialog(localize(30901))
xbmcplugin.setResolvedUrl(router.handle, False)
xbmcplugin.setResolvedUrl(router.handle, False, create_play_item())
4 changes: 2 additions & 2 deletions resources/lib/providers/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

from lib.utils.kodi import get_addon_setting, log

from .abstract_provider import AbstractProvider
from .fr import OrangeCaraibeProvider, OrangeFranceProvider, OrangeReunionProvider
from .provider_interface import ProviderInterface

_PROVIDERS = {
"France.Orange": OrangeFranceProvider,
Expand All @@ -23,6 +23,6 @@
log(f"Cannot instanciate provider: {_PROVIDER_KEY}", xbmc.LOGERROR)


def get_provider() -> ProviderInterface:
def get_provider() -> AbstractProvider:
"""Return the selected provider."""
return _PROVIDER
Loading