-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Bot API 8.3 Update #2453
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bot API 8.3 Update #2453
Conversation
…ning a message-specific cover and a start timestamp for the video.
…o, allowing bots to specify a cover and a start timestamp for the videos they send.
…ideo and InputPaidMediaVideo, allowing bots to edit video cover and start timestamp and specify them for videos in albums and paid media.
…ge and copyMessage, allowing bots to change the start timestamp for forwarded and copied videos.
|
@Badiboy hi, done with bot api 8.3 update, you can start reviewing |
|
Got it |
telebot/__init__.py
Outdated
| return apihelper.delete_sticker_set(self.token, name) | ||
|
|
||
| def send_gift(self, user_id: int, gift_id: str, text: Optional[str]=None, text_parse_mode: Optional[str]=None, | ||
| def send_gift(self, gift_id: str, user_id: Optional[Union[str, int]] = None, chat_id: Optional[Union[str, int]] = None, text: Optional[str]=None, text_parse_mode: Optional[str]=None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We cannot change order of fixed parameters or ones who had been fixed. :(((
In this case I propose to make all parameters optional and check inside gift_id to be not None. Or even not check: Telegram will return error himself.
Mark in manual, that gift_id IS NOT optional in fact.
def send_gift(self, user_id: Optional[Union[str, int]] = None, gift_id: Optional[Union[str, int]] = None, chat_id: Optional[Union[str, int]] = None, text: Optional[str]=None, text_parse_mode: Optional[str]=None,...
if not gift_id:
ValueError("gift_id must be specified.")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I get annoyed to see how we are still 'outdated' from the API. Will fix it :(
telebot/async_telebot.py
Outdated
|
|
||
| async def send_gift(self, user_id: int, gift_id: str, text: Optional[str]=None, text_parse_mode: Optional[str]=None, | ||
| text_entities: Optional[List[types.MessageEntity]]=None, pay_for_upgrade: Optional[bool]=None) -> bool: | ||
| async def send_gift(self, gift_id: str, user_id: Optional[Union[str, int]] = None, chat_id: Optional[Union[str, int]] = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The same here: not possible to change fixed parameters order. :(
|
We are absolutely not outdated from API. We have just some small compatibility overheads that makes this library absoutely safe for years for any users who want to update library to actual version. |
|
Thank you. |
February 12, 2025
Bot API 8.3