Update base.py

This commit is contained in:
Andrei 2024-10-05 21:12:53 +03:00
parent becaa663b5
commit 4be8d30d65
1 changed files with 0 additions and 5 deletions

View File

@ -150,14 +150,9 @@ class BaseCaptcha:
elif captcha_link: elif captcha_link:
try: try:
content = self.url_open(url=captcha_link, **kwargs).content content = self.url_open(url=captcha_link, **kwargs).content
logging.warning(f"{save_format = }")
logging.warning(f"{save_format == SaveFormatsEnm.CONST.value = }")
logging.warning(f"{save_format == SaveFormatsEnm.CONST = }")
# according to the value of the passed parameter, select the function to save the image # according to the value of the passed parameter, select the function to save the image
if save_format == SaveFormatsEnm.CONST.value: if save_format == SaveFormatsEnm.CONST.value:
logging.warning(f"TRY TO CREATE FOLDER WITH FILE")
self._file_const_saver(content, file_path, file_extension=file_extension) self._file_const_saver(content, file_path, file_extension=file_extension)
logging.warning(f"TRY TO CREATE FOLDER")
self.create_task_payload.task.update({"body": base64.b64encode(content).decode("utf-8")}) self.create_task_payload.task.update({"body": base64.b64encode(content).decode("utf-8")})
except Exception as error: except Exception as error:
self.result.errorId = 12 self.result.errorId = 12