Skip to content

Commit

Permalink
Merge pull request #1649 from R4ndomUsers/master
Browse files Browse the repository at this point in the history
Forgot
  • Loading branch information
anasty17 authored Dec 29, 2023
2 parents 2d65316 + b553a5d commit 2bb8075
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions bot/helper/ext_utils/jdownloader_booter.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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,
Expand Down
4 changes: 2 additions & 2 deletions bot/helper/mirror_utils/download_utils/jd_download.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 <b>{self._listener.name}</b> but don't start it manually!\n\nAfter finish press Done Selecting!\nTimeout: 180s"
self._reply_to = await sendMessage(self._listener.message, msg, button)
Expand Down
10 changes: 5 additions & 5 deletions bot/modules/clone.py
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down Expand Up @@ -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:
Expand Down Expand Up @@ -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),
Expand Down

0 comments on commit 2bb8075

Please sign in to comment.