From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on gnuweeb.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=5.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NO_DNS_FOR_FROM,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 Received: from localhost.localdomain (unknown [101.128.125.94]) by gnuweeb.org (Postfix) with ESMTPSA id F2A6E7FE95; Thu, 21 Jul 2022 23:30:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gnuweeb.org; s=default; t=1658446212; bh=3pUbeeuYd9pic/qqSnpJiTTjt7DS7QTgMAWO1J/Xd18=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=L93H797L9Gu3PAOW4odQBOvc8JAoKOqvxawhvW+xm4RzxpcGvPzGA7Hq5DOuQWP6X OxhaptELbiZ1xns/AxoE6FOqdLLGy/nwk59mrOFEG/gKtoK1og+fp0klK9w5srHlxG LWGRgH5gIKjAJkpN2yWbHJCoS6BXCgcyIdRIIutWxLfNp1fK12Uo8qo7bYVxU6AuOC gi4mJHAXRxwbu7UugaCTEyFMq2uVtLJC3QdyXg25jtvUIO4ga3Jn7xDne45zj11f7F R4jyt8E/i3jhS65QRtO4cDV1U6VKTmuKcDGLE42pVgc41jsKKmo1tvSM1lLXRmFq63 Eo5Pf6jiVRh2w== From: Muhammad Rizki To: Ammar Faizi Cc: Muhammad Rizki , GNU/Weeb Mailing List Subject: [PATCH v3 08/17] Move ____send_patch_msg Date: Fri, 22 Jul 2022 06:29:29 +0700 Message-Id: <20220721232938.503-9-kiizuha@gnuweeb.org> X-Mailer: git-send-email 2.34.1.windows.1 In-Reply-To: <20220721232938.503-1-kiizuha@gnuweeb.org> References: <20220721232938.503-1-kiizuha@gnuweeb.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit List-Id: From: Muhammad Rizki I want to move the ____send_patch_msg into the DaemonClient, so it much cleaner if we separate the send email message into the DaemonClient. Signed-off-by: Muhammad Rizki --- daemon/scraper/bot.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/daemon/scraper/bot.py b/daemon/scraper/bot.py index 93e633a..4903fef 100644 --- a/daemon/scraper/bot.py +++ b/daemon/scraper/bot.py @@ -233,20 +233,3 @@ class Bot(): n = int(x.group(1)) print(f"[____handle_telegram_floodwait]: Sleeping for {n} seconds due to Telegram limit") await asyncio.sleep(n) - - - async def ____send_patch_msg(self, tg_chat_id, reply_to, fnm, caption, - url): - return await self.client.send_document( - tg_chat_id, - fnm, - caption=caption, - reply_to_message_id=reply_to, - parse_mode=enums.ParseMode.HTML, - reply_markup=InlineKeyboardMarkup([ - [InlineKeyboardButton( - "See the full message", - url=url - )] - ]) - ) -- Muhammad Rizki