Repository: streamlink/streamlink

Issue:
Dogus.py missing stream
https://www.ntvspor.net/ntvspor-canli-yayin

This is normally handled by dogus.py but it seems to be outdated. The other streams are working ok only this one.

Discussion:

Patch:
diff --git a/docs/plugin_matrix.rst b/docs/plugin_matrix.rst
index 788c0f6e..dab3cbb9 100644
--- a/docs/plugin_matrix.rst
+++ b/docs/plugin_matrix.rst
@@ -64,10 +64,9 @@ dogan                   - cnnturk.com        Yes   Yes
                         - dreamtv.com.tr
                         - kanald.com.tr
                         - teve2.com.tr
-dogus                   - ntvspor.net        Yes   No
+dogus                   - eurostartv.com.tr  Yes   No
                         - kralmuzik.com.tr
                         - ntv.com.tr
-                        - eurostartv.com.tr
                         - startv.com.tr
 dommune                 dommune.com          Yes   --
 drdk                    dr.dk                Yes   No    Streams may be geo-restricted to Denmark.
diff --git a/src/streamlink/plugins/dogus.py b/src/streamlink/plugins/dogus.py
index 38cbff3d..2175abe1 100644
--- a/src/streamlink/plugins/dogus.py
+++ b/src/streamlink/plugins/dogus.py
@@ -12,16 +12,15 @@ log = logging.getLogger(__name__)
 
 class Dogus(Plugin):
     """
-    Support for live streams from Dogus sites include ntv, ntvspor, and kralmuzik
+    Support for live streams from Dogus sites include ntv, and kralmuzik
     """
 
-    url_re = re.compile(r"""https?://(?:www.)?
+    url_re = re.compile(r"""https?://(?:www\.)?
         (?:
-            ntv.com.tr/canli-yayin/ntv|
-            ntvspor.net/canli-yayin|
-            kralmuzik.com.tr/tv/|
-            eurostartv.com.tr/canli-izle|
-            startv.com.tr/canli-yayin
+            eurostartv\.com\.tr/canli-izle|
+            kralmuzik\.com\.tr/tv/|
+            ntv\.com\.tr/canli-yayin/ntv|
+            startv\.com\.tr/canli-yayin
         )/?""", re.VERBOSE)
     mobile_url_re = re.compile(r"""(?P<q>["'])(?P<url>(https?:)?//[^'"]*?/live/hls/[^'"]*?\?token=)
                                    (?P<token>[^'"]*?)(?P=q)""", re.VERBOSE)


Test patch:
diff --git a/tests/plugins/test_dogus.py b/tests/plugins/test_dogus.py
index dee4e16f..b4484114 100644
--- a/tests/plugins/test_dogus.py
+++ b/tests/plugins/test_dogus.py
@@ -6,8 +6,9 @@ from streamlink.plugins.dogus import Dogus
 class TestPluginDogus(unittest.TestCase):
     def test_can_handle_url(self):
         should_match = [
-            'http://www.ntvspor.net/canli-yayin',
             'http://eurostartv.com.tr/canli-izle',
+            'http://kralmuzik.com.tr/tv/',
+            'http://ntv.com.tr/canli-yayin/ntv',
             'http://startv.com.tr/canli-yayin',
         ]
         for url in should_match:
@@ -16,6 +17,7 @@ class TestPluginDogus(unittest.TestCase):
     def test_can_handle_url_negative(self):
         should_not_match = [
             'https://example.com/index.html',
+            'http://www.ntvspor.net/canli-yayin',
         ]
         for url in should_not_match:
             self.assertFalse(Dogus.can_handle_url(url))