Released on Feb 04, 2019
Smart Plugins revamp and lots of additions¶
Smart Plugins revamp: you can now specify exactly which plugins to include or exclude and in which exact order to load each of them.
no_updatesClient parameter. Pass
Truein order to completely disable incoming updates from Telegram. Useful in batch programs, for example, when you want to broadcast a message to many users and have no need to handle incoming messages or other updates whatsoever.
takeoutClient parameter. Pass
Truein order to use a special takeout session instead of a normal one. Useful for exporting your Telegram data; methods invoked inside a takeout session (such as get_history, download_media, …) are less prone to throw FloodWait exceptions.
Message and caption texts are now automatically casted to
str. This makes possible to send objects that implement a string representation without having to manually cast, for example:
app.send_message(chat_id, 123456)sends “123456” (int) text message as string.
message.reply(message)replies with the message (Message) itself.
Filters.me, useful for filtering messages coming from you yourself. Does the same as
close_poll method for closing (stopping) polls.
Game, GameHighScore and GameHighScores types for messages dealing with games,
game_high_scoreattributes inside Message as well as Filters.game, Filters.game_score filters and send_game, set_game_score, get_game_high_scores methods.
It’s now possible to recover the account while logging in, in case you forget your cloud password.
last_namecan now be callback functions.
Filters.regex now works on captions too.
New Filters.media_group for filtering photos or videos being part of an album.
New stop_transmission method useful to stop uploads and downloads.
New restart convenience method to automatically stop and start the Client.
The ChatMember type has been extended with extra attributes:
New Voice Calls page in documentation. Thanks to @bakatrouble for the working proof-of-concept.
A way to continue propagating the same update to the next handler within the same group with .continue_propagation() update’s bound-method.
A bunch of new common Telegram errors regarding takeout sessions and poll messages.
Polls in Layer 91 were reporting a wrong id and in some cases they were also flagged as “closed” when they were in fact not. This is due to a small issue in the TL schema (which will eventually get fixed in the next Layer update by Telegram itself). Nevertheless, from now on Pyrogram will be able to generate the correct code even in case such issues happen again. Relevant commit: c7b1d6f70a97674fc59afc21b1334cd10f024b87
developinstallation for pip. Thanks @bakatrouble for the hint!
All raw updates that were not part of those for which a parser was implemented were being discarded and never passed to raw update handlers. #211