KekikStream 0.1.4__py3-none-any.whl → 0.1.6__py3-none-any.whl

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.
@@ -0,0 +1,61 @@
1
+ # Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
2
+
3
+ from KekikStream.Core import ExtractorBase, ExtractResult, Subtitle
4
+ from Kekik.Sifreleme import Packer, HexCodec
5
+ import re
6
+
7
+ class RapidVid(ExtractorBase):
8
+ name = "RapidVid"
9
+ main_url = "https://rapidvid.net"
10
+
11
+ async def extract(self, url, referer=None) -> ExtractResult:
12
+ if referer:
13
+ self.oturum.headers.update({"Referer": referer})
14
+
15
+ istek = await self.oturum.get(url)
16
+ istek.raise_for_status()
17
+
18
+ subtitles = []
19
+ subtitle_matches = re.findall(r'captions\",\"file\":\"([^\"]+)\",\"label\":\"([^\"]+)\"', istek.text)
20
+ seen_subtitles = set()
21
+
22
+ for sub_url, sub_lang in subtitle_matches:
23
+ if sub_url in seen_subtitles:
24
+ continue
25
+ seen_subtitles.add(sub_url)
26
+
27
+ decoded_lang = (
28
+ sub_lang.replace("\\u0131", "ı")
29
+ .replace("\\u0130", "İ")
30
+ .replace("\\u00fc", "ü")
31
+ .replace("\\u00e7", "ç")
32
+ )
33
+ subtitles.append(Subtitle(name=decoded_lang, url=sub_url.replace("\\", "")))
34
+
35
+ try:
36
+ extracted_value = re.search(r'file": "(.*)",', istek.text)
37
+ if extracted_value:
38
+ escaped_hex = extracted_value.group(1)
39
+ decoded_url = HexCodec.decode(escaped_hex)
40
+ else:
41
+ eval_jwsetup = re.search(r'\};\s*(eval\(function[\s\S]*?)var played = \d+;', istek.text)
42
+ if not eval_jwsetup:
43
+ raise ValueError("JWPlayer setup not found.")
44
+
45
+ unpacked_jwsetup = Packer.unpack(Packer.unpack(eval_jwsetup.group(1)))
46
+ extracted_value = re.search(r'file":"(.*)","label', unpacked_jwsetup)
47
+ if not extracted_value:
48
+ raise ValueError("File URL not found in unpacked JWPlayer setup.")
49
+
50
+ escaped_hex = extracted_value.group(1).replace("\\\\x", "")
51
+ decoded_url = bytes.fromhex(escaped_hex).decode("utf-8")
52
+ except Exception as e:
53
+ raise RuntimeError(f"Extraction failed: {e}")
54
+
55
+ await self.close()
56
+ return ExtractResult(
57
+ name = self.name,
58
+ url = decoded_url,
59
+ referer = self.main_url,
60
+ subtitles = subtitles
61
+ )
@@ -0,0 +1,28 @@
1
+ # Bu araç @keyiflerolsun tarafından | @KekikAkademi için yazılmıştır.
2
+
3
+ from KekikStream.Core import ExtractorBase, ExtractResult
4
+ import re
5
+
6
+ class TurboImgz(ExtractorBase):
7
+ name = "TurboImgz"
8
+ main_url = "https://turbo.imgz.me"
9
+
10
+ async def extract(self, url, referer=None) -> ExtractResult:
11
+ if referer:
12
+ self.oturum.headers.update({"Referer": referer})
13
+
14
+ istek = await self.oturum.get(url)
15
+ istek.raise_for_status()
16
+
17
+ video_match = re.search(r'file: "(.*)",', istek.text)
18
+ if not video_match:
19
+ raise ValueError("File not found in response.")
20
+
21
+ video_link = video_match.group(1)
22
+
23
+ return ExtractResult(
24
+ name = self.name,
25
+ url = video_link,
26
+ referer = referer or self.main_url,
27
+ subtitles = []
28
+ )
@@ -13,15 +13,16 @@ class UIManager:
13
13
 
14
14
  @staticmethod
15
15
  async def select_from_list(message, choices):
16
- return await inquirer.select(message=message, choices=choices).execute_async()
16
+ return await inquirer.select(message=message, choices=choices, max_height="75%").execute_async()
17
17
 
18
18
  @staticmethod
19
19
  async def select_from_fuzzy(message, choices):
20
20
  return await inquirer.fuzzy(
21
- message = message,
22
- choices = choices,
23
- validate = lambda result: result in [choice if isinstance(choice, str) else choice["value"] for choice in choices],
24
- filter = lambda result: result
21
+ message = message,
22
+ choices = choices,
23
+ validate = lambda result: result in [choice if isinstance(choice, str) else choice["value"] for choice in choices],
24
+ filter = lambda result: result,
25
+ max_height = "75%"
25
26
  ).execute_async()
26
27
 
27
28
  @staticmethod
KekikStream/__init__.py CHANGED
@@ -115,6 +115,8 @@ class KekikStream:
115
115
  async def show_options(self, links):
116
116
  mapping = self.extractor_manager.map_links_to_extractors(links)
117
117
  has_play_method = hasattr(self.current_plugin, "play") and callable(getattr(self.current_plugin, "play", None))
118
+ # ! DEBUG
119
+ # konsol.print(links)
118
120
  if not mapping and not has_play_method:
119
121
  konsol.print("[bold red]Hiçbir Extractor bulunamadı![/bold red]")
120
122
  konsol.print(links)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: KekikStream
3
- Version: 0.1.4
3
+ Version: 0.1.6
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,4 +1,4 @@
1
- KekikStream/__init__.py,sha256=2WkuSFmzMV_NULu_-9CHsba4kD4xNMfDS622WMzPSOA,8819
1
+ KekikStream/__init__.py,sha256=VohE_1sY2tvvA0mAKDGQf5VxcDdlip52kJLWfE0S39A,8867
2
2
  KekikStream/__main__.py,sha256=4U-NO1f0Mts5Mf_QnWhWqRbTsRBy2y2VPlpHyaqG9_I,137
3
3
  KekikStream/requirements.txt,sha256=Kh3E0NzIkAmhVODtIwRVffVOHLiElO6Ua9kIgjbocPE,57
4
4
  KekikStream/CLI/__init__.py,sha256=9YlF135BVff85y492hX4sq2WY2CNqa4BuVzF9hIIaKE,233
@@ -13,19 +13,21 @@ KekikStream/Core/PluginModels.py,sha256=-V4Be9ebnUQsQtGzLxg0kGK13RJTmpB7bvAUwsE-
13
13
  KekikStream/Core/__init__.py,sha256=HZpXs3MKy4joO0sDpIGcZ2DrUKwK49IKG-GQgKbO2jk,416
14
14
  KekikStream/Extractors/CloseLoad.py,sha256=YmDB3YvuDaCUbQ0T_tmhnkEsC5mSdEN6GNoAR662fl8,990
15
15
  KekikStream/Extractors/MailRu.py,sha256=lB3Xy912EaSEUw7Im65L5TwtIeM7OLFV1_9lan39g40,1308
16
+ KekikStream/Extractors/RapidVid.py,sha256=HmSXDWhE1EXZRhNCxrqqEBbyJKbqFtTFRtq-zYg3G2c,2430
17
+ KekikStream/Extractors/TurboImgz.py,sha256=0d9t6bj4prVt1_LIbzwcfuqrSRB7SMvc4RKvE25BtW4,851
16
18
  KekikStream/Extractors/VidMoxy.py,sha256=UnVrCEI4XNiONE2aLV9dGUhRqQ9ELJTnYVXyG81N11A,1800
17
19
  KekikStream/Managers/ExtractorManager.py,sha256=4p5VaERx3qIIzvti9gl_khkCWYcVnzUNORmMP-OrQu0,925
18
20
  KekikStream/Managers/MediaManager.py,sha256=F7mkSvAttAaMHRvnDcxnV2K1D_sK644BCSrEaAmMl_U,522
19
21
  KekikStream/Managers/PluginManager.py,sha256=YDBLHB_Fh79A3Pei0ny2KLVY4VSihdNiKBh_w5tBl-0,637
20
- KekikStream/Managers/UIManager.py,sha256=8paUE-ocnakckuTXwVrbWvEbioDaVVNnb0zIQCyBMsg,1532
22
+ KekikStream/Managers/UIManager.py,sha256=PmGabWjHACnaOZLyIfOd0j4cfqpuV34RO58QeeIbF6E,1590
21
23
  KekikStream/Managers/__init__.py,sha256=3085I_9Sa2L_Vq6Z-QvYUYn1BapkN4sQqBo8ITZoD_4,251
22
24
  KekikStream/Plugins/FilmMakinesi.py,sha256=g4LRDP5Atn97PqbgnEdm0-wjVdXaJIVk1Ru0F8B66Ws,2902
23
25
  KekikStream/Plugins/FullHDFilmizlesene.py,sha256=HJzHDXHhhMpvXxiD2SjpoZEYs7dmnPymE8EXCSvLKVo,3106
24
26
  KekikStream/Plugins/SineWix.py,sha256=RJxggTrZxBimQHI4ehtJipVeIBpfHy85NW-ixE2iF2k,4762
25
27
  KekikStream/Plugins/UgurFilm.py,sha256=U7ryNWpjSZJWuYlMGX1Be9uuyiM3SfuI9VJcEiXedNs,2960
26
- KekikStream-0.1.4.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
27
- KekikStream-0.1.4.dist-info/METADATA,sha256=bNR32dNy170g0oPnuyWM3i-fhJ_NsYkW9a4Zu7bYc3k,3961
28
- KekikStream-0.1.4.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
29
- KekikStream-0.1.4.dist-info/entry_points.txt,sha256=dFwdiTx8djyehI0Gsz-rZwjAfZzUzoBSrmzRu9ubjJc,50
30
- KekikStream-0.1.4.dist-info/top_level.txt,sha256=DNmGJDXl27Drdfobrak8KYLmocW_uznVYFJOzcjUgmY,12
31
- KekikStream-0.1.4.dist-info/RECORD,,
28
+ KekikStream-0.1.6.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
29
+ KekikStream-0.1.6.dist-info/METADATA,sha256=txCCc53AvNTTM10timegyEEnf2htwu4jXDk7-6hTH7g,3961
30
+ KekikStream-0.1.6.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
31
+ KekikStream-0.1.6.dist-info/entry_points.txt,sha256=dFwdiTx8djyehI0Gsz-rZwjAfZzUzoBSrmzRu9ubjJc,50
32
+ KekikStream-0.1.6.dist-info/top_level.txt,sha256=DNmGJDXl27Drdfobrak8KYLmocW_uznVYFJOzcjUgmY,12
33
+ KekikStream-0.1.6.dist-info/RECORD,,