From cc5dfcd050e430a3fba0dc83cac6810cc0b60bcd Mon Sep 17 00:00:00 2001 From: wulan17 Date: Wed, 7 Feb 2024 03:50:08 +0700 Subject: [PATCH 1/2] Alice: Update Pyrofork to v2.4.0 Signed-off-by: wulan17 --- alice/alice.py | 2 +- alice/plugins/forward.py | 4 ++-- alice/plugins/misc.py | 2 +- alice/plugins/parser.py | 4 ++-- alice/plugins/raw.py | 2 +- alice/utils/filters.py | 4 ++-- alice/utils/games/epicgames.py | 2 +- alice/utils/games/gog.py | 4 ++-- alice/utils/games/steam.py | 4 ++-- alice/utils/string.py | 2 +- poetry.lock | 8 ++++---- pyproject.toml | 2 +- 12 files changed, 20 insertions(+), 20 deletions(-) diff --git a/alice/alice.py b/alice/alice.py index 7acaacb..5fd0b4e 100644 --- a/alice/alice.py +++ b/alice/alice.py @@ -8,7 +8,7 @@ from apscheduler.schedulers.async_ import AsyncScheduler from apscheduler.triggers.interval import IntervalTrigger from async_pymongo import AsyncClient -from pyrogram import Client, raw +from pyrofork import Client, raw class Alice(Client): def __init__(self): diff --git a/alice/plugins/forward.py b/alice/plugins/forward.py index e98cf43..ea3216d 100644 --- a/alice/plugins/forward.py +++ b/alice/plugins/forward.py @@ -2,8 +2,8 @@ from alice.alice import Alice from alice.utils.string import build_keyboard, parse_button -from pyrogram import enums, filters -from pyrogram.types import InlineKeyboardMarkup +from pyrofork import enums, filters +from pyrofork.types import InlineKeyboardMarkup @Alice.on_message(filters.group & filters.command("settopics")) async def set_topics(c,m): diff --git a/alice/plugins/misc.py b/alice/plugins/misc.py index bd28de2..cd36a38 100644 --- a/alice/plugins/misc.py +++ b/alice/plugins/misc.py @@ -1,5 +1,5 @@ from alice.alice import Alice -from pyrogram import filters +from pyrofork import filters @Alice.on_message(filters.private & filters.command("start")) async def preview(c,m): diff --git a/alice/plugins/parser.py b/alice/plugins/parser.py index e023576..d3b21de 100644 --- a/alice/plugins/parser.py +++ b/alice/plugins/parser.py @@ -3,8 +3,8 @@ from alice.alice import Alice from alice.plugins.forward import forward_m from alice.utils.string import build_keyboard, parse_button -from pyrogram import enums, filters -from pyrogram.types import InlineKeyboardMarkup +from pyrofork import enums, filters +from pyrofork.types import InlineKeyboardMarkup @Alice.on_message(filters.channel, group=1) async def channel_watcher(c,m): diff --git a/alice/plugins/raw.py b/alice/plugins/raw.py index 1cea4fd..d51807f 100644 --- a/alice/plugins/raw.py +++ b/alice/plugins/raw.py @@ -1,5 +1,5 @@ from alice.alice import Alice -from pyrogram import raw +from pyrofork import raw @Alice.on_raw_update() async def _raw(c,u,_,__): diff --git a/alice/utils/filters.py b/alice/utils/filters.py index 927f3d3..8c4c2e1 100644 --- a/alice/utils/filters.py +++ b/alice/utils/filters.py @@ -1,7 +1,7 @@ import asyncio -from pyrogram import enums, filters -from pyrogram.errors import FloodWait +from pyrofork import enums, filters +from pyrofork.errors import FloodWait async def admin_check(_, c, m): if m.sender_chat: diff --git a/alice/utils/games/epicgames.py b/alice/utils/games/epicgames.py index 7429c2c..c18eff8 100644 --- a/alice/utils/games/epicgames.py +++ b/alice/utils/games/epicgames.py @@ -5,7 +5,7 @@ from dateutil import tz from dateutil.parser import parse as parse_time from pathlib import Path -from pyrogram.types import InlineKeyboardButton, InlineKeyboardMarkup, InputMediaPhoto +from pyrofork.types import InlineKeyboardButton, InlineKeyboardMarkup, InputMediaPhoto from typing import Dict # Epic's backend API URL for the free games promotion diff --git a/alice/utils/games/gog.py b/alice/utils/games/gog.py index 60eb49a..2205d1c 100644 --- a/alice/utils/games/gog.py +++ b/alice/utils/games/gog.py @@ -2,8 +2,8 @@ import re from alice import GAME_CHAT from bs4 import BeautifulSoup -from pyrogram import utils -from pyrogram.types import InlineKeyboardButton, InlineKeyboardMarkup +from pyrofork import utils +from pyrofork.types import InlineKeyboardButton, InlineKeyboardMarkup UA = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/115.0" diff --git a/alice/utils/games/steam.py b/alice/utils/games/steam.py index 5101da3..a302a6a 100644 --- a/alice/utils/games/steam.py +++ b/alice/utils/games/steam.py @@ -5,8 +5,8 @@ from alice import GAME_CHAT from bs4 import BeautifulSoup -from pyrogram import utils -from pyrogram.types import InlineKeyboardButton, InlineKeyboardMarkup +from pyrofork import utils +from pyrofork.types import InlineKeyboardButton, InlineKeyboardMarkup UA = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:109.0) Gecko/20100101 Firefox/115.0" STEAM_URL = "https://store.steampowered.com/search/?maxprice=free&specials=1" diff --git a/alice/utils/string.py b/alice/utils/string.py index 97e5809..f8ed127 100644 --- a/alice/utils/string.py +++ b/alice/utils/string.py @@ -1,6 +1,6 @@ import re -from pyrogram.types import InlineKeyboardMarkup, InlineKeyboardButton +from pyrofork.types import InlineKeyboardMarkup, InlineKeyboardButton BTN_URL_REGEX = re.compile(r"(\[([^\[]+?)\]\(btn:(?:/{0,2})(.+?)(:same)?\))") diff --git a/poetry.lock b/poetry.lock index 2ddd7df..02e0a76 100644 --- a/poetry.lock +++ b/poetry.lock @@ -337,13 +337,13 @@ zstd = ["zstandard"] [[package]] name = "pyrofork" -version = "2.3.15" +version = "2.4.0" description = "Fork of pyrogram. Elegant, modern and asynchronous Telegram MTProto API framework in Python for users and bots" optional = false python-versions = "~=3.8" files = [ - {file = "pyrofork-2.3.15-py3-none-any.whl", hash = "sha256:0bd314734f059ea62b0df98a46e48b89a67c61bd8672be70f891e91c0d60f8a3"}, - {file = "pyrofork-2.3.15.tar.gz", hash = "sha256:23cb220921cdb242826058408f19d23d8fd92ff451252ec3e9c63fd5c43aa1f2"}, + {file = "pyrofork-2.4.0-py3-none-any.whl", hash = "sha256:0bc00b39b531d2321e9e57cad106fc4eddc17e09fed3531e3e397c6dcb488d5c"}, + {file = "pyrofork-2.4.0.tar.gz", hash = "sha256:25b6ebcb4b94e26377864739e8899512bb15b96a55540499302bf2d16c3feb38"}, ] [package.dependencies] @@ -558,4 +558,4 @@ test = ["Cython (>=0.29.36,<0.30.0)", "aiohttp (==3.9.0b0)", "aiohttp (>=3.8.1)" [metadata] lock-version = "2.0" python-versions = "~=3.9" -content-hash = "5bf53eb9772a2700882099be07484a6ceb3243c1da3e75f1be82156fc7c13f17" +content-hash = "7bf5f3465f8f36b9ea8241a3a9f86542e16f24478fbedeaa32f4da6e726b9a69" diff --git a/pyproject.toml b/pyproject.toml index 1939541..c19403c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -13,7 +13,7 @@ async-pymongo = "0.1.3" uvloop = "^0.19.0" tgcrypto = "^1.2.5" apscheduler = {git = "https://github.com/agronholm/apscheduler.git", rev = "master"} -pyrofork = "2.3.15" +pyrofork = "2.4.0" python-dotenv = "^1.0.0" httpx = {extras = ["http2"], version = "^0.26.0"} From 53536b5a5287220c64f39f7f7b88362c7fbae1f8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Feb 2024 20:51:16 +0000 Subject: [PATCH 2/2] Bump python-dotenv from 1.0.0 to 1.0.1 Bumps [python-dotenv](https://github.com/theskumar/python-dotenv) from 1.0.0 to 1.0.1. - [Release notes](https://github.com/theskumar/python-dotenv/releases) - [Changelog](https://github.com/theskumar/python-dotenv/blob/main/CHANGELOG.md) - [Commits](https://github.com/theskumar/python-dotenv/compare/v1.0.0...v1.0.1) --- updated-dependencies: - dependency-name: python-dotenv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- poetry.lock | 8 ++++---- pyproject.toml | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/poetry.lock b/poetry.lock index 02e0a76..5e694d2 100644 --- a/poetry.lock +++ b/poetry.lock @@ -370,13 +370,13 @@ files = [ [[package]] name = "python-dotenv" -version = "1.0.0" +version = "1.0.1" description = "Read key-value pairs from a .env file and set them as environment variables" optional = false python-versions = ">=3.8" files = [ - {file = "python-dotenv-1.0.0.tar.gz", hash = "sha256:a8df96034aae6d2d50a4ebe8216326c61c3eb64836776504fcca410e5937a3ba"}, - {file = "python_dotenv-1.0.0-py3-none-any.whl", hash = "sha256:f5971a9226b701070a4bf2c38c89e5a3f0d64de8debda981d1db98583009122a"}, + {file = "python-dotenv-1.0.1.tar.gz", hash = "sha256:e324ee90a023d808f1959c46bcbc04446a10ced277783dc6ee09987c37ec10ca"}, + {file = "python_dotenv-1.0.1-py3-none-any.whl", hash = "sha256:f7b63ef50f1b690dddf550d03497b66d609393b40b564ed0d674909a68ebf16a"}, ] [package.extras] @@ -558,4 +558,4 @@ test = ["Cython (>=0.29.36,<0.30.0)", "aiohttp (==3.9.0b0)", "aiohttp (>=3.8.1)" [metadata] lock-version = "2.0" python-versions = "~=3.9" -content-hash = "7bf5f3465f8f36b9ea8241a3a9f86542e16f24478fbedeaa32f4da6e726b9a69" +content-hash = "2658cfea5900a8b09b4a7219035baf9f485a3bb1676fb011973cf497ecdaeaa8" diff --git a/pyproject.toml b/pyproject.toml index c19403c..8dca74f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,7 +14,7 @@ uvloop = "^0.19.0" tgcrypto = "^1.2.5" apscheduler = {git = "https://github.com/agronholm/apscheduler.git", rev = "master"} pyrofork = "2.4.0" -python-dotenv = "^1.0.0" +python-dotenv = "^1.0.1" httpx = {extras = ["http2"], version = "^0.26.0"}