From c531e242c0a8a2cc1ff190b5ecc391229c218fed Mon Sep 17 00:00:00 2001 From: Profitroll <47523801+profitrollgame@users.noreply.github.com> Date: Sun, 14 May 2023 22:09:04 +0200 Subject: [PATCH] Added convopyro support --- main.py | 6 +++++- requirements.txt | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/main.py b/main.py index 5f1ea60..b5b2549 100644 --- a/main.py +++ b/main.py @@ -1,6 +1,10 @@ import logging from os import getpid +# Uncomment this and the line below client declaration +# in order to use context manager in your commands. +# from convopyro import Conversation + from modules.app import PyroClient logging.basicConfig( @@ -21,13 +25,13 @@ except ImportError: def main(): client = PyroClient() + # Conversation(client) try: client.run() except KeyboardInterrupt: logger.warning(f"Forcefully shutting down with PID {getpid()}...") finally: - client.__exit__() exit() diff --git a/requirements.txt b/requirements.txt index cd1ab55..05bfef8 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,6 +1,7 @@ aiofiles~=23.1.0 apscheduler~=3.10.1 black~=23.3.0 +convopyro==0.5 pyrogram~=2.0.102 tgcrypto==1.2.5 ujson==5.7.0