Skip to content

Commit

Permalink
fix: update functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
Gagik Harutyunyan committed Jan 17, 2024
1 parent 3ca1e59 commit c1b4070
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ ENV DEBIAN_FRONTEND=noninteractive
RUN apt -qq update && apt -qq install -y git python3 python3-pip ffmpeg
COPY . .
RUN pip3 install --no-cache-dir -r requirements.txt
# Or for Windows
# Or for Windows uncomment
# RUN apt-get update && apt-get install -y dos2unix
# RUN dos2unix bash.sh && pip3 install --no-cache-dir -r requirements.txt
CMD ["bash","bash.sh"]
1 change: 0 additions & 1 deletion main/plugins/batch.py
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,3 @@ async def run_batch(userbot, client, sender, link, _range):
protection = await client.send_message(sender, f"Sleeping for `{timer}` seconds to avoid Floodwaits and Protect account!")
await asyncio.sleep(timer)
await protection.delete()

1 change: 0 additions & 1 deletion main/plugins/frontend.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,3 @@ async def clone(event):
except Exception as e:
print(e)
await Drone.send_message(event.sender_id, f"An error occurred during cloning of `{link}`\n\n**Error:** {str(e)}")

2 changes: 1 addition & 1 deletion main/plugins/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@ async def screenshot(video, duration, sender):
if os.path.isfile(out):
return out
else:
None
None
7 changes: 4 additions & 3 deletions main/plugins/pyroplug.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,16 +201,17 @@ async def get_msg(userbot, client, bot, sender, edit_id, msg_link, i):
edit = await client.edit_message_text(sender, edit_id, "Cloning.")
chat = msg_link.split("t.me")[1].split("/")[1]
try:
msg = await client.copy_message(sender, chat, msg_id)
msg = await client.get_messages(chat, msg_id)
if msg.empty:
new_link = f't.me/b/{chat}/{int(msg_id)}'
#recurrsion
return await get_msg(userbot, client, bot, sender, edit_id, new_link, i)
await client.copy_message(sender, chat, msg_id)
except Exception as e:
print(e)
return await client.edit_message_text(sender, edit_id, f'Failed to save: `{msg_link}`\n\nError: {str(e)}')
await edit.delete()

async def get_bulk_msg(userbot, client, sender, msg_link, i):
x = await client.send_message(sender, "Processing!")
await get_msg(userbot, client, Drone, sender, x.id, msg_link, i)
await get_msg(userbot, client, Drone, sender, x.id, msg_link, i)
6 changes: 3 additions & 3 deletions okteto-stack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ services:
drone-srcb:
build: .
environment:
API_ID: $API_ID
API_HASH: $API_HASH
BOT_TOKEN: $BOT_TOKEN
API_ID: $API_ID
API_HASH: $API_HASH
BOT_TOKEN: $BOT_TOKEN
SESSION: $SESSION
AUTH: $AUTH
FORCESUB: $FORCESUB
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#Github.com-Vasusen-code

https://github.com/vasusen-code/Telethon/archive/refs/tags/v1.24.0.zip
https://github.com/gagharutyunyan1993/ethon/archive/refs/tags/v1.3.8.zip
https://github.com/gagharutyunyan1993/ethon/archive/refs/tags/v1.3.9.zip
cryptg
tgcrypto
pyrogram==1.4.16
pyrogram
python-decouple

0 comments on commit c1b4070

Please sign in to comment.