warp-beacon 2.3.40__py3-none-any.whl → 2.3.41__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.
@@ -1,2 +1,2 @@
1
- __version__ = "2.3.40"
1
+ __version__ = "2.3.41"
2
2
 
@@ -279,7 +279,7 @@ class YoutubeAbstract(ScraperAbstract):
279
279
  logging.warning("Proxy DSN malformed!")
280
280
  return YouTube(**yt_opts)
281
281
 
282
- def build_yt_dlp(self) -> yt_dlp.YoutubeDL:
282
+ def build_yt_dlp(self, timeout: int = 0) -> yt_dlp.YoutubeDL:
283
283
  auth_data = {}
284
284
  with open(self.YT_SESSION_FILE % self.account_index, 'r', encoding="utf-8") as f:
285
285
  auth_data = json.loads(f.read())
@@ -300,10 +300,10 @@ class YoutubeAbstract(ScraperAbstract):
300
300
 
301
301
  return yt_dlp.YoutubeDL(ydl_opts)
302
302
 
303
- def _download(self, _: str) -> list:
303
+ def _download(self, _: str, __: int = 60) -> list:
304
304
  raise NotImplementedError("You should to implement _download method")
305
305
 
306
- def _download_yt_dlp(self, _: str) -> list:
306
+ def _download_yt_dlp(self, _: str, __: int = 60) -> list:
307
307
  raise NotImplementedError("You should to implement _download_yt_dlp method")
308
308
 
309
309
  def download(self, job: DownloadJob) -> list:
@@ -28,7 +28,7 @@ class YoutubeScraper(YoutubeAbstract):
28
28
 
29
29
  return False
30
30
 
31
- def _download(self, url: str, session: bool = True, timeout: int = 0) -> list:
31
+ def _download(self, url: str, session: bool = True, timeout: int = 60) -> list:
32
32
  res = []
33
33
  try:
34
34
  thumbnail = None
@@ -67,7 +67,7 @@ class YoutubeScraper(YoutubeAbstract):
67
67
 
68
68
  return res
69
69
 
70
- def _download_yt_dlp(self, url: str) -> list:
70
+ def _download_yt_dlp(self, url: str, timeout: int = 60) -> list:
71
71
  res = []
72
72
  thumbnail = None
73
73
  video_id = self.get_video_id(url)
@@ -78,6 +78,7 @@ class YoutubeScraper(YoutubeAbstract):
78
78
  local_file = ydl.prepare_filename(info)
79
79
  logging.debug("Temp filename: '%s'", local_file)
80
80
  res.append({
81
+ "socket_timeout": timeout,
81
82
  "local_media_path": local_file,
82
83
  "performer": info.get("uploader", "Unknown"),
83
84
  "thumb": thumbnail,
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: warp_beacon
3
- Version: 2.3.40
3
+ Version: 2.3.41
4
4
  Summary: Telegram bot for expanding external media links
5
5
  Home-page: https://github.com/sb0y/warp_beacon
6
6
  Author: Andrey Bagrintsev
@@ -4,7 +4,7 @@ var/warp_beacon/accounts.json,sha256=OsXdncs6h88xrF_AP6_WDCK1waGBn9SR-uYdIeK37GM
4
4
  var/warp_beacon/placeholder.gif,sha256=cE5CGJVaop4Sx21zx6j4AyoHU0ncmvQuS2o6hJfEH88,6064
5
5
  var/warp_beacon/proxies.json,sha256=VnjlQDXumOEq72ZFjbh6IqHS1TEHqn8HPYAZqWCeSIA,95
6
6
  warp_beacon/__init__.py,sha256=_rThNODmz0nDp_n4mWo_HKaNFE5jk1_7cRhHyYaencI,163
7
- warp_beacon/__version__.py,sha256=OcXHHYWlAUshE_Yj-PGDQ_nKxIqsPouQB_HoWAmNDZA,24
7
+ warp_beacon/__version__.py,sha256=eJo4w0wy-rkbDxnK_FYM-eSEodG5CN8jr8NCff2SMpU,24
8
8
  warp_beacon/warp_beacon.py,sha256=7KEtZDj-pdhtl6m-zFLsSojs1ZR4o7L0xbqtdmYPvfE,342
9
9
  warp_beacon/compress/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
10
  warp_beacon/compress/video.py,sha256=_PDMVYCyzLYxHv1uZmmzGcG_8rjaZr7BTXsXTTy_oS4,2846
@@ -30,10 +30,10 @@ warp_beacon/scraper/link_resolver.py,sha256=Rc9ZuMyOo3iPywDHwjngy-WRQ2SXhJwxcg-5
30
30
  warp_beacon/scraper/instagram/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
31
31
  warp_beacon/scraper/instagram/instagram.py,sha256=TpIBS9S3zcLbeGax4CENVo6WP75EE6oIttc-MjWYVjs,13815
32
32
  warp_beacon/scraper/youtube/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
33
- warp_beacon/scraper/youtube/abstract.py,sha256=RcGmSu9E3o1TKD3EvU3C7y3uBKdHxnk3wEIV06oHWWk,11629
33
+ warp_beacon/scraper/youtube/abstract.py,sha256=rJrcJ9g-BETkDGqbfE7gq5TxpoF2HPxOC_XdpeTJEpA,11675
34
34
  warp_beacon/scraper/youtube/music.py,sha256=6FIU1tqKvW7Osh3jg8fqli2W30Lgp_GM33S9lfOnk0s,1418
35
35
  warp_beacon/scraper/youtube/shorts.py,sha256=k3yGF9b8HTzNE6h4VE0zsMGB6kWP-V2xiLhIY3QZXvs,1269
36
- warp_beacon/scraper/youtube/youtube.py,sha256=AC93ianrdI94VqL0WXAqnkekxLtzyY39N0sMcaNoYEo,2812
36
+ warp_beacon/scraper/youtube/youtube.py,sha256=JX3hHHuWiGK81A8POcc0F1GYr1FLjQyIzrp0Mzy9_dU,2863
37
37
  warp_beacon/storage/__init__.py,sha256=0Vajd0oITKJfu2vmNx5uQSt3-L6vwIvUYWJo8HZCjco,3398
38
38
  warp_beacon/storage/mongo.py,sha256=qC4ZiO8XXvPnP0rJwz4CJx42pqFsyAjCiW10W5QdT6E,527
39
39
  warp_beacon/telegram/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -43,9 +43,9 @@ warp_beacon/telegram/handlers.py,sha256=XXIfdV_RCj7tyZMPXchuKmGoDdweOaR08ADDaBPW
43
43
  warp_beacon/telegram/placeholder_message.py,sha256=wN9-BRiyrtHG-EvXtZkGJHt2CX71munQ57ITttjt0mw,6400
44
44
  warp_beacon/telegram/utils.py,sha256=9uebX53G16mV7ER7WgfdWBLFHHw14S8HBt9URrIskg0,4440
45
45
  warp_beacon/uploader/__init__.py,sha256=E9rlZIf7xlQz6MutMOwJ8S5Vm2uheR5nv23Kv8duRQg,5427
46
- warp_beacon-2.3.40.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
47
- warp_beacon-2.3.40.dist-info/METADATA,sha256=0vPgdw0j-VSzzoSeWP4x16Nz8NS9_3buYiKiUUN40GQ,22626
48
- warp_beacon-2.3.40.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
49
- warp_beacon-2.3.40.dist-info/entry_points.txt,sha256=eSB61Rb89d56WY0O-vEIQwkn18J-4CMrJcLA_R_8h3g,119
50
- warp_beacon-2.3.40.dist-info/top_level.txt,sha256=qGjHVVfyf6lTmbdSA-fQq0rHS1YVS4HoJT3rag5xgPE,1141
51
- warp_beacon-2.3.40.dist-info/RECORD,,
46
+ warp_beacon-2.3.41.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
47
+ warp_beacon-2.3.41.dist-info/METADATA,sha256=S18xumQDMp35RZ49TerDM62XACK9XjEQ-d4N3mS1A_I,22626
48
+ warp_beacon-2.3.41.dist-info/WHEEL,sha256=1tXe9gY0PYatrMPMDd6jXqjfpz_B-Wqm32CPfRC58XU,91
49
+ warp_beacon-2.3.41.dist-info/entry_points.txt,sha256=eSB61Rb89d56WY0O-vEIQwkn18J-4CMrJcLA_R_8h3g,119
50
+ warp_beacon-2.3.41.dist-info/top_level.txt,sha256=qGjHVVfyf6lTmbdSA-fQq0rHS1YVS4HoJT3rag5xgPE,1141
51
+ warp_beacon-2.3.41.dist-info/RECORD,,