warp-beacon 2.2.42__tar.gz → 2.2.44__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.
- {warp_beacon-2.2.42/warp_beacon.egg-info → warp_beacon-2.2.44}/PKG-INFO +1 -1
- warp_beacon-2.2.44/warp_beacon/__version__.py +2 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/account_selector.py +9 -3
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/instagram/instagram.py +2 -3
- {warp_beacon-2.2.42 → warp_beacon-2.2.44/warp_beacon.egg-info}/PKG-INFO +1 -1
- warp_beacon-2.2.42/warp_beacon/__version__.py +0 -2
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/LICENSE +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/MANIFEST.in +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/README.md +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/assets/placeholder.gif +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/etc/.gitignore +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/etc/accounts.json +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/etc/warp_beacon.conf +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/etc/warp_beacon.service +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/pyproject.toml +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/setup.cfg +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/setup.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/compress/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/compress/video.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/jobs/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/jobs/abstract.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/jobs/download_job.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/jobs/types.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/jobs/upload_job.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/mediainfo/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/mediainfo/abstract.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/mediainfo/audio.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/mediainfo/silencer.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/mediainfo/video.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scheduler/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scheduler/scheduler.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/abstract.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/exceptions.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/instagram/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/youtube/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/youtube/abstract.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/youtube/music.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/youtube/shorts.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/scraper/youtube/youtube.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/storage/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/telegram/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/telegram/bot.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/telegram/handlers.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/telegram/placeholder_message.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/telegram/utils.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/uploader/__init__.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon/warp_beacon.py +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon.egg-info/SOURCES.txt +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon.egg-info/dependency_links.txt +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon.egg-info/entry_points.txt +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon.egg-info/requires.txt +0 -0
- {warp_beacon-2.2.42 → warp_beacon-2.2.44}/warp_beacon.egg-info/top_level.txt +0 -0
@@ -74,11 +74,17 @@ class AccountSelector(object):
|
|
74
74
|
return self.current
|
75
75
|
|
76
76
|
def bump_acc_fail(self, key: str, amount: int = 1) -> int:
|
77
|
-
|
78
|
-
|
77
|
+
try:
|
78
|
+
idx = self.account_index[self.current_module_name].value
|
79
|
+
self.accounts_meta_data[idx][key] += amount
|
80
|
+
return self.accounts_meta_data[idx][key]
|
81
|
+
except Exception as e:
|
82
|
+
logging.warning("Failed to record fail stats")
|
83
|
+
logging.exception(e)
|
79
84
|
|
80
85
|
def how_much(self, key: str) -> int:
|
81
|
-
|
86
|
+
idx = self.account_index[self.current_module_name].value
|
87
|
+
return self.accounts_meta_data[self.current_module_name][idx][key]
|
82
88
|
|
83
89
|
def get_current(self) -> tuple:
|
84
90
|
idx = self.account_index[self.current_module_name].value
|
@@ -237,9 +237,6 @@ class InstagramScraper(ScraperAbstract):
|
|
237
237
|
|
238
238
|
def download(self, url: str) -> Optional[list[dict]]:
|
239
239
|
res = []
|
240
|
-
wait_timeout = int(os.environ.get("IG_WAIT_TIMEOUT", default=60))
|
241
|
-
timeout_increment = int(os.environ.get("IG_TIMEOUT_INCREMENT", default=30))
|
242
|
-
ratelimit_threshold = int(os.environ.get("IG_RATELIMIT_TRESHOLD", default=3))
|
243
240
|
while True:
|
244
241
|
try:
|
245
242
|
scrap_type, media_id = self.scrap(url)
|
@@ -263,6 +260,8 @@ class InstagramScraper(ScraperAbstract):
|
|
263
260
|
except PleaseWaitFewMinutes as e:
|
264
261
|
logging.warning("Please wait a few minutes error.")
|
265
262
|
logging.exception(e)
|
263
|
+
if os.path.exists(self.inst_session_file):
|
264
|
+
os.unlink(self.inst_session_file)
|
266
265
|
raise IGRateLimitOccurred("Instagram ratelimit")
|
267
266
|
except (MediaNotFound, ClientNotFoundError, UserNotFound) as e:
|
268
267
|
raise NotFound(extract_exception_message(e))
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|