KekikStream 1.9.0__tar.gz → 1.9.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (93) hide show
  1. kekikstream-1.9.2/KekikStream/Core/Extractor/ExtractorManager.py +52 -0
  2. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/YTDLP.py +67 -4
  3. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/PKG-INFO +1 -1
  4. {kekikstream-1.9.0 → kekikstream-1.9.2}/PKG-INFO +1 -1
  5. {kekikstream-1.9.0 → kekikstream-1.9.2}/setup.py +1 -1
  6. kekikstream-1.9.0/KekikStream/Core/Extractor/ExtractorManager.py +0 -31
  7. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/CLI/__init__.py +0 -0
  8. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/CLI/pypi_kontrol.py +0 -0
  9. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Extractor/ExtractorBase.py +0 -0
  10. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Extractor/ExtractorLoader.py +0 -0
  11. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Extractor/ExtractorModels.py +0 -0
  12. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Media/MediaHandler.py +0 -0
  13. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Media/MediaManager.py +0 -0
  14. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Plugin/PluginBase.py +0 -0
  15. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Plugin/PluginLoader.py +0 -0
  16. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Plugin/PluginManager.py +0 -0
  17. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/Plugin/PluginModels.py +0 -0
  18. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/UI/UIManager.py +0 -0
  19. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Core/__init__.py +0 -0
  20. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/CloseLoad.py +0 -0
  21. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/ContentX.py +0 -0
  22. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/DzenRu.py +0 -0
  23. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/ExPlay.py +0 -0
  24. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/FirePlayer.py +0 -0
  25. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/FourCX.py +0 -0
  26. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/FourPichive.py +0 -0
  27. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/FourPlayRu.py +0 -0
  28. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/HDPlayerSystem.py +0 -0
  29. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/HDStreamAble.py +0 -0
  30. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/Hotlinger.py +0 -0
  31. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/JetTv.py +0 -0
  32. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/MailRu.py +0 -0
  33. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/MixPlayHD.py +0 -0
  34. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/MixTiger.py +0 -0
  35. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/MolyStream.py +0 -0
  36. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/Odnoklassniki.py +0 -0
  37. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/OkRuHTTP.py +0 -0
  38. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/OkRuSSL.py +0 -0
  39. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/PeaceMakerst.py +0 -0
  40. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/Pichive.py +0 -0
  41. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/PixelDrain.py +0 -0
  42. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/PlayRu.py +0 -0
  43. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/PlayerFilmIzle.py +0 -0
  44. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/RapidVid.py +0 -0
  45. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/SetPlay.py +0 -0
  46. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/SetPrime.py +0 -0
  47. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/SibNet.py +0 -0
  48. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/Sobreatsesuyp.py +0 -0
  49. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/TRsTX.py +0 -0
  50. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/TauVideo.py +0 -0
  51. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/TurboImgz.py +0 -0
  52. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/TurkeyPlayer.py +0 -0
  53. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VidHide.py +0 -0
  54. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VidMoly.py +0 -0
  55. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VidMolyMe.py +0 -0
  56. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VidMoxy.py +0 -0
  57. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VidPapi.py +0 -0
  58. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/VideoSeyred.py +0 -0
  59. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Extractors/YildizKisaFilm.py +0 -0
  60. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/DiziBox.py +0 -0
  61. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/DiziPal.py +0 -0
  62. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/DiziYou.py +0 -0
  63. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/Dizilla.py +0 -0
  64. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/FilmBip.py +0 -0
  65. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/FilmMakinesi.py +0 -0
  66. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/FilmModu.py +0 -0
  67. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/FullHDFilm.py +0 -0
  68. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/FullHDFilmizlesene.py +0 -0
  69. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/HDFilmCehennemi.py +0 -0
  70. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/JetFilmizle.py +0 -0
  71. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/KultFilmler.py +0 -0
  72. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/RecTV.py +0 -0
  73. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/RoketDizi.py +0 -0
  74. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/SelcukFlix.py +0 -0
  75. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/SezonlukDizi.py +0 -0
  76. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/SineWix.py +0 -0
  77. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/Sinefy.py +0 -0
  78. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/SinemaCX.py +0 -0
  79. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/Sinezy.py +0 -0
  80. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/SuperFilmGeldi.py +0 -0
  81. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/Plugins/UgurFilm.py +0 -0
  82. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/__init__.py +0 -0
  83. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/__main__.py +0 -0
  84. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream/requirements.txt +0 -0
  85. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/SOURCES.txt +0 -0
  86. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/dependency_links.txt +0 -0
  87. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/entry_points.txt +0 -0
  88. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/requires.txt +0 -0
  89. {kekikstream-1.9.0 → kekikstream-1.9.2}/KekikStream.egg-info/top_level.txt +0 -0
  90. {kekikstream-1.9.0 → kekikstream-1.9.2}/LICENSE +0 -0
  91. {kekikstream-1.9.0 → kekikstream-1.9.2}/MANIFEST.in +0 -0
  92. {kekikstream-1.9.0 → kekikstream-1.9.2}/README.md +0 -0
  93. {kekikstream-1.9.0 → kekikstream-1.9.2}/setup.cfg +0 -0
@@ -0,0 +1,52 @@
1
+ # Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
2
+
3
+ from .ExtractorLoader import ExtractorLoader
4
+ from .ExtractorBase import ExtractorBase
5
+
6
+ class ExtractorManager:
7
+ def __init__(self, extractor_dir="Extractors"):
8
+ # Çıkarıcı yükleyiciyi başlat ve tüm çıkarıcıları yükle
9
+ self.extractor_loader = ExtractorLoader(extractor_dir)
10
+ self.extractors = self.extractor_loader.load_all()
11
+
12
+ # Extractor instance'larını cache'le
13
+ self._extractor_instances = []
14
+ self._ytdlp_extractor = None
15
+
16
+ for extractor_cls in self.extractors:
17
+ instance = extractor_cls()
18
+
19
+ # YTDLP'yi ayrı tut
20
+ if instance.name == "yt-dlp":
21
+ self._ytdlp_extractor = instance
22
+ else:
23
+ self._extractor_instances.append(instance)
24
+
25
+ # YTDLP'yi EN BAŞA ekle
26
+ if self._ytdlp_extractor:
27
+ self._extractor_instances.insert(0, self._ytdlp_extractor)
28
+
29
+ def find_extractor(self, link) -> ExtractorBase:
30
+ """
31
+ Verilen bağlantıyı işleyebilecek çıkarıcıyı bul
32
+ """
33
+ # Cached instance'ları kullan
34
+ for extractor in self._extractor_instances:
35
+ if extractor.can_handle_url(link):
36
+ return extractor
37
+
38
+ return None
39
+
40
+ def map_links_to_extractors(self, links) -> dict:
41
+ """
42
+ Bağlantıları uygun çıkarıcılarla eşleştir
43
+ """
44
+ mapping = {}
45
+ for link in links:
46
+ # Cached instance'ları kullan
47
+ for extractor in self._extractor_instances:
48
+ if extractor.can_handle_url(link):
49
+ mapping[link] = f"{extractor.name:<30} » {link.replace(extractor.main_url, '')}"
50
+ break # İlk eşleşmede dur
51
+
52
+ return mapping
@@ -1,19 +1,82 @@
1
1
  # Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
2
2
 
3
3
  from KekikStream.Core import ExtractorBase, ExtractResult, Subtitle
4
- import yt_dlp, sys, os
4
+ from urllib.parse import urlparse
5
+ from yt_dlp.extractor import gen_extractors
6
+ import yt_dlp, re, sys, os
5
7
 
6
8
  class YTDLP(ExtractorBase):
7
9
  name = "yt-dlp"
8
10
  main_url = "" # Universal - tüm siteleri destekler
9
11
 
12
+ _FAST_DOMAIN_RE = None # compiled mega-regex (host üstünden)
13
+
14
+ @classmethod
15
+ def _init_fast_domain_regex(cls):
16
+ if cls._FAST_DOMAIN_RE is not None:
17
+ return
18
+
19
+ domains = set()
20
+
21
+ # yt-dlp extractor'larının _VALID_URL regex'lerinden domain yakala
22
+ # Regex metinlerinde domainler genelde "\." şeklinde geçer.
23
+ domain_pat = re.compile(r"(?:[a-z0-9-]+\\\.)+[a-z]{2,}", re.IGNORECASE)
24
+
25
+ for ie in gen_extractors():
26
+ # Generic'i fast-path'e dahil etmiyoruz
27
+ if getattr(ie, "IE_NAME", "").lower() == "generic":
28
+ continue
29
+
30
+ valid = getattr(ie, "_VALID_URL", None)
31
+ if not valid or not isinstance(valid, str):
32
+ continue
33
+
34
+ for m in domain_pat.findall(valid):
35
+ d = m.replace(r"\.", ".").lower()
36
+
37
+ # Çok agresif/şüpheli şeyleri elemek istersen burada filtre koyabilirsin
38
+ # (genelde gerek kalmıyor)
39
+ domains.add(d)
40
+
41
+ # Hiç domain çıkmazsa (çok uç durum) fallback: boş regex
42
+ if not domains:
43
+ cls._FAST_DOMAIN_RE = re.compile(r"$^") # hiçbir şeye match etmez
44
+ return
45
+
46
+ # Host eşleştirmesi: subdomain destekli (m.youtube.com, player.vimeo.com vs.)
47
+ # (?:^|.*\.) (domain1|domain2|...) $
48
+ joined = "|".join(sorted(re.escape(d) for d in domains))
49
+ pattern = rf"(?:^|.*\.)(?:{joined})$"
50
+ cls._FAST_DOMAIN_RE = re.compile(pattern, re.IGNORECASE)
51
+
10
52
  def __init__(self):
11
- pass
53
+ self.__class__._init_fast_domain_regex()
12
54
 
13
55
  def can_handle_url(self, url: str) -> bool:
14
56
  """
15
- yt-dlp'nin bu URL'yi işleyip işleyemeyeceğini kontrol et
57
+ Fast-path: URL host'unu tek mega-regex ile kontrol et (loop yok)
58
+ Slow-path: gerekirse mevcut extract_info tabanlı kontrolün
16
59
  """
60
+ # URL parse + host al
61
+ try:
62
+ parsed = urlparse(url)
63
+ host = (parsed.hostname or "").lower()
64
+ except Exception:
65
+ host = ""
66
+
67
+ # Şemasız URL desteği: "youtube.com/..." gibi
68
+ if not host and "://" not in url:
69
+ try:
70
+ parsed = urlparse("https://" + url)
71
+ host = (parsed.hostname or "").lower()
72
+ except Exception:
73
+ host = ""
74
+
75
+ # Fast-path
76
+ if host and self.__class__._FAST_DOMAIN_RE.search(host):
77
+ return True
78
+
79
+ # SLOW PATH: Diğer siteler için yt-dlp'nin native kontrolü
17
80
  try:
18
81
  # stderr'ı geçici olarak kapat (hata mesajlarını gizle)
19
82
  old_stderr = sys.stderr
@@ -51,7 +114,7 @@ class YTDLP(ExtractorBase):
51
114
  ydl_opts = {
52
115
  "quiet" : True,
53
116
  "no_warnings" : True,
54
- "extract_flat" : False, # Tam bilgi al
117
+ "extract_flat" : False, # Tam bilgi al
55
118
  "format" : "best", # En iyi kalite
56
119
  "no_check_certificates" : True
57
120
  }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: KekikStream
3
- Version: 1.9.0
3
+ Version: 1.9.2
4
4
  Summary: terminal üzerinden medya içeriği aramanızı ve VLC/MPV gibi popüler medya oynatıcılar aracılığıyla doğrudan izlemenizi sağlayan modüler ve genişletilebilir bir bıdı bıdı
5
5
  Home-page: https://github.com/keyiflerolsun/KekikStream
6
6
  Author: keyiflerolsun
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: KekikStream
3
- Version: 1.9.0
3
+ Version: 1.9.2
4
4
  Summary: terminal üzerinden medya içeriği aramanızı ve VLC/MPV gibi popüler medya oynatıcılar aracılığıyla doğrudan izlemenizi sağlayan modüler ve genişletilebilir bir bıdı bıdı
5
5
  Home-page: https://github.com/keyiflerolsun/KekikStream
6
6
  Author: keyiflerolsun
@@ -6,7 +6,7 @@ from io import open
6
6
  setup(
7
7
  # ? Genel Bilgiler
8
8
  name = "KekikStream",
9
- version = "1.9.0",
9
+ version = "1.9.2",
10
10
  url = "https://github.com/keyiflerolsun/KekikStream",
11
11
  description = "terminal üzerinden medya içeriği aramanızı ve VLC/MPV gibi popüler medya oynatıcılar aracılığıyla doğrudan izlemenizi sağlayan modüler ve genişletilebilir bir bıdı bıdı",
12
12
  keywords = ["KekikStream", "KekikAkademi", "keyiflerolsun"],
@@ -1,31 +0,0 @@
1
- # Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
2
-
3
- from .ExtractorLoader import ExtractorLoader
4
- from .ExtractorBase import ExtractorBase
5
-
6
- class ExtractorManager:
7
- def __init__(self, extractor_dir="Extractors"):
8
- # Çıkarıcı yükleyiciyi başlat ve tüm çıkarıcıları yükle
9
- self.extractor_loader = ExtractorLoader(extractor_dir)
10
- self.extractors = self.extractor_loader.load_all()
11
-
12
- def find_extractor(self, link) -> ExtractorBase:
13
- # Verilen bağlantıyı işleyebilecek çıkarıcıyı bul
14
- for extractor_cls in self.extractors:
15
- extractor:ExtractorBase = extractor_cls()
16
- if extractor.can_handle_url(link):
17
- return extractor
18
-
19
- return None
20
-
21
- def map_links_to_extractors(self, links) -> dict:
22
- # Bağlantıları uygun çıkarıcılarla eşleştir
23
- mapping = {}
24
- for link in links:
25
- for extractor_cls in self.extractors:
26
- extractor:ExtractorBase = extractor_cls()
27
- if extractor.can_handle_url(link):
28
- mapping[link] = f"{extractor.name:<30} » {link.replace(extractor.main_url, '')}"
29
- break
30
-
31
- return mapping
File without changes
File without changes
File without changes
File without changes