mirror of
https://github.com/python-telegram-bot/python-telegram-bot.git
synced 2024-11-23 07:38:58 +01:00
Bump version to v21.2
This commit is contained in:
parent
512a0b7417
commit
6fc45a803d
28 changed files with 188 additions and 136 deletions
52
CHANGES.rst
52
CHANGES.rst
|
@ -4,6 +4,58 @@
|
|||
Changelog
|
||||
=========
|
||||
|
||||
Version 21.2
|
||||
============
|
||||
|
||||
*Released 2024-05-20*
|
||||
|
||||
This is the technical changelog for version 21.2. More elaborate release notes can be found in the news channel `@pythontelegrambotchannel <https://t.me/pythontelegrambotchannel>`_.
|
||||
|
||||
Major Changes
|
||||
-------------
|
||||
|
||||
- Full Support for Bot API 7.3 (:pr:`4246`, :pr:`4260`, :pr:`4243`, :pr:`4248`, :pr:`4242` closes :issue:`4236`, :pr:`4247` by `aelkheir <https://github.com/aelkheir>`_)
|
||||
- Remove Functionality Deprecated by Bot API 7.2 (:pr:`4245`)
|
||||
|
||||
New Features
|
||||
------------
|
||||
|
||||
- Add Version to ``PTBDeprecationWarning`` (:pr:`4262` closes :issue:`4261`)
|
||||
- Handle Exceptions in building ``CallbackContext`` (:pr:`4222`)
|
||||
|
||||
Bug Fixes
|
||||
---------
|
||||
|
||||
- Call ``Application.post_stop`` Only if ``Application.stop`` was called (:pr:`4211` closes :issue:`4210`)
|
||||
- Handle ``SystemExit`` raised in Handlers (:pr:`4157` closes :issue:`4155` and :issue:`4156`)
|
||||
- Make ``Birthdate.to_date`` Return a ``datetime.date`` Object (:pr:`4251`)
|
||||
|
||||
Documentation Improvements
|
||||
--------------------------
|
||||
|
||||
- Documentation Improvements (:pr:`4217`)
|
||||
|
||||
Internal Changes
|
||||
----------------
|
||||
|
||||
- Add New Rules to ``ruff`` Config (:pr:`4250`)
|
||||
- Adapt Test Suite to Changes in Error Messages (:pr:`4238`)
|
||||
|
||||
Dependency Updates
|
||||
------------------
|
||||
|
||||
- Bump ``furo`` from 2024.4.27 to 2024.5.6 (:pr:`4252`)
|
||||
- ``pre-commit`` autoupdate (:pr:`4239`)
|
||||
- Bump ``pytest`` from 8.1.1 to 8.2.0 (:pr:`4231`)
|
||||
- Bump ``dependabot/fetch-metadata`` from 2.0.0 to 2.1.0 (:pr:`4228`)
|
||||
- Bump ``pytest-asyncio`` from 0.21.1 to 0.21.2 (:pr:`4232`)
|
||||
- Bump ``pytest-xdist`` from 3.6.0 to 3.6.1 (:pr:`4233`)
|
||||
- Bump ``furo`` from 2024.1.29 to 2024.4.27 (:pr:`4230`)
|
||||
- Bump ``srvaroa/labeler`` from 1.10.0 to 1.10.1 (:pr:`4227`)
|
||||
- Bump ``pytest`` from 7.4.4 to 8.1.1 (:pr:`4218`)
|
||||
- Bump ``sphinx`` from 7.2.6 to 7.3.7 (:pr:`4215`)
|
||||
- Bump ``pytest-xdist`` from 3.5.0 to 3.6.0 (:pr:`4215`)
|
||||
|
||||
Version 21.1.1
|
||||
==============
|
||||
|
||||
|
|
|
@ -20,9 +20,9 @@ author = "Leandro Toledo"
|
|||
# built documents.
|
||||
#
|
||||
# The short X.Y version.
|
||||
version = "21.1.1" # telegram.__version__[:3]
|
||||
version = "21.2" # telegram.__version__[:3]
|
||||
# The full version, including alpha/beta/rc tags.
|
||||
release = "21.1.1" # telegram.__version__
|
||||
release = "21.2" # telegram.__version__
|
||||
|
||||
# If your documentation needs a minimal Sphinx version, state it here.
|
||||
needs_sphinx = "6.1.3"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundFill
|
||||
==============
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundFill
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundFillFreeformGradient
|
||||
==============================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundFillFreeformGradient
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundFillGradient
|
||||
======================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundFillGradient
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundFillSolid
|
||||
===================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundFillSolid
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundType
|
||||
==============
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundType
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundTypeChatTheme
|
||||
=======================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundTypeChatTheme
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundTypeFill
|
||||
==================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundTypeFill
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundTypePattern
|
||||
=====================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundTypePattern
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
BackgroundTypeWallpaper
|
||||
=======================
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.BackgroundTypeWallpaper
|
||||
:members:
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
ChatBackground
|
||||
==============
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. autoclass:: telegram.ChatBackground
|
||||
:members:
|
||||
|
|
|
@ -73,7 +73,7 @@ class Birthdate(TelegramObject):
|
|||
def to_date(self, year: Optional[int] = None) -> date:
|
||||
"""Return the birthdate as a date object.
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
Now returns a :obj:`datetime.date` object instead of a :obj:`datetime.datetime` object,
|
||||
as was originally intended.
|
||||
|
||||
|
|
|
@ -2772,7 +2772,7 @@ class Bot(TelegramObject, AsyncContextManager["Bot"]):
|
|||
date must remain within the next 90 days. If not specified, then ``live_period``
|
||||
remains unchanged
|
||||
|
||||
.. versionadded:: NEXT.VERSION.
|
||||
.. versionadded:: 21.2.
|
||||
|
||||
Keyword Args:
|
||||
location (:class:`telegram.Location`, optional): The location to send.
|
||||
|
@ -4457,7 +4457,7 @@ class Bot(TelegramObject, AsyncContextManager["Bot"]):
|
|||
Use this method to get up to date information about the chat (current name of the user for
|
||||
one-on-one conversations, current username of a user, group or channel, etc.).
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
In accordance to Bot API 7.3, this method now returns a :class:`telegram.ChatFullInfo`.
|
||||
|
||||
Args:
|
||||
|
@ -6360,7 +6360,7 @@ CUSTOM_EMOJI_IDENTIFIER_LIMIT` custom emoji identifiers can be specified.
|
|||
Removed the deprecated parameters mentioned above and adjusted the order of the
|
||||
parameters.
|
||||
|
||||
.. versionremoved:: NEXT.VERSION
|
||||
.. versionremoved:: 21.2
|
||||
Removed the deprecated parameter ``sticker_format``.
|
||||
|
||||
Args:
|
||||
|
@ -6867,7 +6867,7 @@ CUSTOM_EMOJI_IDENTIFIER_LIMIT` custom emoji identifiers can be specified.
|
|||
.. versionchanged:: 20.0
|
||||
|sequenceargs|
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
Bot API 7.3 adds support for :class:`~telegram.InputPollOption` objects.
|
||||
is_anonymous (:obj:`bool`, optional): :obj:`True`, if the poll needs to be anonymous,
|
||||
defaults to :obj:`True`.
|
||||
|
@ -6927,12 +6927,12 @@ CUSTOM_EMOJI_IDENTIFIER_LIMIT` custom emoji identifiers can be specified.
|
|||
See the constants in :class:`telegram.constants.ParseMode` for the available modes.
|
||||
Currently, only custom emoji entities are allowed.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
question_entities (Sequence[:class:`telegram.Message`], optional): Special entities
|
||||
that appear in the poll :paramref:`question`. It can be specified instead of
|
||||
:paramref:`question_parse_mode`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Keyword Args:
|
||||
allow_sending_without_reply (:obj:`bool`, optional): |allow_sending_without_reply|
|
||||
|
|
|
@ -150,13 +150,13 @@ class Chat(TelegramObject):
|
|||
photo (:class:`telegram.ChatPhoto`, optional): Chat photo.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
bio (:obj:`str`, optional): Bio of the other party in a private chat. Returned only in
|
||||
:meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_private_forwards (:obj:`bool`, optional): :obj:`True`, if privacy settings of the other
|
||||
|
@ -165,38 +165,38 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.9
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
description (:obj:`str`, optional): Description, for groups, supergroups and channel chats.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
invite_link (:obj:`str`, optional): Primary invite link, for groups, supergroups and
|
||||
channel. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
pinned_message (:class:`telegram.Message`, optional): The most recent pinned message
|
||||
(by sending date). Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
permissions (:class:`telegram.ChatPermissions`): Optional. Default chat member permissions,
|
||||
for groups and supergroups. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
slow_mode_delay (:obj:`int`, optional): For supergroups, the minimum allowed delay between
|
||||
consecutive messages sent by each unprivileged user.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
message_auto_delete_time (:obj:`int`, optional): The time after which all messages sent to
|
||||
|
@ -205,7 +205,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.4
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_protected_content (:obj:`bool`, optional): :obj:`True`, if messages from the chat can't
|
||||
|
@ -213,7 +213,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.9
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_visible_history (:obj:`bool`, optional): :obj:`True`, if new chat members will have
|
||||
|
@ -222,32 +222,32 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
sticker_set_name (:obj:`str`, optional): For supergroups, name of group sticker set.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
can_set_sticker_set (:obj:`bool`, optional): :obj:`True`, if the bot can change group the
|
||||
sticker set. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
linked_chat_id (:obj:`int`, optional): Unique identifier for the linked chat, i.e. the
|
||||
discussion group identifier for a channel and vice versa; for supergroups and channel
|
||||
chats. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
location (:class:`telegram.ChatLocation`, optional): For supergroups, the location to which
|
||||
the supergroup is connected. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
join_to_send_messages (:obj:`bool`, optional): :obj:`True`, if users need to join the
|
||||
|
@ -256,7 +256,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
join_by_request (:obj:`bool`, optional): :obj:`True`, if all users directly joining the
|
||||
|
@ -265,7 +265,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_restricted_voice_and_video_messages (:obj:`bool`, optional): :obj:`True`, if the
|
||||
|
@ -274,7 +274,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
is_forum (:obj:`bool`, optional): :obj:`True`, if the supergroup chat is a forum
|
||||
|
@ -288,7 +288,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_intro (:class:`telegram.BusinessIntro`, optional): For private chats with
|
||||
|
@ -297,7 +297,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_location (:class:`telegram.BusinessLocation`, optional): For private chats with
|
||||
|
@ -306,7 +306,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_opening_hours (:class:`telegram.BusinessOpeningHours`, optional): For private
|
||||
|
@ -315,7 +315,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
available_reactions (Sequence[:class:`telegram.ReactionType`], optional): List of available
|
||||
|
@ -325,7 +325,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
accent_color_id (:obj:`int`, optional): Identifier of the
|
||||
|
@ -336,7 +336,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
background_custom_emoji_id (:obj:`str`, optional): Custom emoji identifier of emoji chosen
|
||||
|
@ -345,7 +345,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
profile_accent_color_id (:obj:`int`, optional): Identifier of the
|
||||
|
@ -355,7 +355,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
profile_background_custom_emoji_id (:obj:`str`, optional): Custom emoji identifier of
|
||||
|
@ -364,7 +364,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
emoji_status_custom_emoji_id (:obj:`str`, optional): Custom emoji identifier of emoji
|
||||
|
@ -373,7 +373,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
emoji_status_expiration_date (:class:`datetime.datetime`, optional): Expiration date of
|
||||
|
@ -383,7 +383,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.5
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_aggressive_anti_spam_enabled (:obj:`bool`, optional): :obj:`True`, if aggressive
|
||||
|
@ -392,7 +392,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_hidden_members (:obj:`bool`, optional): :obj:`True`, if non-administrators can only
|
||||
|
@ -401,7 +401,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
unrestrict_boost_count (:obj:`int`, optional): For supergroups, the minimum number of
|
||||
|
@ -410,7 +410,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
custom_emoji_sticker_set_name (:obj:`str`, optional): For supergroups, the name of the
|
||||
|
@ -419,7 +419,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
birthdate (:obj:`telegram.Birthdate`, optional): For private chats,
|
||||
|
@ -427,7 +427,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
personal_chat (:obj:`telegram.Chat`, optional): For private chats, the personal channel of
|
||||
|
@ -435,7 +435,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
|
||||
|
@ -454,13 +454,13 @@ class Chat(TelegramObject):
|
|||
photo (:class:`telegram.ChatPhoto`): Optional. Chat photo.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
bio (:obj:`str`): Optional. Bio of the other party in a private chat. Returned only in
|
||||
:meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_private_forwards (:obj:`bool`): Optional. :obj:`True`, if privacy settings of the other
|
||||
|
@ -469,38 +469,38 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.9
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
description (:obj:`str`): Optional. Description, for groups, supergroups and channel chats.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
invite_link (:obj:`str`): Optional. Primary invite link, for groups, supergroups and
|
||||
channel. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
pinned_message (:class:`telegram.Message`): Optional. The most recent pinned message
|
||||
(by sending date). Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
permissions (:class:`telegram.ChatPermissions`): Optional. Default chat member permissions,
|
||||
for groups and supergroups. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
slow_mode_delay (:obj:`int`): Optional. For supergroups, the minimum allowed delay between
|
||||
consecutive messages sent by each unprivileged user. Returned only in
|
||||
:meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
message_auto_delete_time (:obj:`int`): Optional. The time after which all messages sent to
|
||||
|
@ -509,7 +509,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.4
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_protected_content (:obj:`bool`): Optional. :obj:`True`, if messages from the chat can't
|
||||
|
@ -517,7 +517,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 13.9
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_visible_history (:obj:`bool`): Optional. :obj:`True`, if new chat members will have
|
||||
|
@ -526,32 +526,32 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
sticker_set_name (:obj:`str`): Optional. For supergroups, name of Group sticker set.
|
||||
Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
can_set_sticker_set (:obj:`bool`): Optional. :obj:`True`, if the bot can change group the
|
||||
sticker set. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
linked_chat_id (:obj:`int`): Optional. Unique identifier for the linked chat, i.e. the
|
||||
discussion group identifier for a channel and vice versa; for supergroups and channel
|
||||
chats. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
location (:class:`telegram.ChatLocation`): Optional. For supergroups, the location to which
|
||||
the supergroup is connected. Returned only in :meth:`telegram.Bot.get_chat`.
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
join_to_send_messages (:obj:`bool`): Optional. :obj:`True`, if users need to join
|
||||
|
@ -560,7 +560,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
join_by_request (:obj:`bool`): Optional. :obj:`True`, if all users directly joining the
|
||||
|
@ -569,7 +569,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_restricted_voice_and_video_messages (:obj:`bool`): Optional. :obj:`True`, if the
|
||||
|
@ -578,7 +578,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
is_forum (:obj:`bool`): Optional. :obj:`True`, if the supergroup chat is a forum
|
||||
|
@ -594,7 +594,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_intro (:class:`telegram.BusinessIntro`): Optional. For private chats with
|
||||
|
@ -603,7 +603,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_location (:class:`telegram.BusinessLocation`): Optional. For private chats with
|
||||
|
@ -612,7 +612,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
business_opening_hours (:class:`telegram.BusinessOpeningHours`): Optional. For private
|
||||
|
@ -621,7 +621,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
available_reactions (Tuple[:class:`telegram.ReactionType`]): Optional. List of available
|
||||
|
@ -631,7 +631,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
accent_color_id (:obj:`int`): Optional. Identifier of the
|
||||
|
@ -642,7 +642,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
background_custom_emoji_id (:obj:`str`): Optional. Custom emoji identifier of emoji chosen
|
||||
|
@ -651,7 +651,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
profile_accent_color_id (:obj:`int`): Optional. Identifier of the
|
||||
|
@ -661,7 +661,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
profile_background_custom_emoji_id (:obj:`str`): Optional. Custom emoji identifier of
|
||||
|
@ -670,7 +670,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.8
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
emoji_status_custom_emoji_id (:obj:`str`): Optional. Custom emoji identifier of emoji
|
||||
|
@ -679,7 +679,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
emoji_status_expiration_date (:class:`datetime.datetime`): Optional. Expiration date of
|
||||
|
@ -689,7 +689,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.5
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_aggressive_anti_spam_enabled (:obj:`bool`): Optional. :obj:`True`, if aggressive
|
||||
|
@ -698,7 +698,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
has_hidden_members (:obj:`bool`): Optional. :obj:`True`, if non-administrators can only
|
||||
|
@ -707,7 +707,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 20.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
unrestrict_boost_count (:obj:`int`): Optional. For supergroups, the minimum number of
|
||||
|
@ -716,7 +716,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
custom_emoji_sticker_set_name (:obj:`str`): Optional. For supergroups, the name of the
|
||||
|
@ -725,7 +725,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.0
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
birthdate (:obj:`telegram.Birthdate`): Optional. For private chats,
|
||||
|
@ -733,7 +733,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
personal_chat (:obj:`telegram.Chat`): Optional. For private chats, the personal channel of
|
||||
|
@ -741,7 +741,7 @@ class Chat(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. deprecated:: NEXT.VERSION
|
||||
.. deprecated:: 21.2
|
||||
In accordance to Bot API 7.3, this attribute will be moved to
|
||||
:class:`telegram.ChatFullInfo`.
|
||||
|
||||
|
@ -911,7 +911,7 @@ class Chat(TelegramObject):
|
|||
if (val := object.__getattribute__(self, arg)) is not None and val != ():
|
||||
warn(
|
||||
PTBDeprecationWarning(
|
||||
"NEXT.VERSION",
|
||||
"21.2",
|
||||
f"The argument `{arg}` is deprecated and will only be available via "
|
||||
"`ChatFullInfo` in the future.",
|
||||
),
|
||||
|
@ -926,7 +926,7 @@ class Chat(TelegramObject):
|
|||
if name in _deprecated_attrs and self.__class__ is Chat:
|
||||
warn(
|
||||
PTBDeprecationWarning(
|
||||
"NEXT.VERSION",
|
||||
"21.2",
|
||||
f"The attribute `{name}` is deprecated and will only be accessible via "
|
||||
"`ChatFullInfo` in the future.",
|
||||
),
|
||||
|
|
|
@ -40,7 +40,7 @@ class BackgroundFill(TelegramObject):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`type` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
type (:obj:`str`): Type of the background fill. Can be one of:
|
||||
|
@ -104,7 +104,7 @@ class BackgroundFillSolid(BackgroundFill):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`color` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
color (:obj:`int`): The color of the background fill in the `RGB24` format.
|
||||
|
@ -139,7 +139,7 @@ class BackgroundFillGradient(BackgroundFill):
|
|||
considered equal, if their :attr:`top_color`, :attr:`bottom_color`
|
||||
and :attr:`rotation_angle` are equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
top_color (:obj:`int`): Top color of the gradient in the `RGB24` format.
|
||||
|
@ -186,7 +186,7 @@ class BackgroundFillFreeformGradient(BackgroundFill):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`colors` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
colors (Sequence[:obj:`int`]): A list of the 3 or 4 base colors that are used to
|
||||
|
@ -226,7 +226,7 @@ class BackgroundType(TelegramObject):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`type` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
type (:obj:`str`): Type of the background. Can be one of:
|
||||
|
@ -300,7 +300,7 @@ class BackgroundTypeFill(BackgroundType):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`fill` and :attr:`dark_theme_dimming` are equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
fill (:obj:`telegram.BackgroundFill`): The background fill.
|
||||
|
@ -342,7 +342,7 @@ class BackgroundTypeWallpaper(BackgroundType):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`document` and :attr:`dark_theme_dimming` are equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
document (:obj:`telegram.Document`): Document with the wallpaper
|
||||
|
@ -400,7 +400,7 @@ class BackgroundTypePattern(BackgroundType):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`document` and :attr:`fill` and :attr:`intensity` are equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
document (:obj:`telegram.Document`): Document with the pattern.
|
||||
|
@ -470,7 +470,7 @@ class BackgroundTypeChatTheme(BackgroundType):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`theme_name` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
theme_name (:obj:`str`): Name of the chat theme, which is usually an emoji.
|
||||
|
@ -504,7 +504,7 @@ class ChatBackground(TelegramObject):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`type` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
type (:obj:`telegram.BackgroundType`): Type of the background.
|
||||
|
|
|
@ -48,19 +48,19 @@ class ChatFullInfo(Chat):
|
|||
.. seealso::
|
||||
All arguments and attributes can be found in :class:`telegram.Chat`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
max_reaction_count (:obj:`int`): The maximum number of reactions that can be set on a
|
||||
message in the chat.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
max_reaction_count (:obj:`int`): The maximum number of reactions that can be set on a
|
||||
message in the chat.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ("max_reaction_count",)
|
||||
|
|
|
@ -67,7 +67,7 @@ class ChatMemberUpdated(TelegramObject):
|
|||
sending a direct join request without using an invite link and being approved by
|
||||
an administrator
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
chat (:class:`telegram.Chat`): Chat the user belongs to.
|
||||
|
@ -89,7 +89,7 @@ class ChatMemberUpdated(TelegramObject):
|
|||
sending a direct join request without using an invite link and being approved
|
||||
by an administrator
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
"""
|
||||
|
||||
|
|
|
@ -235,7 +235,7 @@ class StickerSet(TelegramObject):
|
|||
.. versionchanged:: 20.5
|
||||
|removed_thumb_note|
|
||||
|
||||
.. versionremoved:: NEXT.VERSION
|
||||
.. versionremoved:: 21.2
|
||||
Removed the deprecated arguments and attributes ``is_animated`` and ``is_video``.
|
||||
|
||||
Args:
|
||||
|
|
|
@ -559,7 +559,7 @@ class Message(MaybeInaccessibleMessage):
|
|||
chat_background_set (:obj:`telegram.ChatBackground`, optional): Service message: chat
|
||||
background set.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
message_id (:obj:`int`): Unique message identifier inside this chat.
|
||||
|
@ -864,7 +864,7 @@ class Message(MaybeInaccessibleMessage):
|
|||
chat_background_set (:obj:`telegram.ChatBackground`): Optional. Service message: chat
|
||||
background set
|
||||
|
||||
.. versionadded:: Next.Version
|
||||
.. versionadded:: 21.2
|
||||
|
||||
.. |custom_emoji_no_md1_support| replace:: Since custom emoji entities are not supported by
|
||||
:attr:`~telegram.constants.ParseMode.MARKDOWN`, this method now raises a
|
||||
|
|
|
@ -43,7 +43,7 @@ class InputPollOption(TelegramObject):
|
|||
Objects of this class are comparable in terms of equality. Two objects of this class are
|
||||
considered equal, if their :attr:`text` is equal.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
text (:obj:`str`): Option text,
|
||||
|
@ -118,7 +118,7 @@ class PollOption(TelegramObject):
|
|||
that appear in the option text. Currently, only custom emoji entities are allowed in
|
||||
poll option texts.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
text (:obj:`str`): Option text,
|
||||
|
@ -130,7 +130,7 @@ class PollOption(TelegramObject):
|
|||
poll option texts.
|
||||
This list is empty if the question does not contain entities.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
"""
|
||||
|
||||
|
@ -174,7 +174,7 @@ class PollOption(TelegramObject):
|
|||
UTF-16 codepoint pairs, which some versions of Python don't handle automatically.
|
||||
(That is, you can't just slice ``Message.text`` with the offset and length.)
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
entity (:class:`telegram.MessageEntity`): The entity to extract the text from. It must
|
||||
|
@ -196,7 +196,7 @@ class PollOption(TelegramObject):
|
|||
attribute, since it calculates the correct substring from the message text based on
|
||||
UTF-16 codepoints. See :attr:`parse_entity` for more info.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Args:
|
||||
types (List[:obj:`str`], optional): List of ``MessageEntity`` types as strings. If the
|
||||
|
@ -362,7 +362,7 @@ class Poll(TelegramObject):
|
|||
that appear in the :attr:`question`. Currently, only custom emoji entities are allowed
|
||||
in poll questions.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
id (:obj:`str`): Unique poll identifier.
|
||||
|
@ -404,7 +404,7 @@ class Poll(TelegramObject):
|
|||
in poll questions.
|
||||
This list is empty if the question does not contain entities.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
"""
|
||||
|
||||
|
@ -544,7 +544,7 @@ class Poll(TelegramObject):
|
|||
"""Returns the text in :attr:`question` from a given :class:`telegram.MessageEntity` of
|
||||
:attr:`question_entities`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Note:
|
||||
This method is present because Telegram calculates the offset and length in
|
||||
|
@ -568,7 +568,7 @@ class Poll(TelegramObject):
|
|||
It contains entities from this polls question filtered by their ``type`` attribute as
|
||||
the key, and the text that each entity belongs to as the value of the :obj:`dict`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Note:
|
||||
This method should always be used instead of the :attr:`question_entities`
|
||||
|
|
|
@ -44,7 +44,7 @@ class UsersShared(TelegramObject):
|
|||
The argument :attr:`users` is now considered for the equality comparison instead of
|
||||
``user_ids``.
|
||||
|
||||
.. versionremoved:: NEXT.VERSION
|
||||
.. versionremoved:: 21.2
|
||||
Removed the deprecated argument and attribute ``user_ids``.
|
||||
|
||||
Args:
|
||||
|
@ -54,7 +54,7 @@ class UsersShared(TelegramObject):
|
|||
|
||||
.. versionadded:: 21.1
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
This argument is now required.
|
||||
|
||||
Attributes:
|
||||
|
|
|
@ -45,7 +45,7 @@ def warn(
|
|||
message (:obj:`str` | :obj:`PTBUserWarning`): Specify the warnings message to pass to
|
||||
``warnings.warn()``.
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
Now also accepts a :obj:`PTBUserWarning` instance.
|
||||
|
||||
category (:obj:`Type[Warning]`, optional): Specify the Warning class to pass to
|
||||
|
|
|
@ -51,7 +51,7 @@ class Version(NamedTuple):
|
|||
|
||||
|
||||
__version_info__: Final[Version] = Version(
|
||||
major=21, minor=1, micro=1, releaselevel="final", serial=0
|
||||
major=21, minor=2, micro=0, releaselevel="final", serial=0
|
||||
)
|
||||
__version__: Final[str] = str(__version_info__)
|
||||
|
||||
|
|
|
@ -831,7 +831,7 @@ class BackgroundTypeLimit(IntEnum):
|
|||
:class:`telegram.BackgroundTypeWallpaper` and :class:`telegram.BackgroundTypePattern`.
|
||||
The enum members of this enumeration are instances of :class:`int` and can be treated as such.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ()
|
||||
|
@ -854,7 +854,7 @@ class BackgroundFillLimit(IntEnum):
|
|||
"""This enum contains limitations for :class:`telegram.BackgroundFillGradient`.
|
||||
The enum members of this enumeration are instances of :class:`int` and can be treated as such.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ()
|
||||
|
@ -1483,7 +1483,7 @@ class LocationLimit(IntEnum):
|
|||
* :paramref:`~telegram.Bot.send_location.live_period` parameter of
|
||||
:meth:`telegram.Bot.send_location`
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
MIN_PROXIMITY_ALERT_RADIUS = 1
|
||||
|
@ -1788,7 +1788,7 @@ class MessageType(StringEnum):
|
|||
CHAT_BACKGROUND_SET = "chat_background_set"
|
||||
""":obj:`str`: Messages with :attr:`telegram.Message.chat_background_set`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
CONNECTED_WEBSITE = "connected_website"
|
||||
""":obj:`str`: Messages with :attr:`telegram.Message.connected_website`."""
|
||||
|
@ -2948,7 +2948,7 @@ class BackgroundTypeType(StringEnum):
|
|||
"""This enum contains the available types of :class:`telegram.BackgroundType`. The enum
|
||||
members of this enumeration are instances of :class:`str` and can be treated as such.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ()
|
||||
|
@ -2967,7 +2967,7 @@ class BackgroundFillType(StringEnum):
|
|||
"""This enum contains the available types of :class:`telegram.BackgroundFill`. The enum
|
||||
members of this enumeration are instances of :class:`str` and can be treated as such.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ()
|
||||
|
|
|
@ -733,7 +733,7 @@ class Application(Generic[BT, CCT, UD, CD, BD, JQ], AsyncContextManager["Applica
|
|||
|
||||
.. versionadded:: 20.5
|
||||
|
||||
.. versionchanged:: NEXT.VERSION
|
||||
.. versionchanged:: 21.2
|
||||
Added support for calling within :meth:`post_init`.
|
||||
"""
|
||||
if self.running:
|
||||
|
|
|
@ -273,7 +273,7 @@ class Defaults:
|
|||
""":obj:`str`: Optional. Alias for :attr:`parse_mode`, used for
|
||||
the corresponding parameter of :class:`telegram.InputPollOption`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
return self._parse_mode
|
||||
|
||||
|
@ -288,7 +288,7 @@ class Defaults:
|
|||
""":obj:`str`: Optional. Alias for :attr:`parse_mode`, used for
|
||||
the corresponding parameter of :meth:`telegram.Bot.send_poll`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
return self._parse_mode
|
||||
|
||||
|
|
|
@ -58,18 +58,18 @@ class PTBDeprecationWarning(PTBUserWarning, DeprecationWarning):
|
|||
Args:
|
||||
version (:obj:`str`): The version in which the feature was deprecated.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
message (:obj:`str`): The message to display.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
|
||||
Attributes:
|
||||
version (:obj:`str`): The version in which the feature was deprecated.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
message (:obj:`str`): The message to display.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
|
||||
__slots__ = ("message", "version")
|
||||
|
@ -82,6 +82,6 @@ class PTBDeprecationWarning(PTBUserWarning, DeprecationWarning):
|
|||
"""Returns a string representation of the warning, using :attr:`message` and
|
||||
:attr:`version`.
|
||||
|
||||
.. versionadded:: NEXT.VERSION
|
||||
.. versionadded:: 21.2
|
||||
"""
|
||||
return f"Deprecated since version {self.version}: {self.message}"
|
||||
|
|
Loading…
Reference in a new issue