-
Notifications
You must be signed in to change notification settings - Fork 5.9k
API 5.0 WP5 - Pinned messages #2184
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
API 5.0 WP5 - Pinned messages #2184
Conversation
- Also added unpin() shortcut in message.py and unpin all msgs shortcut in chat.py Signed-off-by: Harshil <ilovebhagwan@gmail.com>
Bibo-Joshi
left a comment
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.
Thanks for the PR! Left some notes :)
- Add pin_message() & unpin_message() shortcuts in `CallbackQuery`. - Add pin_message(), unpin_message(), & unpin_all_messages() shortcuts in `User`. - Rename unpin_all_chat_messages() to unpin_all_messages() in `Chat` - Minor doc fixes. Signed-off-by: Harshil <ilovebhagwan@gmail.com>
Signed-off-by: Harshil <ilovebhagwan@gmail.com>
Bibo-Joshi
left a comment
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.
Yea just realized that I was testing that as a positional argument 😳 |
Bibo-Joshi
left a comment
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.
Just one minor nitpick left from my side. @Poolitzer will want to review as well, though.
Poolitzer
left a comment
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.
@Poolitzer will want to review as well, though.
Dam Dam Daaaam. He wants though yeah. And he did some nitpicking about docs. And talks about himself in the third perspective.
Weird guy.
Bibo-Joshi
left a comment
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 just noticed that the docsring of Message.pinned_message changed as well, please update that :)
|
oh thats right. Pretty sure that bibo mixed them up as well |
|
ups, my bad 😬 sorry for the confusion |
|
For some reason codecov marks docstring as uncovered, but afais all change requests were resolved. merging. |



Along with the bot API update, I also added a
unpin()shortcut to message.py andunpin_all_chat_messages()shortcut to chat.py.Also if the tests I wrote aren't good enough, please feel free to edit them.
The mypy build is failing because of something webhook handler related (probably due to API 5.0) (edit: Nvm it only failed for me locally, it's not failing here)