Better document MESSAGE_ID_INVALID

This commit is contained in:
Lonami Exo 2019-07-20 11:10:01 +02:00
parent cbcbda5276
commit ae620db0c5
2 changed files with 6 additions and 1 deletions

View File

@ -936,6 +936,11 @@ class MessageMethods:
``MessageNotModifiedError`` if the contents of the message were
not modified at all.
``MessageIdInvalidError`` if the ID of the message is invalid
(the ID itself may be correct, but the message with that ID
cannot be edited). For example, when trying to edit messages
with a reply markup (or clear markup) this error will be raised.
Example
.. code-block:: python

View File

@ -142,7 +142,7 @@ MESSAGE_DELETE_FORBIDDEN,403,"You can't delete one of the messages you tried to
MESSAGE_EDIT_TIME_EXPIRED,400,"You can't edit this message anymore, too much time has passed since its creation."
MESSAGE_EMPTY,400,Empty or invalid UTF-8 message was sent
MESSAGE_IDS_EMPTY,400,No message ids were provided
MESSAGE_ID_INVALID,400,The specified message ID is invalid
MESSAGE_ID_INVALID,400,"The specified message ID is invalid or you can't do that operation on such message"
MESSAGE_NOT_MODIFIED,400,Content of the message was not modified
MESSAGE_TOO_LONG,400,Message was too long. Current maximum length is 4096 UTF-8 characters
MSG_WAIT_FAILED,400,A waiting call returned an error

1 name codes description
142 MESSAGE_EDIT_TIME_EXPIRED 400 You can't edit this message anymore, too much time has passed since its creation.
143 MESSAGE_EMPTY 400 Empty or invalid UTF-8 message was sent
144 MESSAGE_IDS_EMPTY 400 No message ids were provided
145 MESSAGE_ID_INVALID 400 The specified message ID is invalid The specified message ID is invalid or you can't do that operation on such message
146 MESSAGE_NOT_MODIFIED 400 Content of the message was not modified
147 MESSAGE_TOO_LONG 400 Message was too long. Current maximum length is 4096 UTF-8 characters
148 MSG_WAIT_FAILED 400 A waiting call returned an error