warp-beacon 2.2.41__py3-none-any.whl → 2.2.42__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.
- warp_beacon/__version__.py +1 -1
- warp_beacon/scheduler/scheduler.py +2 -2
- warp_beacon/scraper/instagram/instagram.py +2 -21
- warp_beacon/scraper/youtube/abstract.py +1 -1
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/METADATA +1 -1
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/RECORD +10 -10
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/LICENSE +0 -0
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/WHEEL +0 -0
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/entry_points.txt +0 -0
- {warp_beacon-2.2.41.dist-info → warp_beacon-2.2.42.dist-info}/top_level.txt +0 -0
warp_beacon/__version__.py
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
__version__ = "2.2.
|
1
|
+
__version__ = "2.2.42"
|
2
2
|
|
@@ -15,7 +15,7 @@ class IGScheduler(object):
|
|
15
15
|
running = True
|
16
16
|
thread = None
|
17
17
|
event = None
|
18
|
-
state = {"remaining": randrange(
|
18
|
+
state = {"remaining": randrange(8400, 26200)}
|
19
19
|
|
20
20
|
def __init__(self, downloader: warp_beacon.scraper.AsyncDownloader) -> None:
|
21
21
|
self.downloader = downloader
|
@@ -82,7 +82,7 @@ class IGScheduler(object):
|
|
82
82
|
while self.running:
|
83
83
|
try:
|
84
84
|
if self.state["remaining"] <= 0:
|
85
|
-
self.state["remaining"] = randrange(
|
85
|
+
self.state["remaining"] = randrange(8400, 26200)
|
86
86
|
logging.info("Next scheduler activity in '%s' seconds", self.state["remaining"])
|
87
87
|
|
88
88
|
start_time = time.time()
|
@@ -240,7 +240,6 @@ class InstagramScraper(ScraperAbstract):
|
|
240
240
|
wait_timeout = int(os.environ.get("IG_WAIT_TIMEOUT", default=60))
|
241
241
|
timeout_increment = int(os.environ.get("IG_TIMEOUT_INCREMENT", default=30))
|
242
242
|
ratelimit_threshold = int(os.environ.get("IG_RATELIMIT_TRESHOLD", default=3))
|
243
|
-
please_wait_few_minutes_count = 1
|
244
243
|
while True:
|
245
244
|
try:
|
246
245
|
scrap_type, media_id = self.scrap(url)
|
@@ -262,27 +261,9 @@ class InstagramScraper(ScraperAbstract):
|
|
262
261
|
res.append(self.download_stories(self.scrap_stories(media_id)))
|
263
262
|
break
|
264
263
|
except PleaseWaitFewMinutes as e:
|
265
|
-
|
266
|
-
logging.warning("Please wait a few minutes error. Trying to relogin ...")
|
264
|
+
logging.warning("Please wait a few minutes error.")
|
267
265
|
logging.exception(e)
|
268
|
-
|
269
|
-
logging.warning("IG ratelimit occurred")
|
270
|
-
raise IGRateLimitOccurred()
|
271
|
-
wait_timeout += timeout_increment
|
272
|
-
logging.info("Waiting %d seconds according configuration option `IG_WAIT_TIMEOUT` with `IG_TIMEOUT_INCREMENT`", wait_timeout)
|
273
|
-
if res:
|
274
|
-
for i in res:
|
275
|
-
if i["media_type"] == JobType.COLLECTION:
|
276
|
-
for j in i["items"]:
|
277
|
-
if os.path.exists(j["local_media_path"]):
|
278
|
-
os.unlink(j["local_media_path"])
|
279
|
-
else:
|
280
|
-
if os.path.exists(i["local_media_path"]):
|
281
|
-
os.unlink(i["local_media_path"])
|
282
|
-
if os.path.exists(self.inst_session_file):
|
283
|
-
os.unlink(self.inst_session_file)
|
284
|
-
self.login()
|
285
|
-
time.sleep(wait_timeout)
|
266
|
+
raise IGRateLimitOccurred("Instagram ratelimit")
|
286
267
|
except (MediaNotFound, ClientNotFoundError, UserNotFound) as e:
|
287
268
|
raise NotFound(extract_exception_message(e))
|
288
269
|
except IGUnknownError as e:
|
@@ -132,7 +132,7 @@ class YoutubeAbstract(ScraperAbstract):
|
|
132
132
|
return size[0] // gcd, size[1] // gcd
|
133
133
|
|
134
134
|
def download_thumbnail(self, video_id: str, timeout: int) -> Optional[io.BytesIO]:
|
135
|
-
for i in ("https://img.youtube.com/vi/{VIDEO_ID}/maxresdefault.jpg",
|
135
|
+
for i in (#"https://img.youtube.com/vi/{VIDEO_ID}/maxresdefault.jpg",
|
136
136
|
"https://img.youtube.com/vi/{VIDEO_ID}/hqdefault.jpg",
|
137
137
|
"https://img.youtube.com/vi/{VIDEO_ID}/sddefault.jpg"):
|
138
138
|
try:
|
@@ -3,7 +3,7 @@ lib/systemd/system/warp_beacon.service,sha256=lPmHqLqcI2eIV7nwHS0qcALQrznixqJuww
|
|
3
3
|
var/warp_beacon/accounts.json,sha256=2QQMS9N_Z-TnfZq4U1vSUe4IKyZGmTFdgo8BoF4hQ7E,1710
|
4
4
|
var/warp_beacon/placeholder.gif,sha256=cE5CGJVaop4Sx21zx6j4AyoHU0ncmvQuS2o6hJfEH88,6064
|
5
5
|
warp_beacon/__init__.py,sha256=_rThNODmz0nDp_n4mWo_HKaNFE5jk1_7cRhHyYaencI,163
|
6
|
-
warp_beacon/__version__.py,sha256=
|
6
|
+
warp_beacon/__version__.py,sha256=GjwTJOUfaTTwWSrJrrNTFpTM9rXHUkuTkNUOo7vj1HA,24
|
7
7
|
warp_beacon/warp_beacon.py,sha256=7KEtZDj-pdhtl6m-zFLsSojs1ZR4o7L0xbqtdmYPvfE,342
|
8
8
|
warp_beacon/compress/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
9
9
|
warp_beacon/compress/video.py,sha256=_PDMVYCyzLYxHv1uZmmzGcG_8rjaZr7BTXsXTTy_oS4,2846
|
@@ -18,15 +18,15 @@ warp_beacon/mediainfo/audio.py,sha256=ous88kwQj4bDIChN5wnGil5LqTs0IQHH0d-nyrL0-Z
|
|
18
18
|
warp_beacon/mediainfo/silencer.py,sha256=MgUc9Ibbhjhg9GbJMNfJqrdDkMsQShZkQ1sCwvW_-qI,1647
|
19
19
|
warp_beacon/mediainfo/video.py,sha256=DXHiWAOyJPSVXQ0OP7uOBikUFT7noFmMaMSIx04Mhs4,2506
|
20
20
|
warp_beacon/scheduler/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
21
|
-
warp_beacon/scheduler/scheduler.py,sha256=
|
21
|
+
warp_beacon/scheduler/scheduler.py,sha256=F9jF6myIHOI0TmC0-rBt2Un8gVvuhBW9zL-nEAEj0Bc,2585
|
22
22
|
warp_beacon/scraper/__init__.py,sha256=58zSy74g1LY02HLEwP497a3ABg7f_LGxR6peKSt8dpI,15808
|
23
23
|
warp_beacon/scraper/abstract.py,sha256=aNZ9ypF9B8BjflcIwi-7wEzIqF-XPeF0xvfX9CP_iIw,2708
|
24
24
|
warp_beacon/scraper/account_selector.py,sha256=MbDJRuHr-1ebWwzEg4tTXuEZWAuwpJsgo0lI-LXEzVM,3552
|
25
25
|
warp_beacon/scraper/exceptions.py,sha256=fHywTm2-y2RkgM6hVz12CkDMBgHcEoN2a1TBLaVM2t4,1300
|
26
26
|
warp_beacon/scraper/instagram/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
27
|
-
warp_beacon/scraper/instagram/instagram.py,sha256=
|
27
|
+
warp_beacon/scraper/instagram/instagram.py,sha256=ePAlN4SdpFJ-7eUkDL3TIgPQ8NP6yntzgy4p4xK1k4I,12997
|
28
28
|
warp_beacon/scraper/youtube/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
29
|
-
warp_beacon/scraper/youtube/abstract.py,sha256=
|
29
|
+
warp_beacon/scraper/youtube/abstract.py,sha256=4Le9xA0OF7yidpGXnhwT4bVdW04zlNUIDFPOgEgFjbo,7858
|
30
30
|
warp_beacon/scraper/youtube/music.py,sha256=nbTDFdgXGbTNqttE828DEgvSc8-SuAsQAHeqUwU6yFM,1484
|
31
31
|
warp_beacon/scraper/youtube/shorts.py,sha256=RqMYDq4XHChtp-LdlxXyHej4h3NI3Qi9T8USxwk-pIk,1177
|
32
32
|
warp_beacon/scraper/youtube/youtube.py,sha256=JvN5pVz0jtxCY9FGMl1dIg5Ccr2Kulaoxtym0Vb1QwQ,2224
|
@@ -37,9 +37,9 @@ warp_beacon/telegram/handlers.py,sha256=xSNG_v4D4FaA5q1_5wXvJkjcDUhy5GaQnfpijJZp
|
|
37
37
|
warp_beacon/telegram/placeholder_message.py,sha256=32U-R_IMPRJd-S5UwlpemLkArJOxCmO7whcynduSbMA,6418
|
38
38
|
warp_beacon/telegram/utils.py,sha256=CeWXMwyzv2l4Af6I-wW2ySU490c-5k82sBhkjabv0n4,2452
|
39
39
|
warp_beacon/uploader/__init__.py,sha256=rbfsm_eYcfsBRkiaG0glVgBNtQCEe7cVQTWEIAHz5aw,4763
|
40
|
-
warp_beacon-2.2.
|
41
|
-
warp_beacon-2.2.
|
42
|
-
warp_beacon-2.2.
|
43
|
-
warp_beacon-2.2.
|
44
|
-
warp_beacon-2.2.
|
45
|
-
warp_beacon-2.2.
|
40
|
+
warp_beacon-2.2.42.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
41
|
+
warp_beacon-2.2.42.dist-info/METADATA,sha256=lBWZXL1R2HL4aIFw6HgaAXidMaz3CCF24pPoE3dXrkM,21251
|
42
|
+
warp_beacon-2.2.42.dist-info/WHEEL,sha256=OVMc5UfuAQiSplgO0_WdW7vXVGAt9Hdd6qtN4HotdyA,91
|
43
|
+
warp_beacon-2.2.42.dist-info/entry_points.txt,sha256=eSB61Rb89d56WY0O-vEIQwkn18J-4CMrJcLA_R_8h3g,119
|
44
|
+
warp_beacon-2.2.42.dist-info/top_level.txt,sha256=ALb_Ft_eG-OY4_m0TWUifNUOZsrx483L-zw7G7vqXoc,971
|
45
|
+
warp_beacon-2.2.42.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|