mirror of
https://github.com/pyrogram/pyrogram
synced 2025-09-08 18:25:16 +00:00
Make session leaner by removing some redundant parameters
Related to #86
This commit is contained in:
@@ -16,17 +16,34 @@
|
||||
# You should have received a copy of the GNU Lesser General Public License
|
||||
# along with Pyrogram. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import platform
|
||||
import re
|
||||
from queue import Queue
|
||||
from threading import Lock
|
||||
|
||||
from pyrogram import __version__
|
||||
from ..style import Markdown, HTML
|
||||
from ...api.core import Object
|
||||
from ...session.internals import MsgId
|
||||
from ...session import Session
|
||||
from ...session.internals import MsgId
|
||||
|
||||
|
||||
class BaseClient:
|
||||
APP_VERSION = "Pyrogram \U0001f525 {}".format(__version__)
|
||||
|
||||
DEVICE_MODEL = "{} {}".format(
|
||||
platform.python_implementation(),
|
||||
platform.python_version()
|
||||
)
|
||||
|
||||
SYSTEM_VERSION = "{} {}".format(
|
||||
platform.system(),
|
||||
platform.release()
|
||||
)
|
||||
|
||||
SYSTEM_LANG_CODE = "en"
|
||||
LANG_CODE = "en"
|
||||
|
||||
INVITE_LINK_RE = re.compile(r"^(?:https?://)?(?:www\.)?(?:t(?:elegram)?\.(?:org|me|dog)/joinchat/)([\w-]+)$")
|
||||
BOT_TOKEN_RE = re.compile(r"^\d+:[\w-]+$")
|
||||
DIALOGS_AT_ONCE = 100
|
||||
|
Reference in New Issue
Block a user