diff --git a/bot/helper/ext_utils/jdownloader_booter.py b/bot/helper/ext_utils/jdownloader_booter.py index 52d4ada8ede..b56103c4612 100644 --- a/bot/helper/ext_utils/jdownloader_booter.py +++ b/bot/helper/ext_utils/jdownloader_booter.py @@ -74,7 +74,7 @@ async def boot(self): self.boot() def connect(self): - LOGGER.info(f"Connecting to JDownloader...") + LOGGER.info("Connecting to JDownloader...") try: self.myjd.connect(config_dict["JD_EMAIL"], config_dict["JD_PASS"]) while True: @@ -92,7 +92,7 @@ def connect(self): self.device = self.myjd.get_device(f"{self._device_name}") self.device.enable_direct_connection() self.device.action("/device/ping") - LOGGER.info(f"JDownloader is Connected!") + LOGGER.info("JDownloader is Connected!") except ( MYJDAuthFailedException, MYJDEmailForbiddenException, diff --git a/bot/helper/mirror_utils/download_utils/jd_download.py b/bot/helper/mirror_utils/download_utils/jd_download.py index dade1778a1d..ba3b647e2a5 100644 --- a/bot/helper/mirror_utils/download_utils/jd_download.py +++ b/bot/helper/mirror_utils/download_utils/jd_download.py @@ -70,8 +70,8 @@ async def waitForConfigurations(self): future = self._event_handler() buttons = ButtonMaker() buttons.ubutton("Select", "https://my.jdownloader.org") - buttons.ibutton("Done Selecting", f"jdq sdone") - buttons.ibutton("Cancel", f"jdq cancel") + buttons.ibutton("Done Selecting", "jdq sdone") + buttons.ibutton("Cancel", "jdq cancel") button = buttons.build_menu(2) msg = f"Disable the unwanted files or change variants from myJdownloader site for {self._listener.name} but don't start it manually!\n\nAfter finish press Done Selecting!\nTimeout: 180s" self._reply_to = await sendMessage(self._listener.message, msg, button) diff --git a/bot/modules/clone.py b/bot/modules/clone.py index 0f1fa305557..1d63e787111 100644 --- a/bot/modules/clone.py +++ b/bot/modules/clone.py @@ -7,7 +7,7 @@ from bot import LOGGER, task_dict, task_dict_lock, bot from bot.helper.mirror_utils.gdrive_utils.clone import gdClone from bot.helper.mirror_utils.gdrive_utils.count import gdCount -from bot.helper.ext_utils.help_messages import CLONE_HELP_MESSAGE +from bot.helper.ext_utils.help_messages import CLONE_HELP_MESSAGE, COMMAND_USAGE from bot.helper.telegram_helper.message_utils import ( sendMessage, deleteMessage, @@ -173,7 +173,7 @@ async def _proceedToClone(self): remote, src_path = self.link.split(":", 1) src_path = src_path.strip("/") - cmd = f'rclone lsjson --fast-list --stat --no-modtime --config {config_path} "{remote}:{src_path}"' + cmd = f"rclone lsjson --fast-list --stat --no-modtime --config {config_path} '{remote}:{src_path}'" res = await cmd_exec(cmd, shell=True) if res[2] != 0: if res[2] != -9: @@ -208,10 +208,10 @@ async def _proceedToClone(self): if not flink: return LOGGER.info(f"Cloning Done: {self.name}") - cmd1 = f'rclone lsf --fast-list -R --files-only --config {config_path} "{destination}"' - cmd2 = f'rclone lsf --fast-list -R --dirs-only --config {config_path} "{destination}"' + cmd1 = f"rclone lsf --fast-list -R --files-only --config {config_path} '{destination}'" + cmd2 = f"rclone lsf --fast-list -R --dirs-only --config {config_path} '{destination}'" cmd3 = ( - f'rclone size --fast-list --json --config {config_path} "{destination}"' + f"rclone size --fast-list --json --config {config_path} '{destination}'" ) res1, res2, res3 = await gather( cmd_exec(cmd1, shell=True),