python-telegram-bot
16.3K subscribers
91 links
The official channel for the python-telegram-bot library | https://python-telegram-bot.org
Download Telegram
Another cool blog post that uses python-telegram-bot for a chat bot with Natural Language Processing! Link: http://blog.algorithmia.com/create-a-chatbot-telegram-python-summarize-text/

We will start collecting articles like this in the wiki, please add any articles you know (or have written yourself) here: https://github.com/python-telegram-bot/python-telegram-bot/wiki/Press
A new release, at last!
python-telegram-bot v5.1 is now available on PyPI

Changelog:

- Drop Python 2.6 support
- Deprecate telegram.Emoji

- Use ujson if available
- Add instance methods to Message, Chat, User, InlineQuery and CallbackQuery
- RegEx filtering for CallbackQueryHandler and InlineQueryHandler
- New MessageHandler filters: forwarded and entity
- Add Message.get_entity to correctly handle UTF-16 codepoints and MessageEntity offsets
- Fix bug in ConversationHandler when first handler ends the conversation
- Allow multiple Dispatcher instances
- Add ChatMigrated Exception
- Properly split and handle arguments in CommandHandler

First of all: Sorry for letting you wait so long between two releases. Second of all: Holy shit! What an epic changelog!
7 different contributors worked on this release, and there is some cool new stuff to explore. Check out our updated examples on GitHub!

As always, you can upgrade to the latest version with
pip install -U python-telegram-bot
Just a heads up: We are aware of the Bot API changes of today, October 3rd, and we are already working on it.
The prophecy was fullfilled! We just released v5.2

- Implement API changes of October 3rd (games update)
- Add Message.edit_* methods
- Filters for the MessageHandler can now be combined using bitwise operators (& and |)
- Add a way to save user- and chat-related data temporarily (check out the new conversationbot2.py example)
- Other bugfixes and improvements
Released v5.3

- Implement API changes of November 21st (Bot API 2.3)
- JobQueue now supports datetime.timedelta in addition to seconds
- JobQueue now supports running jobs only on certain days
- New Filters.reply filter
- Bugfix for Message.edit_reply_markup
- Other bugfixes

Update with pip install -U python-telegram-bot
I just released a hotfix version 5.3.1 which resolves https://github.com/python-telegram-bot/python-telegram-bot/issues/579 by enforcing the use of urllib3 v1.20 instead of v1.21.

We are still working on the v6 release.
Forwarded from Markdown
We just released python-telegram-bot v6.0!

This release adds lots of cool new stuff. To learn more about specific features, please read through the linked pull requests or join us in our Telegram Group and ask around.

- Add support for Bot API 2.3.1
- Add support for deleteMessage API method
- New, simpler API for JobQueue - PR #484
- Download files into file-like objects - PR #459
- Use vendor urllib3 to address issues with timeouts
- The default timeout for messages is now 5 seconds. For sending media, the default timeout is now 20 seconds.
- String attributes that are not set are now None by default, instead of empty strings
- Add text_markdown and text_html properties to Message - PR #507
- Add support for Socks5 proxy - PR #518
- Add support for filters in CommandHandler - PR #536
- Add the ability to invert (not) filters - PR #552
- Add Filters.group and Filters.private
- Compatibility with GAE via urllib3.contrib package - PR #583
- Add equality rich comparision operators to telegram objects - PR #604
- Several bugfixes and other improvements
- Remove some deprecated code

We'll be working on the new Bot API 3.0 features and bring them to you ASAP. Thanks a lot to all the wonderful people who contributed to this release!

As always, upgrade using
pip install -U python-telegram-bot
Released v6.0.1

- Add support for User.language_code
- Fix Message.text_html and Message.text_markdown for messages with emoji
We just released v6.1 beta 0, which includes all of Bot API 3.0.

You can install it using
pip install python-telegram-bot==6.1b0
We just released v6.1 beta 1, which adds the missing Handler classes for the payment API.

You can install it using
pip install python-telegram-bot==6.1b1
Released 6.1 beta 2

- Bugfixes
- Add filters for payment API

Install it using
pip install python-telegram-bot==6.1b2
Released 6.0.2

- Avoid confusion with user's urllib3 by renaming vendored urllib3 to ptb_urllib3

Upgrade using pip install python-telegram-bot -U
There seems to be a problem with the PyPI release of v6.0.2.
Please don't upgrade, we are looking into it.
If you already upgraded, you can downgrade using
pip install python-telegram-bot==6.0.1
Alright, v6.0.3 fixes the problem, you can safely upgrade now
We just released v6.1.0!

- Fully support Bot API 3.0
- Add more fine-grained filters for status updates
- Bug fixes and other improvements

As always, upgrade using
pip install python-telegram-bot -U
We just released v7.0.0!

TL;DR
- We wish to thank everyone who had contributed to this major release. If for some reason your name is not in AUTHORS.rst please don't be shy and send us a PR to add your name.

- As always, upgrade using
pip install python-telegram-bot -U




Changes:

- Fully support Bot API 3.2.
- New filters for handling messages from specific chat/user id (PR #677).
- Add the possibility to add objects as arguments to send_* methods (PR #742).
- Fixed download of URLs with UTF-8 chars in path (PR #688).
- Fixed URL parsing for Message text properties (PR #689).
- Fixed args dispatching in MessageQueue's decorator (PR #705).
- Fixed regression preventing IPv6 only hosts from connnecting to Telegram servers (Issue #720).
- ConvesationHandler - check if a user exist before using it (PR #699).
- Removed deprecated telegram.Emoji.
- Removed deprecated Botan import from utils (Botan is still available through contrib).
- Removed deprecated ReplyKeyboardHide.
- Removed deprecated edit_message argument of bot.set_game_score.
- Internal restructure of files.
- Improved documentation.
- Improved unitests.
We just released v7.0.1 (a bug fix release).

Changes:
- Fix TypeError exception in RegexHandler (PR #751).
- Small documentation fix (PR #749).

As always, upgrade using:
pip install -U python-telegram-bot
Hi,
We just wanted to let you all know that @EchteEldin & @BomJacob have been promoted to maintainers of the ptb project.
Both of them showed a major commitment & dedication to the project and have contributed a lot of their knowledge and experience. We were always happy to have them as part of the dev team, so we can only be delighted to have them as part of the maintainers.

@BomJacob & @EchteEldin - congratulations!
We just released v8.0.0!

TL;DR
- We wish to thank everyone who had contributed to this major release. If for some reason your name is not in AUTHORS.rst please don't be shy and send us a PR to add your name.

- As always, upgrade using
pip install python-telegram-bot -U

New features:

- Fully support Bot Api 3.3 (PR #806).
- DispatcherHandlerStop (see docs).
- Regression fix for text_html & text_markdown (PR #777).
- Added effective_attachment to message (PR #766).

Non backward compatible changes:

- Removed Botan support from the library (PR #776).
- Fully support Bot Api 3.3 (PR #806).
- Remove de_json() (PR #789).

Changes:

- Sane defaults for tcp socket options on linux (PR #754).
- Add RESTRICTED as constant to ChatMember (PR #761).
- Add rich comparison to CallbackQuery (PR #764).
- Fix get_game_high_scores (PR #771).
- Warn on small con_pool_size during custom initalization of Updater (PR #793).
- Catch exceptions in error handler for errors that happen during polling (PR #810).
- For testing we switched to pytest (PR #788).
- Lot's of small improvements to our tests and documentation.
We've just released v8.1.0!

TL;DR
Upgrade to get Bot API 3.4 support.

- As always, upgrade using
pip install python-telegram-bot -U


Changes:
New features
- Support Bot API 3.4 (PR #865).

Changes
- MessgaeHandler & RegexHandler now consider channel_updates.
- Fix command not recognized if it is directly followed by a newline (PR #869).
- Removed Bot._message_wrapper (PR #822).
- Unitests are now also running on Appveyor (Windows VM).
- Various unitest improvments.
- Documentation fixes.

We wish to thank everyone who had contributed to this release. Happy upgrades everyone!
We've just release v8.1.1!

TL;DR
Thanks for bringing a small error in our improve commandhandler to our attention. This is a hotfix for the risen problems with single character messages and the CommandHandler

- As always, upgrade using
pip install python-telegram-bot -U

Changes:
Fix Commandhandler crashing on single character messages (PR #873)

We wish to thank everyone who had contributed to this release. Happy upgrades everyone!