Movatterモバイル変換


[0]ホーム

URL:


ContentsMenuExpandLight modeDark modeAuto light/dark, in light modeAuto light/dark, in dark modeSkip to content
python-telegram-bot
v22.5
Logo
python-telegram-bot
v22.5

Reference

Resources

Project

Back to top

Changelog

22.5

2025-09-27

Breaking Changes

  • Move paramReplyParameters.checklist_task_id to last position.

    Hint

    This change addresses a breaking change accidentally introduced in version 22.4 where the introduction of the new parameter was not done in a backward compatible way.

    Existing code using keyword arguments is unaffected. Only code using positional arguments (and based on version 22.4) may need updates.

    (#4972 by@aelkheir)

New Features

  • Add convenience methods forBusinessOpeningHours:

    • get_opening_hours_for_day: returns the opening hours applicable for a specific date

    • is_open: indicates whether the business is open at the specified date and time.

    (#4861 by@Aweryc closes#4194)

Bug Fixes

  • Fix Handling of Infinite Bootstrap Retries inApplication.run_* andUpdater.start_* (#4973 by@Bibo-Joshi closes#4966)

Other Changes

Documentation

Internal Changes

22.4

2025-09-13

New Features

Bug Fixes

  • Adapt logic on getting the event loop inApplication.run_polling/webhook to Python 3.14 (#4875 by@harshil21 closes#4874)

  • FixResourceWarning when passingpathlib.Path objects to methods which accept file input (#4908 by@harshil21 closes#4907)

Dependencies

Other Changes

  • Set the default connection pool size forHTTPXRequest to 256 to allow more concurrent requests by default. Drop thehttpx parametermax_keepalive_connections. This way, thehttpx default of 20 is used, leading to a smaller number of idle connections in large connection pools.

    Hint

    If you manually build theHTTPXRequest objects, please be aware that these changes also applies to you. Kindly double check your settings. To specify custom limits, you can set them via the parameterhttpx_kwargs ofHTTPXRequest. See alsothe httpx documentation for more details on these settings.”

    (#4882 by@Poolitzer)

  • Bump Version to v22.4 (#4939 by@Bibo-Joshi)

Documentation

Internal Changes

22.3

2025-07-20

Highlights

Breaking Changes

New Features

  • New filters based on Bot API 9.1:

    • filters.StatusUpdate.DIRECT_MESSAGE_PRICE_CHANGED forMessage.direct_message_price_changed

    • filters.StatusUpdate.CHECKLIST_TASKS_ADDED forMessage.checklist_tasks_added

    • filters.StatusUpdate.CHECKLIST_TASKS_DONE forMessage.checklist_tasks_done

    • filters.CHECKLIST forMessage.checklist

    (#4847 by@Bibo-Joshi closes#4845;#4848 by@Bibo-Joshi;#4849 by@harshil21;#4851 by@harshil21;#4857 by@aelkheir)

Other Changes

Documentation

  • Documentation Improvements. Among others, fix links to source code. (#4839 by@aelkheir closes#4838)

Internal Changes

22.2

2025-06-29

Deprecations

New Features

  • Usetimedelta to represent time periods in class arguments and attributes (#4750 by@aelkheir closes#4575)

Bug Fixes

  • Fixed a bug where callingApplication.remove/add_handler during update handling can cause aRuntimeError inApplication.process_update.

    Hint

    CallingApplication.add/remove_handler now has no influence on calls toprocess_update() that are

    already in progress. The same holds forApplication.add/remove_error_handler andApplication.process_error, respectively.

    Warning

    This behavior should currently be considered an implementation detail and not as guaranteed behavior.

    (#4802 by@Bibo-Joshi closes#4803)

  • Allow for pattern matching empty inline queries (#4817 by@locobott)

  • Correctly parse parameterallow_sending_without_reply inMessage.reply_* when used in combination withdo_quote=True.

    Hint

    Usingdict valued input fordo_quote along with passingallow_sending_without_reply is not supported and will raise an error.

    (#4818 by@Bibo-Joshi closes#4807)

Dependencies

Other Changes

  • Improve Informativeness of Network Errors Raised byBaseRequest.post/retrieve (#4822 by@Bibo-Joshi)

  • Add Python 3.14 Beta To Test Matrix.Python 3.14 is not officially supported by PTB yet! (#4825 by@harshil21)

  • Bump Version to v22.2 (#4834 by@Bibo-Joshi)

Documentation

Internal Changes

22.1

2025-05-15

Breaking Changes

  • Drop backward compatibility foruser_id insend_gift by updating the order of parameters. Please adapt your code accordingly or use keyword arguments. (#4692 by@Bibo-Joshi)

Deprecations

  • This release comes with several deprecations, in line with ourstability policy.

    This includes the following:

    • Deprecatedtelegram.constants.StarTransactionsLimit.NANOSTAR_MIN_AMOUNT andtelegram.constants.StarTransactionsLimit.NANOSTAR_MAX_AMOUNT. These members will be replaced bytelegram.constants.NanostarLimit.MIN_AMOUNT andtelegram.constants.NanostarLimit.MAX_AMOUNT.

    • Deprecated the classtelegram.constants.StarTransactions. Its only membertelegram.constants.StarTransactions.NANOSTAR_VALUE will be replaced bytelegram.constants.Nanostar.VALUE.

    • Bot API 9.0 deprecatedBusinessConnection.can_reply in favor ofBusinessConnection.rights

    • Bot API 9.0 deprecatedChatFullInfo.can_send_gift in favor ofChatFullInfo.accepted_gift_types.

    • Bot API 9.0 introduced these new required fields to existing classes:

      • TransactionPartnerUser.transaction_type

      • ChatFullInfo.accepted_gift_types

      Passing these values as positional arguments is deprecated. We encourage you to use keyword arguments instead, as the the signature will be updated in a future release.

    These deprecations are backward compatible, but we strongly recommend to update your code to use the new members.

    (#4756 by@Bibo-Joshi closes#4754;#4757 by@Bibo-Joshi;#4759 by@Bibo-Joshi;#4763 by@aelkheir;#4766 by@Bibo-Joshi;#4769 by@aelkheir;#4773 by@aelkheir;#4781 by@aelkheir;#4782 by@Bibo-Joshi)

New Features

Bug Fixes

Other Changes

Documentation

  • Documentation Improvements. Among others, add missingReturns field inUser.get_profile_photos (#4730 by@Bibo-Joshi;#4740 by@aelkheir)

  • UpdateAUTHORS.rst, Adding@aelkheir to Active Development Team (#4747 by@Bibo-Joshi)

  • Clarify Documentation and Type Hints ofInputMedia andInputPaidMedia. Note that themedia parameter accepts only objects of typestr andInputFile. The respective subclasses ofInput(Paid)Media each accept a broader range of input type for themedia parameter. (#4762 by@Bibo-Joshi)

Internal Changes

22.0

2025-03-15

Breaking Changes

  • This release removes all functionality that was deprecated in v20.x. This is in line with ourstability policy.

    This includes the following changes:

    • Removedfilters.CHAT (all messages have an associated chat) andfilters.StatusUpdate.USER_SHARED (usefilters.StatusUpdate.USERS_SHARED instead).

    • RemovedDefaults.disable_web_page_preview andDefaults.quote. UseDefaults.link_preview_options andDefaults.do_quote instead.

    • RemovedApplicationBuilder.(get_updates_)proxy_url andHTTPXRequest.proxy_url. UseApplicationBuilder.(get_updates_)proxy andHTTPXRequest.proxy instead.

    • Removed the*_timeout arguments ofApplication.run_polling andUpdater.start_webhook. Instead, specify the values viaApplicationBuilder.get_updates_*_timeout.

    • Removedconstants.InlineQueryLimit.MIN_SWITCH_PM_TEXT_LENGTH. Useconstants.InlineQueryResultsButtonLimit.MAX_START_PARAMETER_LENGTH instead.

    • Removed the argumentquote ofMessage.reply_*. Usedo_quote instead.

    • Removed the superfluousEncryptedPassportElement.credentials without replacement.

    • Changed attribute value ofPassportFile.file_date fromint todatetime.datetime. Make sure to adjust your code accordingly.

    • Changed the attribute value ofPassportElementErrors.file_hashes fromlist totuple. Make sure to adjust your code accordingly.

    • MakeBaseRequest.read_timeout an abstract property. If you subclassBaseRequest, you need to implement this property.

    • The default value forwrite_timeout now defaults toDEFAULT_NONE also for bot methods that send media. Previously, it was20. If you subclassBaseRequest, make sure to use your desired write timeout ifRequestData.multipart_data is set.

    (#4671 by@Bibo-Joshi closes#4659)

Documentation

Internal Changes

Version 21.11.1

Released 2025-03-01

This is the technical changelog for version 21.11. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Documentation Improvements

  • Fix ReadTheDocs Build (#4695)

Version 21.11

Released 2025-03-01

This is the technical changelog for version 21.11. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes and New Features

Minor Changes and Bug Fixes

  • Add Bootstrapping Logic toApplication.run_* (#4673 closes#4657)

  • Fix a Bug inedit_user_star_subscription (#4681 byvavasik800)

  • Simplify Handling of Empty Data inTelegramObject.de_json and Friends (#4617 closes#4614)

Documentation Improvements

  • Documentation Improvements (#4641)

  • Overhaul Admonition Insertion in Documentation (#4462 closes#4414)

Internal Changes

  • Stabilize Linkcheck Test (#4693)

  • Bumppre-commit Hooks to Latest Versions (#4643)

  • Refactor Tests forTelegramObject Classes with Subclasses (#4654 closes#4652)

  • Use Fine Grained Permissions for GitHub Actions Workflows (#4668)

Dependency Updates

  • Bumpactions/setup-python from 5.3.0 to 5.4.0 (#4665)

  • Bumpdependabot/fetch-metadata from 2.2.0 to 2.3.0 (#4666)

  • Bumpactions/stale from 9.0.0 to 9.1.0 (#4667)

  • Bumpastral-sh/setup-uv from 5.1.0 to 5.2.2 (#4664)

  • Bumpcodecov/test-results-action from 1.0.1 to 1.0.2 (#4663)

Version 21.10

Released 2025-01-03

This is the technical changelog for version 21.10. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for Bot API 8.2 (#4633)

  • Bumpapscheduler & Deprecatepytz Support (#4582)

New Features

  • Add Parameterpattern toJobQueue.jobs() (#4613 closes#4544)

  • Allow Input of TypeSticker for Several Methods (#4616 closes#4580)

Bug Fixes

  • Ensure Forward Compatibility ofGift andGifts (#4634 closes#4637)

Documentation Improvements & Internal Changes

  • Use Custom Labels fordependabot PRs (#4621)

  • Remove Redundantpylint Suppressions (#4628)

  • Update Copyright to 2025 (#4631)

  • Refactor Module Structure and Tests for Star Payments Classes (#4615 closes#4593)

  • Unifydatetime Imports (#4605 bycuevasrja closes#4577)

  • Add Static Security Analysis of GitHub Actions Workflows (#4606)

Dependency Updates

  • Bumpastral-sh/setup-uv from 4.2.0 to 5.1.0 (#4625)

  • Bumpcodecov/codecov-action from 5.1.1 to 5.1.2 (#4622)

  • Bumpactions/upload-artifact from 4.4.3 to 4.5.0 (#4623)

  • Bumpgithub/codeql-action from 3.27.9 to 3.28.0 (#4624)

Version 21.9

Released 2024-12-07

This is the technical changelog for version 21.9. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

Minor Changes

  • UseMessageLimit.DEEP_LINK_LENGTH inhelpers.create_deep_linked_url (#4597 bynemacysts)

  • AllowSequence Input forallowed_updates inApplication andUpdater Methods (#4589 bynemacysts)

Dependency Updates

  • Updateaiolimiter requirement from ~=1.1.0 to >=1.1,<1.3 (#4595)

  • Bumppytest from 8.3.3 to 8.3.4 (#4596)

  • Bumpcodecov/codecov-action from 4 to 5 (#4585)

  • Bumppylint to v3.3.2 to Improve Python 3.13 Support (#4590 bynemacysts)

  • Bumpsrvaroa/labeler from 1.11.1 to 1.12.0 (#4586)

Version 21.8

Released 2024-12-01

This is the technical changelog for version 21.8. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

Documentation Improvements

  • Documentation Improvements (#4565 by Snehashish06,#4573)

Version 21.7

Released 2024-11-04

This is the technical changelog for version 21.7. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

Minor Changes

  • AllowSequence inApplication.add_handlers (#4531 byroast-lord closes#4530)

  • Improve Exception Handling inFile.download_* (#4542)

  • Use Stable Python 3.13 Release in Test Suite (#4535)

Documentation Improvements

  • Documentation Improvements (#4536 byEcode2,#4556)

  • Fix Linkcheck Workflow (#4545)

  • Usesphinx-build-compatibility to Keep Sphinx Compatibility (#4492)

Internal Changes

  • Improve Test Instability Caused byMessage Fixtures (#4507)

  • Stabilize Some Flaky Tests (#4500)

  • Reduce Creation of HTTP Clients in Tests (#4493)

  • Updatepytest-xdist Usage (#4491)

  • Fix Failing Tests by Making Them Independent (#4494)

  • Introduce Codecov’s Test Analysis (#4487)

  • Maintenance Work onBot Tests (#4489)

  • Introduceconftest.py for File Related Tests (#4488)

  • Update Issue Templates to Use Issue Types (#4553)

  • Update Automation to Label Changes (#4552)

Dependency Updates

  • Bumpsrvaroa/labeler from 1.11.0 to 1.11.1 (#4549)

  • Bumpsphinx from 8.0.2 to 8.1.3 (#4532)

  • Bumpsphinxcontrib-mermaid from 0.9.2 to 1.0.0 (#4529)

  • Bumpsrvaroa/labeler from 1.10.1 to 1.11.0 (#4509)

  • BumpBibo-Joshi/pyright-type-completeness from 1.0.0 to 1.0.1 (#4510)

Version 21.6

Released 2024-09-19

This is the technical changelog for version 21.6. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

New Features

Minor Changes

  • Improve Type Completeness (#4466)

Internal Changes

  • Update Python 3.13 Test Suite to RC2 (#4471)

  • Enforce theoffline_bot Fixture inTest*WithoutRequest (#4465)

  • Make Tests fortelegram.ext Independent of Networking (#4454)

  • Rename Testing Base Classes (#4453)

Dependency Updates

  • Bumppytest from 8.3.2 to 8.3.3 (#4475)

Version 21.5

Released 2024-09-01

This is the technical changelog for version 21.5. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for Bot API 7.9 (#4429)

  • Full Support for Bot API 7.8 (#4408)

New Features

  • AddMessageEntity.shift_entities andMessageEntity.concatenate (#4376 closes#4372)

  • Add Parametergame_pattern toCallbackQueryHandler (#4353 byjainamoswal closes#4269)

  • Add Parameterread_file_handle toInputFile (#4388 closes#4339)

Documentation Improvements

Minor and Internal Changes

  • Remove Surplus Logging fromUpdater Network Loop (#4432 byMartinHjelmare)

  • Add Internal Constants for Encodings (#4378 byelpekenin)

  • Improve PyPI Automation (#4375 closes#4373)

  • Update Test Suite to New Test Channel Setup (#4435)

  • Improve Fixture Usage intest_message.py (#4431 byPalaptin)

  • Update Python 3.13 Test Suite to RC1 (#4415)

  • Bumpruff and Add New Rules (#4416)

Dependency Updates

  • Updatecachetools requirement from <5.5.0,>=5.3.3 to >=5.3.3,<5.6.0 (#4437)

  • Bumpsphinx from 7.4.7 to 8.0.2 andfuro from 2024.7.18 to 2024.8.6 (#4412)

  • Bumptest-summary/action from 2.3 to 2.4 (#4410)

  • Bumppytest from 8.2.2 to 8.3.2 (#4403)

  • Bumpdependabot/fetch-metadata from 2.1.0 to 2.2.0 (#4411)

  • Updatecachetools requirement from ~=5.3.3 to >=5.3.3,<5.5.0 (#4390)

  • Bumpsphinx from 7.3.7 to 7.4.7 (#4395)

  • Bumpfuro from 2024.5.6 to 2024.7.18 (#4392)

Version 21.4

Released 2024-07-12

This is the technical changelog for version 21.4. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

New Features

  • Add Support for Python 3.13 Beta (#4253)

  • Addfilters.PAID_MEDIA (#4357)

  • Log Received Data on Deserialization Errors (#4304)

  • AddMessageEntity.adjust_message_entities_to_utf_16 Utility Function (#4323 byAntares0982 closes#4319)

  • Make Argumentbot ofTelegramObject.de_json Optional (#4320)

Documentation Improvements

  • Documentation Improvements (#4303 closes#4301)

  • Restructure Readme (#4362)

  • Fix Link-Check Workflow (#4332)

Internal Changes

  • Automate PyPI Releases (#4364 closes#4318)

  • Addmise-en-place to.gitignore (#4300)

  • Use a Composite Action for Testing Type Completeness (#4367)

  • Stabilize Some Concurrency Usages in Test Suite (#4360)

  • Add a Test Case forMenuButton (#4363)

  • ExtendSuccessfulPayment Test (#4349)

  • Small Fixes fortest_stars.py (#4347)

  • Use Python 3.13 Beta 3 in Test Suite (#4336)

Dependency Updates

  • Bumpruff and Add New Rules (#4329)

  • Bumppre-commit Hooks to Latest Versions (#4337)

  • Add Lower Bound forflaky Dependency (#4322 byPalaptin)

  • Bumppytest from 8.2.1 to 8.2.2 (#4294)

Version 21.3

Released 2024-06-07

This is the technical changelog for version 21.3. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

New Features

Documentation Improvements

Internal Changes

  • Addsetuptools torequirements-dev.txt (#4282)

  • Update Settings for pre-commit.ci (#4265)

Dependency Updates

  • Bumppytest from 8.2.0 to 8.2.1 (#4272)

Version 21.2

Released 2024-05-20

This is the technical changelog for version 21.2. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

New Features

  • Add Version toPTBDeprecationWarning (#4262 closes#4261)

  • Handle Exceptions in buildingCallbackContext (#4222)

Bug Fixes

  • CallApplication.post_stop Only ifApplication.stop was called (#4211 closes#4210)

  • HandleSystemExit raised in Handlers (#4157 closes#4155 and#4156)

  • MakeBirthdate.to_date Return adatetime.date Object (#4251)

Documentation Improvements

  • Documentation Improvements (#4217)

Internal Changes

  • Add New Rules toruff Config (#4250)

  • Adapt Test Suite to Changes in Error Messages (#4238)

Dependency Updates

  • Bumpfuro from 2024.4.27 to 2024.5.6 (#4252)

  • pre-commit autoupdate (#4239)

  • Bumppytest from 8.1.1 to 8.2.0 (#4231)

  • Bumpdependabot/fetch-metadata from 2.0.0 to 2.1.0 (#4228)

  • Bumppytest-asyncio from 0.21.1 to 0.21.2 (#4232)

  • Bumppytest-xdist from 3.6.0 to 3.6.1 (#4233)

  • Bumpfuro from 2024.1.29 to 2024.4.27 (#4230)

  • Bumpsrvaroa/labeler from 1.10.0 to 1.10.1 (#4227)

  • Bumppytest from 7.4.4 to 8.1.1 (#4218)

  • Bumpsphinx from 7.2.6 to 7.3.7 (#4215)

  • Bumppytest-xdist from 3.5.0 to 3.6.0 (#4215)

Version 21.1.1

Released 2024-04-15

This is the technical changelog for version 21.1.1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Bug Fixes

  • Fix Bug With Parametermessage_thread_id ofMessage.reply_* (#4207 closes#4205)

Minor Changes

Version 21.1

Released 2024-04-12

This is the technical changelog for version 21.1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • API 7.2 (#4180 closes#4179 and#4181,#4181)

  • MakeChatAdministratorRights/ChatMemberAdministrator.can_*_stories Required (API 7.1) (#4192)

Minor Changes

  • Refactor Debug logging inBot to Improve Type Hinting (#4151 closes#4010)

New Features

Documentation Improvements

Internal Changes

  • Temporarily Mark Tests withget_sticker_set as XFAIL due to API 7.2 Update (#4190)

Dependency Updates

  • pre-commit autoupdate (#4184)

  • Bumpdependabot/fetch-metadata from 1.6.0 to 2.0.0 (#4185)

Version 21.0.1

Released 2024-03-06

This is the technical changelog for version 21.0.1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Bug Fixes

  • Removedocs from Package (#4150)

Version 21.0

Released 2024-03-06

This is the technical changelog for version 21.0. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Remove Functionality Deprecated in API 7.0 (#4114 closes#4099)

  • API 7.1 (#4118)

New Features

  • Add Parametermedia_write_timeout toHTTPXRequest and MethodApplicationBuilder.media_write_timeout (#4120 closes#3864)

  • Handle Properties inTelegramObject.__setstate__ (#4134 closes#4111)

Bug Fixes

Documentation Improvements

Internal Changes

  • Applypre-commit Checks More Widely (#4135)

  • Refactor and Overhaultest_official (#4087 closes#3874)

  • Run Unit Tests in PRs on Requirements Changes (#4144)

  • MakeUpdater.stop Independent ofCancelledError (#4126)

Dependency Updates

  • Relax Upper Bound forhttpx Dependency (#4148)

  • Bumptest-summary/action from 2.2 to 2.3 (#4142)

  • Updatecachetools requirement from ~=5.3.2 to ~=5.3.3 (#4141)

  • Updatehttpx requirement from ~=0.26.0 to ~=0.27.0 (#4131)

Version 20.8

Released 2024-02-08

This is the technical changelog for version 20.8. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

Minor Changes

  • Fix Type Hint forfilters Parameter ofMessageHandler (#4039 by@Palaptin)

  • Deprecatefilters.CHAT (#4083 closes#4062)

  • Improve Error Handling in Built-In Webhook Handler (#3987 closes#3979)

New Features

  • Add Parameterpattern toPreCheckoutQueryHandler andfilters.SuccessfulPayment (#4005 by@aelkheir closes#3752)

  • Add Missing Conversions oftype to Corresponding Enum fromtelegram.constants (#4067)

  • Add Support for Unix Sockets toUpdater.start_webhook (#3986 closes#3978)

  • AddBot.do_api_request (#4084 closes#4053)

  • AddAsyncContextManager as Parent Class toBaseUpdateProcessor (#4001)

Documentation Improvements

Internal Changes

  • Drop Usage of DeepSource (#4100)

  • Improve Type Completeness & Corresponding Workflow (#4035)

  • Bumpruff and Removesort-all (#4075)

  • Move Handler Files to_handlers Subdirectory (#4064 by@lucasmolinari closes#4060)

  • Introducesort-all Hook forpre-commit (#4052)

  • Use Recommendedpre-commit Mirror forblack (#4051)

  • Remove UnusedDEFAULT_20 (#3997)

  • Migrate Fromsetup.cfg topyproject.toml Where Possible (#4088)

Dependency Updates

  • Bumpblack andruff (#4089)

  • Bumpsrvaroa/labeler from 1.8.0 to 1.10.0 (#4048)

  • Updatetornado requirement from ~=6.3.3 to ~=6.4 (#3992)

  • Bumpactions/stale from 8 to 9 (#4046)

  • Bumpactions/setup-python from 4 to 5 (#4047)

  • pre-commit autoupdate (#4101)

  • Bumpactions/upload-artifact from 3 to 4 (#4045)

  • pre-commit autoupdate (#3996)

  • Bumpfuro from 2023.9.10 to 2024.1.29 (#4094)

  • pre-commit autoupdate (#4043)

  • Bumpcodecov/codecov-action from 3 to 4 (#4091)

  • BumpEndBug/add-and-commit from 9.1.3 to 9.1.4 (#4090)

  • Updatehttpx requirement from ~=0.25.2 to ~=0.26.0 (#4024)

  • Bumppytest from 7.4.3 to 7.4.4 (#4056)

  • Bumpsrvaroa/labeler from 1.7.0 to 1.8.0 (#3993)

  • Bumptest-summary/action from 2.1 to 2.2 (#4044)

  • Bumpdessant/lock-threads from 4.0.1 to 5.0.1 (#3994)

Version 20.7

Released 2023-11-27

This is the technical changelog for version 20.7. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

New Features

  • AddJobQueue.scheduler_configuration and Corresponding Warnings (#3913 closes#3837)

  • Add Parametersocket_options toHTTPXRequest (#3935 closes#2965)

  • AddApplicationBuilder.(get_updates_)socket_options (#3943)

  • Improvewrite_timeout Handling for Media Methods (#3952)

  • Addfilters.Mention (#3941 closes#3799)

  • Renameproxy_url toproxy and Allowhttpx.{Proxy,URL} as Input (#3939 closes#3844)

Bug Fixes & Changes

  • Adjustread_timeout Behavior forBot.get_updates (#3963 closes#3893)

  • ImproveBaseHandler.__repr__ for Callbacks without__qualname__ (#3934)

  • Fix Persistency Issue with Ended Non-Blocking Conversations (#3962)

  • Improve Type Hinting for Arguments with Default Values inBot (#3942)

Documentation Improvements

  • Add Documentation for__aenter__ and__aexit__ Methods (#3907 closes#3886)

  • Improve Insertion of Kwargs intoBot Methods (#3965)

Internal Changes

  • Adjust Tests to New Error Messages (#3970)

Dependency Updates

  • Bumppytest-xdist from 3.3.1 to 3.4.0 (#3975)

  • pre-commit autoupdate (#3967)

  • Updatehttpx requirement from ~=0.25.1 to ~=0.25.2 (#3983)

  • Bumppytest-xdist from 3.4.0 to 3.5.0 (#3982)

  • Updatehttpx requirement from ~=0.25.0 to ~=0.25.1 (#3961)

  • Bumpsrvaroa/labeler from 1.6.1 to 1.7.0 (#3958)

  • Updatecachetools requirement from ~=5.3.1 to ~=5.3.2 (#3954)

  • Bumppytest from 7.4.2 to 7.4.3 (#3953)

Version 20.6

Released 2023-10-03

This is the technical changelog for version 20.6. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Drop Backward Compatibility Layer Introduced in#3853 (API 6.8) (#3873)

  • Full Support for Bot API 6.9 (#3898)

New Features

  • Add Rich Equality Comparison toWriteAccessAllowed (#3911 closes#3909)

  • Add__repr__ Methods Added in#3826 closes#3770 to Sphinx Documentation (#3901 closes#3889)

  • Add String Representation for Selected Classes (#3826 closes#3770)

Minor Changes

  • Add Support Python 3.12 (#3915)

  • Documentation Improvements (#3910)

Internal Changes

  • Verify Type Hints for Bot Method & Telegram Class Parameters (#3868)

  • Move Bot API Tests to Separate Workflow File (#3912)

  • Fix Failingfile_size Tests (#3906)

  • Set Threshold for DeepSource’s PY-R1000 to High (#3888)

  • One-Time Code Formatting Improvement via--preview Flag ofblack (#3882)

  • Move Dunder Methods to the Top of Class Bodies (#3883)

  • Remove SuperfluousDefaults.__ne__ (#3884)

Dependency Updates

  • pre-commit autoupdate (#3876)

  • Updatepre-commit Dependencies (#3916)

  • Bumpactions/checkout from 3 to 4 (#3914)

  • Updatehttpx requirement from ~=0.24.1 to ~=0.25.0 (#3891)

  • Bumpfuro from 2023.8.19 to 2023.9.10 (#3890)

  • Bumpsphinx from 7.2.5 to 7.2.6 (#3892)

  • Updatetornado requirement from ~=6.2 to ~=6.3.3 (#3675)

  • Bumppytest from 7.4.0 to 7.4.2 (#3881)

Version 20.5

Released 2023-09-03

This is the technical changelog for version 20.5. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • API 6.8 (#3853)

  • Remove Functionality Deprecated Since Bot API 6.5, 6.6 or 6.7 (#3858)

New Features

  • Extend Allowed Values for HTTP Version (#3823 closes#3821)

  • Addhas_args Parameter toCommandHandler (#3854 by@thatguylah closes#3798)

  • AddApplication.stop_running() and Improve Marking Updates as Read onUpdater.stop() (#3804)

Minor Changes

  • Type Hinting Fixes forWebhookInfo (#3871)

  • Test and DocumentException.__cause__ onNetworkError (#3792 closes#3778)

  • Add Support for Python 3.12 RC (#3847)

Documentation Improvements

Dependency Updates

  • pre-commit autoupdate (#3824)

  • Bumpsrvaroa/labeler from 1.6.0 to 1.6.1 (#3870)

  • Bumpsphinx from 7.0.1 to 7.1.1 (#3818)

  • Bumpsphinx from 7.2.3 to 7.2.5 (#3869)

  • Bumpfuro from 2023.5.20 to 2023.7.26 (#3817)

  • Updateapscheduler requirement from ~=3.10.3 to ~=3.10.4 (#3862)

  • Bumpsphinx from 7.2.2 to 7.2.3 (#3861)

  • Bumppytest-asyncio from 0.21.0 to 0.21.1 (#3801)

  • Bumpsphinx-paramlinks from 0.5.4 to 0.6.0 (#3840)

  • Updateapscheduler requirement from ~=3.10.1 to ~=3.10.3 (#3851)

  • Bumpfuro from 2023.7.26 to 2023.8.19 (#3850)

  • Bumpsphinx from 7.1.2 to 7.2.2 (#3852)

  • Bumpsphinx from 7.1.1 to 7.1.2 (#3827)

Version 20.4

Released 2023-07-09

This is the technical changelog for version 20.4. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

New Features

  • Make Integration ofAPScheduler intoJobQueue More Explicit (#3695)

  • IntroduceBaseUpdateProcessor for Customized Concurrent Handling of Updates (#3654 closes#3509)

Minor Changes

Bug Fixes

  • Fix Wrong Warning Text inKeyboardButton.__eq__ (#3768)

Documentation Improvements

  • Explicitly setallowed_updates in Examples (#3741 by@Trifase closes#3726)

  • Bumpfuro andsphinx (#3719)

  • Documentation Improvements (#3698,#3708 by@revolter,#3767)

  • Add Quotes for Installation Instructions With Optional Dependencies (#3780)

  • Exclude Type Hints from Stability Policy (#3712)

  • Sethttpx Logging Level to Warning in Examples (#3746 closes#3743)

Internal Changes

  • Drop a Legacypre-commit.ci Configuration (#3697)

  • Add Python 3.12 Beta to the Test Matrix (#3751)

  • Use Temporary Files for Testing File Downloads (#3777)

  • Auto-Update Changed Version in Other Files After Dependabot PRs (#3716)

  • Add Moreruff Rules (#3763)

  • Rename_handler.py to_basehandler.py (#3761)

  • Automatically Labelpre-commit-ci PRs (#3713)

  • Reworkpytest Integration into GitHub Actions (#3776)

  • Fix Two Bugs in GitHub Actions Workflows (#3739)

Dependency Updates

  • Updatecachetools requirement from ~=5.3.0 to ~=5.3.1 (#3738)

  • Updateaiolimiter requirement from ~=1.0.0 to ~=1.1.0 (#3707)

  • pre-commit autoupdate (#3791)

  • Bumpsphinxcontrib-mermaid from 0.8.1 to 0.9.2 (#3737)

  • Bumppytest-xdist from 3.2.1 to 3.3.0 (#3705)

  • Bumpsrvaroa/labeler from 1.5.0 to 1.6.0 (#3786)

  • Bumpdependabot/fetch-metadata from 1.5.1 to 1.6.0 (#3787)

  • Bumpdessant/lock-threads from 4.0.0 to 4.0.1 (#3785)

  • Bumppytest from 7.3.2 to 7.4.0 (#3774)

  • Updatehttpx requirement from ~=0.24.0 to ~=0.24.1 (#3715)

  • Bumppytest-xdist from 3.3.0 to 3.3.1 (#3714)

  • Bumppytest from 7.3.1 to 7.3.2 (#3758)

  • pre-commit autoupdate (#3747)

Version 20.3

Released 2023-05-07

This is the technical changelog for version 20.3. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full support for API 6.7 (#3673)

  • Add a Stability Policy (#3622)

New Features

  • AddApplication.mark_data_for_update_persistence (#3607)

  • MakeMessage.link Point to Thread View Where Possible (#3640)

  • Localize Receiveddatetime Objects According toDefaults.tzinfo (#3632)

Minor Changes, Documentation Improvements and CI

  • Empowerruff (#3594)

  • Drop Usage ofsys.maxunicode (#3630)

  • Add String Representation forRequestParameter (#3634)

  • Stabilize CI by Rerunning Failed Tests (#3631)

  • Give Loggers Better Names (#3623)

  • Add Logging for Invalid JSON Data inBasePersistence.parse_json_payload (#3668)

  • Improve Warning Categories & Stacklevels (#3674)

  • Stabilizetest_delete_sticker_set (#3685)

  • Shield Update Fetcher Task inApplication.start (#3657)

  • Recover 100% Type Completeness (#3676)

  • Documentation Improvements (#3628,#3636,#3694)

Dependencies

  • Bumpactions/stale from 7 to 8 (#3644)

  • Bumpfuro from 2023.3.23 to 2023.3.27 (#3643)

  • pre-commit autoupdate (#3646,#3688)

  • Remove Deprecatedcodecov Package from CI (#3664)

  • Bumpsphinx-copybutton from 0.5.1 to 0.5.2 (#3662)

  • Updatehttpx requirement from ~=0.23.3 to ~=0.24.0 (#3660)

  • Bumppytest from 7.2.2 to 7.3.1 (#3661)

Version 20.2

Released 2023-03-25

This is the technical changelog for version 20.2. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for API 6.6 (#3584)

  • Revert to HTTP/1.1 as Default and make HTTP/2 an Optional Dependency (#3576)

Minor Changes, Documentation Improvements and CI

  • Documentation Improvements (#3565,#3600)

  • Handle Symbolic Links inwas_called_by (#3552)

  • Tidy Up Tests Directory (#3553)

  • EnhanceApplication.create_task (#3543)

  • Make Type Completeness Workflow Usable forPRs from Forks (#3551)

  • Refactor and Overhaul the Test Suite (#3426)

Dependencies

  • Bumppytest-asyncio from 0.20.3 to 0.21.0 (#3624)

  • Bumpfuro from 2022.12.7 to 2023.3.23 (#3625)

  • Bumppytest-xdist from 3.2.0 to 3.2.1 (#3606)

  • pre-commit autoupdate (#3577)

  • Updateapscheduler requirement from ~=3.10.0 to ~=3.10.1 (#3572)

  • Bumppytest from 7.2.1 to 7.2.2 (#3573)

  • Bumppytest-xdist from 3.1.0 to 3.2.0 (#3550)

  • Bumpsphinxcontrib-mermaid from 0.7.1 to 0.8 (#3549)

Version 20.1

Released 2023-02-09

This is the technical changelog for version 20.1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for Bot API 6.5 (#3530)

New Features

  • AddApplication(Builder).post_stop (#3466)

  • AddChat.effective_name Convenience Property (#3485)

  • Allow to Adjust HTTP Version and Use HTTP/2 by Default (#3506)

Documentation Improvements

Minor Changes, Documentation Improvements and CI

  • Update Copyright to 2023 (#3459)

  • Stabilize Tests on Closing and Hiding the General Forum Topic (#3460)

  • Fix Dependency Warning Typo (#3474)

  • Cache Dependencies onGitHub Actions (#3469)

  • Store Documentation Builts asGitHub Actions Artifacts (#3468)

  • Addruff topre-commit Hooks (#3488)

  • Improve Warning fordays Parameter ofJobQueue.run_daily (#3503)

  • Improve Error Message forNetworkError (#3505)

  • Lock Inactive Threads Only Once Each Day (#3510)

  • Bumppytest from 7.2.0 to 7.2.1 (#3513)

  • Check for 3D Arrays incheck_keyboard_type (#3514)

  • Explicit Type Annotations (#3508)

  • Increase Verbosity of Type Completeness CI Job (#3531)

  • Fix CI on Python 3.11 + Windows (#3547)

Dependencies

  • Bumpactions/stale from 6 to 7 (#3461)

  • Bumpdessant/lock-threads from 3.0.0 to 4.0.0 (#3462)

  • pre-commit autoupdate (#3470)

  • Updatehttpx requirement from ~=0.23.1 to ~=0.23.3 (#3489)

  • Updatecachetools requirement from ~=5.2.0 to ~=5.2.1 (#3502)

  • Improve Config forruff and Bump tov0.0.222 (#3507)

  • Updatecachetools requirement from ~=5.2.1 to ~=5.3.0 (#3520)

  • Bumpisort to 5.12.0 (#3525)

  • Updateapscheduler requirement from ~=3.9.1 to ~=3.10.0 (#3532)

  • pre-commit autoupdate (#3537)

  • Updatecryptography requirement to >=39.0.1 to address Vulnerability (#3539)

Version 20.0

Released 2023-01-01

This is the technical changelog for version 20.0. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support For Bot API 6.4 (#3449)

Minor Changes, Documentation Improvements and CI

  • Documentation Improvements (#3428,#3423,#3429,#3441,#3404,#3443)

  • AllowSequence Input for Bot Methods (#3412)

  • Update Link-Check CI and Replace a Dead Link (#3456)

  • Freeze Classes Without Arguments (#3453)

  • Add New Constants (#3444)

  • OverrideBot.__deepcopy__ to RaiseTypeError (#3446)

  • Add Log Decorator toBot.get_webhook_info (#3442)

  • Add Documentation On Verifying Releases (#3436)

  • Drop UndocumentedJob.__lt__ (#3432)

Dependencies

  • Downgradesphinx to 5.3.0 to Fix Search (#3457)

  • Bumpsphinx from 5.3.0 to 6.0.0 (#3450)

Version 20.0b0

Released 2022-12-15

This is the technical changelog for version 20.0b0. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • MakeTelegramObject Immutable (#3249)

Minor Changes, Documentation Improvements and CI

  • Reduce Code Duplication in TestingDefaults (#3419)

  • Add Notes and Warnings About Optional Dependencies (#3393)

  • Simplify Internals ofBot Methods (#3396)

  • Reduce Code Duplication in SeveralBot Methods (#3385)

  • Documentation Improvements (#3386,#3395,#3398,#3403)

Dependencies

  • Bumppytest-xdist from 3.0.2 to 3.1.0 (#3415)

  • Bumppytest-asyncio from 0.20.2 to 0.20.3 (#3417)

  • pre-commit autoupdate (#3409)

Version 20.0a6

Released 2022-11-24

This is the technical changelog for version 20.0a6. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Bug Fixes

  • Only Persist Arbitrarycallback_data ifExtBot.callback_data_cache is Present (#3384)

  • Improve Backwards Compatibility ofTelegramObjects Pickle Behavior (#3382)

  • Fix Naming and Keyword Arguments ofFile.download_* Methods (#3380)

  • Fix Return Value Annotation ofChat.create_forum_topic (#3381)

Version 20.0a5

Released 2022-11-22

This is the technical changelog for version 20.0a5. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • API 6.3 (#3346,#3343,#3342,#3360)

  • Explicitlocal_mode Setting (#3154)

  • Make Almost All 3rd Party Dependencies Optional (#3267)

  • SplitFile.download IntoFile.download_to_drive AndFile.download_to_memory (#3223)

New Features

  • Add Properties for API Settings ofBot (#3247)

  • Addchat_id andusername Parameters toChatJoinRequestHandler (#3261)

  • IntroduceTelegramObject.api_kwargs (#3233)

  • Add Two Constants Related to Local Bot API Servers (#3296)

  • Addrecursive Parameter toTelegramObject.to_dict() (#3276)

  • Overhaul String Representation ofTelegramObject (#3234)

  • Add MethodsChat.mention_{html,markdown,markdown_v2} (#3308)

  • Addconstants.MessageLimit.DEEP_LINK_LENGTH (#3315)

  • Add Shortcut Parameterscaption,parse_mode andcaption_entities toBot.send_media_group (#3295)

  • Add Several New Enums To Constants (#3351)

Bug Fixes

  • FixCallbackQueryHandler Not Handling Non-String Data Correctly With Regex Patterns (#3252)

  • Fix Defaults Handling inBot.answer_web_app_query (#3362)

Documentation Improvements

Minor Changes, Documentation Improvements and CI

  • Improve Warning About UnknownConversationHandler States (#3242)

  • Switch from Stale Bot toGitHub Actions (#3243)

  • Bump Python 3.11 to RC2 in Test Matrix (#3246)

  • MakeJob.job a Property and MakeJobs Hashable (#3250)

  • SkipJobQueue Tests on Windows Again (#3280)

  • Read-OnlyCallbackDataCache (#3266)

  • Type Hinting Fix forMessage.effective_attachment (#3294)

  • Run Unit Tests in Parallel (#3283)

  • Update Test Matrix to Use Stable Python 3.11 (#3313)

  • Don’t Edit Objects In-Place When Insertingext.Defaults (#3311)

  • Add a Test forMessageAttachmentType (#3335)

  • Add Three New Test Bots (#3347)

  • Improve Unit Tests RegardingChatMemberUpdated.difference (#3352)

  • Flaky Unit Tests: Usepytest Marker (#3354)

  • FixDeepSource Issues (#3357)

  • Handle Lists and Tuples and Datetimes Directly inTelegramObject.to_dict (#3353)

  • Update Meta Config (#3365)

  • MergeChatDescriptionLimit Enum IntoChatLimit (#3377)

Dependencies

  • Bumppytest from 7.1.2 to 7.1.3 (#3228)

  • pre-commit Updates (#3221)

  • Bumpsphinx from 5.1.1 to 5.2.3 (#3269)

  • Bumpfuro from 2022.6.21 to 2022.9.29 (#3268)

  • Bumpactions/stale from 5 to 6 (#3277)

  • pre-commit autoupdate (#3282)

  • Bumpsphinx from 5.2.3 to 5.3.0 (#3300)

  • Bumppytest-asyncio from 0.19.0 to 0.20.1 (#3299)

  • Bumppytest from 7.1.3 to 7.2.0 (#3318)

  • Bumppytest-xdist from 2.5.0 to 3.0.2 (#3317)

  • pre-commit autoupdate (#3325)

  • Bumppytest-asyncio from 0.20.1 to 0.20.2 (#3359)

  • Updatehttpx requirement from ~=0.23.0 to ~=0.23.1 (#3373)

Version 20.0a4

Released 2022-08-27

This is the technical changelog for version 20.0a4. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Hot Fixes

  • Fix a Bug insetup.py Regarding Optional Dependencies (#3209)

Version 20.0a3

Released 2022-08-27

This is the technical changelog for version 20.0a3. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for API 6.2 (#3195)

New Features

  • New Rate Limiting Mechanism (#3148)

  • Makechat/user_data Available in Error Handler for Errors in Jobs (#3152)

  • AddApplication.post_shutdown (#3126)

Bug Fixes

  • Fixhelpers.mention_markdown for Markdown V1 and Improve Related Unit Tests (#3155)

  • Addapi_kwargs Parameter toBot.log_out and Improve Related Unit Tests (#3147)

  • MakeBot.delete_my_commands a Coroutine Function (#3136)

  • FixConversationHandler.check_update not respectingper_user (#3128)

Minor Changes, Documentation Improvements and CI

  • Add Python 3.11 to Test Suite & Adapt Enum Behaviour (#3168)

  • Drop Manual Token Validation (#3167)

  • Simplify Unit Tests forBot.send_chat_action (#3151)

  • Droppre-commit Dependencies fromrequirements-dev.txt (#3120)

  • Change Default Values forconcurrent_updates andconnection_pool_size (#3127)

  • Documentation Improvements (#3139,#3153,#3135)

  • Type Hinting Fixes (#3202)

Dependencies

  • Bumpsphinx from 5.0.2 to 5.1.1 (#3177)

  • Updatepre-commit Dependencies (#3085)

  • Bumppytest-asyncio from 0.18.3 to 0.19.0 (#3158)

  • Updatetornado requirement from ~=6.1 to ~=6.2 (#3149)

  • Bumpblack from 22.3.0 to 22.6.0 (#3132)

  • Bumpactions/setup-python from 3 to 4 (#3131)

Version 20.0a2

Released 2022-06-27

This is the technical changelog for version 20.0a2. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes

  • Full Support for API 6.1 (#3112)

New Features

  • Add Additional Shortcut Methods toChat (#3115)

  • Mermaid-based Example State Diagrams (#3090)

Minor Changes, Documentation Improvements and CI

  • Documentation Improvements (#3103,#3121,#3098)

  • Stabilize CI (#3119)

  • Bumppyupgrade from 2.32.1 to 2.34.0 (#3096)

  • Bumpfuro from 2022.6.4 to 2022.6.4.1 (#3095)

  • Bumpmypy from 0.960 to 0.961 (#3093)

Version 20.0a1

Released 2022-06-09

This is the technical changelog for version 20.0a1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Drop Support forujson and insteadBaseRequest.parse_json_payload (#3037,#3072)

  • DropInputFile.is_image (#3053)

  • Drop Explicit Type conversions in__init__ s (#3056)

  • Handle List-Valued Attributes More Consistently (#3057)

  • Split{Command,Prefix}Handler And Make Attributes Immutable (#3045)

  • Align Behavior OfJobQueue.run_daily Withcron (#3046)

  • Make PTB Specific Keyword-Only Arguments for PTB Specific in Bot methods (#3035)

  • Adjust Equality Comparisons to Fit Bot API 6.0 (#3033)

  • Add Tuple Based Version Info (#3030)

  • Improve Type Annotations forCallbackContext and Move Default Type Alias toContextTypes.DEFAULT_TYPE (#3017,#3023)

  • RenameJob.context toJob.data (#3028)

  • RenameHandler toBaseHandler (#3019)

New Features:

  • AddApplication.post_init (#3078)

  • Add Argumentschat/user_id toCallbackContext And Example On Custom Webhook Setups (#3059)

  • Add Convenience PropertyMessage.id (#3077)

  • Add Example forWebApp (#3052)

  • Renametelegram.bot_api_version totelegram.__bot_api_version__ (#3030)

Bug Fixes:

  • Fix Non-Blocking Entry Point inConversationHandler (#3068)

  • Escape Backslashes inescape_markdown (#3055)

Dependencies:

  • Updatehttpx requirement from ~=0.22.0 to ~=0.23.0 (#3069)

  • Updatecachetools requirement from ~=5.0.0 to ~=5.2.0 (#3058,#3080)

Minor Changes, Documentation Improvements and CI:

  • Move Examples To Documentation (#3089)

  • Documentation Improvements and Update Dependencies (#3010,#3007,#3012,#3067,#3081,#3082)

  • Improve Some Unit Tests (#3026)

  • Update Code Quality dependencies (#3070,#3032,:pr:2998,#2999)

  • Don’t Set Signal Handlers On Windows By Default (#3065)

  • Split{Command,Prefix}Handler And Make Attributes Immutable (#3045)

  • Applyisort and Updatepre-commit.ci Configuration (#3049)

  • Adjustpre-commit Settings forisort (#3043)

  • Add Version Check to Examples (#3036)

  • UseCollection Instead ofList andTuple (#3025)

  • Remove Client-Side Parameter Validation (#3024)

  • Don’t Pass Default Values of Optional Parameters to Telegram (#2978)

  • StabilizeApplication.run_* on Python 3.7 (#3009)

  • Ignore Code Style Commits ingitblame (#3003)

  • Adjust Tests to Changed API Behavior (#3002)

Version 20.0a0

Released 2022-05-06

This is the technical changelog for version 20.0a0. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Refactor Initialization of Persistence Classes(#2604)

  • Drop Non-CallbackContext API(#2617)

  • Remove__dict__ from__slots__ and drop Python 3.6(#2619,#2636)

  • Move and RenameTelegramDecryptionError totelegram.error.PassportDecryptionError(#2621)

  • MakeBasePersistence Methods Abstract(#2624)

  • Removeday_is_strict argument ofJobQueue.run_monthly(#2634byiota-008)

  • MoveDefaults totelegram.ext(#2648)

  • Remove Deprecated Functionality(#2644,#2740,#2745)

  • Overhaul of Filters(#2759,#2922)

  • Switch toasyncio and Refactor PTBs Architecture(#2731)

  • ImproveJob.__getattr__(#2832)

  • Removetelegram.ReplyMarkup(#2870)

  • Persistence ofBots: Refactor Automatic Replacement andIntegration withTelegramObject(#2893)

New Features:

  • Introduce Builder Pattern(#2646)

  • AddFilters.update.edited(#2705byPhilippFr)

  • IntroduceEnums fortelegram.constants(#2708)

  • Accept File Paths forprivate_key(#2724)

  • AssociateJobs withchat/user_id(#2731)

  • Convenience Functionality forChatInviteLinks(#2782)

  • AddDispatcher.add_handlers(#2823)

  • Improve Error Messages inCommandHandler.__init__(#2837)

  • Defaults.protect_content(#2840)

  • AddDispatcher.migrate_chat_data(#2848byDonalDuck004)

  • Add Methoddrop_chat/user_data toDispatcher and Persistence(#2852)

  • Add methodsChatPermissions.{all,no}_permissions (#2948)

  • Full Support for API 6.0(#2956)

  • Add Python 3.10 to Test Suite(#2968)

Bug Fixes & Minor Changes:

  • Improve Type Hinting forCallbackContext(#2587byrevolter)

  • Fix Signatures and Improvetest_official(#2643)

  • RefineDispatcher.dispatch_error(#2660)

  • MakeInlineQuery.answer RaiseValueError(#2675)

  • Improve Signature Inspection for Bot Methods(#2686)

  • IntroduceTelegramObject.set/get_bot(#2712byzpavloudis)

  • Improve Subscription ofTelegramObject(#2719bySimonDamberg)

  • Use Enums for Dynamic Types & Rename Two Attributes inChatMember(#2817)

  • Return Plain Dicts fromBasePersistence.get_*_data(#2873)

  • Fix a Bug inChatMemberUpdated.difference(#2947)

  • Update Dependency Policy(#2958)

Internal Restructurings & Improvements:

  • Add User Friendly Type Check For Init Of{Inline,Reply}KeyboardMarkup(#2657)

  • Warnings Overhaul(#2662)

  • Clear Up Import Policy(#2671)

  • Mark Internal Modules As Private(#2687bykencx)

  • Handle Filepaths via thepathlib Module(#2688byeldbud)

  • Refactor MRO ofInputMedia* and Some File-Like Classes(#2717byeldbud)

  • Update Exceptions for Immutable Attributes(#2749)

  • Refactor Warnings inConversationHandler(#2755,#2784)

  • Use__all__ Consistently(#2805)

CI, Code Quality & Test Suite Improvements:

  • Add Custompytest Marker to Ease Development(#2628)

  • Pass Failing Jobs to Error Handlers(#2692)

  • Update Notification Workflows(#2695)

  • Use Error Messages forpylint Instead of Codes(#2700byPiraty)

  • Make Tests Agnostic of the CWD(#2727byeldbud)

  • Update Code Quality Dependencies(#2748)

  • Improve Code Quality(#2783)

  • Updatepre-commit Settings & Improve a Test(#2796)

  • Improve Code Quality & Test Suite(#2843)

  • Fix failing animation tests(#2865)

  • Update and Expand Tests & pre-commit Settings and Improve CodeQuality(#2925)

  • Extend Code Formatting With Black(#2972)

  • Update Workflow Permissions(#2984)

  • Adapt Tests to ChangedBot.get_file Behavior(#2995)

Documentation Improvements:

  • Doc Fixes(#2597)

  • Add Code Comment Guidelines to Contribution Guide(#2612)

  • Add Cross-References to External Libraries & Other DocumentationImprovements(#2693,#2691byjoesinghh,#2739byeldbud)

  • Use Furo Theme, Make Parameters Referenceable, Add DocumentationBuilding to CI, Improve Links to Source Code & Other Improvements(#2856,#2798,#2854,#2841)

  • Documentation Fixes & Improvements(#2822)

  • Replacegit.io Links(#2872bymurugu-21)

  • Overhaul Readmes, Update RTD Startpage & Other Improvements(#2969)

Version 13.11

Released 2022-02-02

This is the technical changelog for version 13.11. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Full Support for Bot API 5.7 (#2881)

Version 13.10

Released 2022-01-03

This is the technical changelog for version 13.10. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Full Support for API 5.6 (#2835)

Minor Changes & Doc fixes:

  • Update Copyright to 2022 (#2836)

  • Update Documentation ofBotCommand (#2820)

Version 13.9

Released 2021-12-11

This is the technical changelog for version 13.9. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Full Support for Api 5.5 (#2809)

Minor Changes

  • Adjust Automated Locking of Inactive Issues (#2775)

Version 13.8.1

Released 2021-11-08

This is the technical changelog for version 13.8.1. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Doc fixes:

  • AddChatJoinRequest(Handler) to Docs (#2771)

Version 13.8

Released 2021-11-08

This is the technical changelog for version 13.8. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Full support for API 5.4 (#2767)

Minor changes, CI improvements, Doc fixes and Type hinting:

  • Create Issue Template Forms (#2689)

  • FixcamelCase Functions inExtBot (#2659)

  • Fix Empty Captions not Being Passed byBot.copy_message (#2651)

  • Fix Setting Thumbs When Uploading A Single File (#2583)

  • Fix Bug inBasePersistence.insert/replace_bot for Objects with__dict__ not in__slots__ (#2603)

Version 13.7

Released 2021-07-01

This is the technical changelog for version 13.7. More elaborate release notes can be found in the news channel@pythontelegrambotchannel.

Major Changes:

  • Full support for Bot API 5.3 (#2572)

Bug Fixes:

  • Fix Bug inBasePersistence.insert/replace_bot for Objects with__dict__ in their slots (#2561)

  • Remove Incorrect Warning AboutDefaults andExtBot (#2553)

Minor changes, CI improvements, Doc fixes and Type hinting:

  • Type Hinting Fixes (#2552)

  • Doc Fixes (#2551)

  • Improve Deprecation Warning for__slots__ (#2574)

  • Stabilize CI (#2575)

  • Fix Coverage Configuration (#2571)

  • Better Exception-Handling forBasePersistence.replace/insert_bot (#2564)

  • Remove Deprecatedpass_args from Deeplinking Example (#2550)

Version 13.6

Released 2021-06-06

New Features:

  • Arbitrarycallback_data (#1844)

  • AddContextTypes &BasePersistence.refresh_user/chat/bot_data (#2262)

  • AddFilters.attachment (#2528)

  • Addpattern Argument toChosenInlineResultHandler (#2517)

Major Changes:

Minor changes, CI improvements, Doc fixes and Type hinting:

  • Doc Fixes (#2495,#2510)

  • Addmax_connections Parameter toUpdater.start_webhook (#2547)

  • Fix forPromise.done_callback (#2544)

  • Improve Code Quality (#2536,#2454)

  • Increase Test Coverage ofCallbackQueryHandler (#2520)

  • Stabilize CI (#2522,#2537,#2541)

  • Fixsend_phone_number_to_provider argument forBot.send_invoice (#2527)

  • Handle Classes as Input forBasePersistence.replace/insert_bot (#2523)

  • Bump Tornado Version and Remove Workaround from#2067 (#2494)

Version 13.5

Released 2021-04-30

Major Changes:

  • Full support of Bot API 5.2 (#2489).

    Note

    Thestart_parameter argument ofBot.send_invoice and the corresponding shortcuts is now optional, so the order ofparameters had to be changed. Make sure to update your method calls accordingly.

  • UpdateChatActions, DeprecatingChatAction.RECORD_AUDIO andChatAction.UPLOAD_AUDIO (#2460)

New Features:

  • Convenience Utilities & Example for HandlingChatMemberUpdated (#2490)

  • Filters.forwarded_from (#2446)

Minor changes, CI improvements, Doc fixes and Type hinting:

  • Improve Timeouts inConversationHandler (#2417)

  • Stabilize CI (#2480)

  • Doc Fixes (#2437)

  • Improve Type Hints of Data Filters (#2456)

  • Add TwoUserWarnings (#2464)

  • Improve Code Quality (#2450)

  • Update Fallback Test-Bots (#2451)

  • Improve Examples (#2441,#2448)

Version 13.4.1

Released 2021-03-14

Hot fix release:

  • Fixed a bug insetup.py (#2431)

Version 13.4

Released 2021-03-14

Major Changes:

  • Full support of Bot API 5.1 (#2424)

Minor changes, CI improvements, doc fixes and type hinting:

  • ImproveUpdater.set_webhook (#2419)

  • Doc Fixes (#2404)

  • Type Hinting Fixes (#2425)

  • Updatepre-commit Settings (#2415)

  • Fix Logging for Vendoredurllib3 (#2427)

  • Stabilize Tests (#2409)

Version 13.3

Released 2021-02-19

Major Changes:

  • Makecryptography Dependency Optional & Refactor Some Tests (#2386,#2370)

  • DeprecateMessageQueue (#2393)

Bug Fixes:

  • RefactorDefaults Integration (#2363)

  • Add Missingtelegram.SecureValue to init and Docs (#2398)

Minor changes:

Version 13.2

Released 2021-02-02

Major Changes:

  • Introducepython-telegram-bot-raw (#2324)

  • Explicit Signatures for Shortcuts (#2240)

New Features:

  • Add Missing Shortcuts toMessage (#2330)

  • Rich Comparison forBot (#2320)

  • Addrun_async Parameter toConversationHandler (#2292)

  • Add New Shortcuts toChat (#2291)

  • Add New ConstantMAX_ANSWER_CALLBACK_QUERY_TEXT_LENGTH (#2282)

  • Allow Passing Custom Filename For All Media (#2249)

  • Handle Bytes as File Input (#2233)

Bug Fixes:

  • Fix Escaping in Nested Entities inMessage Properties (#2312)

  • Adjust Calling ofDispatcher.update_persistence (#2285)

  • Addquote kwarg toMessage.reply_copy (#2232)

  • ConversationHandler: Docs &edited_channel_post behavior (#2339)

Minor changes, CI improvements, doc fixes and type hinting:

  • Doc Fixes (#2253,#2225)

  • Reduce Usage oftyping.Any (#2321)

  • Extend Deeplinking Example (#2335)

  • Add pyupgrade to pre-commit Hooks (#2301)

  • Add PR Template (#2299)

  • Drop Nightly Tests & Update Badges (#2323)

  • Update Copyright (#2289,#2287)

  • Change Order of Class DocStrings (#2256)

  • Add macOS to Test Matrix (#2266)

  • Start Using Versioning Directives in Docs (#2252)

  • Improve Annotations & Docs of Handlers (#2243)

Version 13.1

Released 2020-11-29

Major Changes:

New Features:

  • AddDefaults.run_async (#2210)

  • Improve and ExpandCallbackQuery Shortcuts (#2172)

  • Add XOR Filters and makeFilters.name a Property (#2179)

  • AddFilters.document.file_extension (#2169)

  • AddFilters.caption_regex (#2163)

  • AddFilters.chat_type (#2128)

  • Handle Non-Binary File Input (#2202)

Bug Fixes:

  • Improve Handling of Custom Objects inBasePersistence.insert/replace_bot (#2151)

  • Fix bugs inreplace/insert_bot (#2218)

Minor changes, CI improvements, doc fixes and type hinting:

Version 13.0

Released 2020-10-07

For a detailed guide on how to migrate from v12 to v13, see thiswiki page.

Major Changes:

  • Deprecate old-style callbacks, i.e. setuse_context=True by default (#2050)

  • Refactor Handling of Message VS Update Filters (#2032)

  • DeprecateMessage.default_quote (#1965)

  • Refactor persistence of Bot instances (#1994)

  • RefactorJobQueue (#1981)

  • Refactor handling of kwargs in Bot methods (#1924)

  • RefactorDispatcher.run_async, deprecating the@run_async decorator (#2051)

New Features:

  • Type Hinting (#1920)

  • Automatic Pagination foranswer_inline_query (#2072)

  • Defaults.tzinfo (#2042)

  • Extend rich comparison of objects (#1724)

  • AddFilters.via_bot (#2009)

  • Add missing shortcuts (#2043)

  • AllowDispatcherHandlerStop inConversationHandler (#2059)

  • Make Errors picklable (#2106)

Minor changes, CI improvements, doc fixes or bug fixes:

  • Fix Webhook not working on Windows with Python 3.8+ (#2067)

  • Fix setting thumbs withsend_media_group (#2093)

  • MakeMessageHandler filter forFilters.update first (#2085)

  • FixPicklePersistence.flush() with onlybot_data (#2017)

  • Add test for clean argument ofUpdater.start_polling/webhook (#2002)

  • Doc fixes, refinements and additions (#2005,#2008,#2089,#2094,#2090)

  • CI fixes (#2018,#2061)

  • Refinepollbot.py example (#2047)

  • Refine Filters in examples (#2027)

  • Renameechobot examples (#2025)

  • Use Lock-Bot to lock old threads (#2048,#2052,#2049,#2053)

Version 12.8

Released 2020-06-22

Major Changes:

  • Remove Python 2 support (#1715)

  • Bot API 4.9 support (#1980)

  • IDs/Usernames ofFilters.user andFilters.chat can now be updated (#1757)

Minor changes, CI improvements, doc fixes or bug fixes:

Version 12.7

Released 2020-05-02

Major Changes:

  • Bot API 4.8 support.Note: TheDice object now has a second positional argumentemoji. This is relevant, if you instantiateDice objects manually. (#1917)

  • Addedtzinfo argument tohelpers.from_timestamp. It now returns an timezone aware object. This is relevant forMessage.{date,forward_date,edit_date},Poll.close_date andChatMember.until_date (#1621)

New Features:

  • New methodrun_monthly for theJobQueue (#1705)

  • Job.next_t now gives the datetime of the jobs next execution (#1685)

Minor changes, CI improvements, doc fixes or bug fixes:

  • Stabalize CI (#1919,#1931)

  • Use ABCs@abstractmethod instead of raisingNotImplementedError forHandler,BasePersistence andBaseFilter (#1905)

  • Doc fixes (#1914,#1902,#1910)

Version 12.6.1

Released 2020-04-11

Bug fixes:

  • Fix serialization ofreply_markup in media messages (#1889)

Version 12.6

Released 2020-04-10

Major Changes:

  • Bot API 4.7 support.Note: InBot.create_new_sticker_set andBot.add_sticker_to_set, the order of the parameters had be changed, as thepng_sticker parameter is now optional. (#1858)

Minor changes, CI improvements or bug fixes:

  • Add tests forswtich_inline_query(_current_chat) with empty string (#1635)

  • Doc fixes (#1854,#1874,#1884)

  • Update issue templates (#1880)

  • Favor concrete types over “Iterable” (#1882)

  • Pass last validCallbackContext toTIMEOUT handlers ofConversationHandler (#1826)

  • Tweak handling of persistence and update persistence after job calls (#1827)

  • Usecheckout@v2 for GitHub actions (#1887)

Version 12.5.1

Released 2020-03-30

Minor changes, doc fixes or bug fixes:

  • Add missing docs forPollHandler andPollAnswerHandler (#1853)

  • Fix wording inFilters docs (#1855)

  • Reorder tests to make them more stable (#1835)

  • MakeConversationHandler attributes immutable (#1756)

  • MakePrefixHandler attributescommand andprefix editable (#1636)

  • Fix UTC as defaulttzinfo forJob (#1696)

Version 12.5

Released 2020-03-29

New Features:

  • Bot.link gives thet.me link of the bot (#1770)

Major Changes:

Minor changes, CI improvements or bug fixes:

  • Remove legacy CI files (#1783,#1791)

  • Update pre-commit config file (#1787)

  • Remove builtin names (#1792)

  • CI improvements (#1808,#1848)

  • Support Python 3.8 (#1614,#1824)

  • Use stale bot for auto closing stale issues (#1820,#1829,#1840)

  • Doc fixes (#1778,#1818)

  • Fix typo inedit_message_media (#1779)

  • In examples, answer CallbackQueries and useedit_message_text shortcut (#1721)

  • Revert accidental change in vendored urllib3 (#1775)

Version 12.4.2

Released 2020-02-10

Bug Fixes

  • Pass correct parse_mode to InlineResults if bot.defaults is None (#1763)

  • Make sure PP can read files that dont have bot_data (#1760)

Version 12.4.1

Released 2020-02-08

This is a quick release for#1744 which was accidently left out of v12.4.0 though mentioned in therelease notes.

Version 12.4.0

Released 2020-02-08

New features:

  • Set default values for arguments appearing repeatedly. We also have awiki page for the new defaults. (#1490)

  • Store data inCallbackContext.bot_data to access it in every callback. Also persists. (#1325)

  • Filters.poll allows only messages containing a poll (#1673)

Major changes:

  • Filters.text now accepts messages that start with a slash, becauseCommandHandler checks forMessageEntity.BOT_COMMAND since v12. This might lead to your MessageHandlers receiving more updates than before (#1680).

  • Filters.command new checks forMessageEntity.BOT_COMMAND instead of just a leading slash. Also byFilters.command(False) you can now filters for messages containing a commandanywhere in the text (#1744).

Minor changes, CI improvements or bug fixes:

  • Adddisptacher argument toUpdater to allow passing a customizedDispatcher (#1484)

  • Add missing names forFilters (#1632)

  • Documentation fixes (#1624,#1647,#1669,#1703,#1718,#1734,#1740,#1642,#1739,#1746)

  • CI improvements (#1716,#1731,#1738,#1748,#1749,#1750,#1752)

  • Fix spelling issue forencode_conversations_to_json (#1661)

  • Remove double assignement ofDispatcher.job_queue (#1698)

  • Expose dispatcher as property forCallbackContext (#1684)

  • FixNone check inJobQueue._put() (#1707)

  • Log datetimes correctly inJobQueue (#1714)

  • Fix falseMessage.link creation for private groups (#1741)

  • Add option--with-upstream-urllib3 tosetup.py to allow using non-vendored version (#1725)

  • Fix persistence for nestedConversationHandlers (#1679)

  • Improve handling of non-decodable server responses (#1623)

  • Fix download for files withoutfile_path (#1591)

  • test_webhook_invalid_posts is now considered flaky and retried on failure (#1758)

Version 12.3.0

Released 2020-01-11

New features:

  • Filters.caption allows only messages with caption (#1631).

  • Filter for exact messages/captions with new capability ofFilters.text andFilters.caption. Especially useful in combination with ReplyKeyboardMarkup. (#1631).

Major changes:

  • Fix inconsistent handling of naive datetimes (#1506).

Minor changes, CI improvements or bug fixes:

Version 12.2.0

Released 2019-10-14

New features:

  • Nested ConversationHandlers (#1512).

Minor changes, CI improvments or bug fixes:

  • Fix CI failures due to non-backward compat attrs depndency (#1540).

  • travis.yaml: TEST_OFFICIAL removed from allowed_failures.

  • Fix typos in examples (#1537).

  • Fix Bot.to_dict to use proper first_name (#1525).

  • Refactortest_commandhandler.py (#1408).

  • Add Python 3.8 (RC version) to Travis testing matrix (#1543).

  • test_bot.py: Add to_dict test (#1544).

  • Flake config moved into setup.cfg (#1546).

Version 12.1.1

Released 2019-09-18

Hot fix release

Fixed regression in the vendored urllib3 (#1517).

Version 12.1.0

Released 2019-09-13

Major changes:

  • Bot API 4.4 support (#1464,#1510)

  • Addget_file method toAnimation &ChatPhoto. Add,get_small_file &get_big_filemethods toChatPhoto (#1489)

  • Tools for deep linking (#1049)

Minor changes and/or bug fixes:

Version 12.0.0

Released 2019-08-29

Well… This felt like decades. But here we are with a new release.

Expect minor releases soon (mainly complete Bot API 4.4 support)

Major and/or breaking changes:

  • Context based callbacks

  • Persistence

  • PrefixHandler added (Handler overhaul)

  • Deprecation of RegexHandler and edited_messages, channel_post, etc. arguments (Filter overhaul)

  • Various ConversationHandler changes and fixes

  • Bot API 4.1, 4.2, 4.3 support

  • Python 3.4 is no longer supported

  • Error Handler now handles all types of exceptions (#1485)

  • Return UTC from from_timestamp() (#1485)

See the wiki page at https://github.com/python-telegram-bot/python-telegram-bot/wiki/Transition-guide-to-Version-12.0 for a detailed guide on how to migrate from version 11 to version 12.

Context based callbacks (#1100)

  • Use ofpass_ in handlers is deprecated.

  • Instead useuse_context=True onUpdater orDispatcher and change callback from (bot, update, others…) to (update, context).

  • This also applies to error handlersDispatcher.add_error_handler and JobQueue jobs (change (bot, job) to (context) here).

  • For users with custom handlers subclassing Handler, this is mostly backwards compatible, but to use the new context based callbacks you need to implement the new collect_additional_context method.

  • Passing bot toJobQueue.__init__ is deprecated. Use JobQueue.set_dispatcher with a dispatcher instead.

  • Dispatcher makes sure to use a singleCallbackContext for a entire update. This means that if an update is handled by multiple handlers (by using the group argument), you can add custom arguments to theCallbackContext in a lower group handler and use it in higher group handler. NOTE: Never use with @run_async, see docs for more info. (#1283)

  • If you have custom handlers they will need to be updated to support the changes in this release.

  • Update all examples to use context based callbacks.

Persistence (#1017)

  • Added PicklePersistence and DictPersistence for adding persistence to your bots.

  • BasePersistence can be subclassed for all your persistence needs.

  • Add a new example that shows a persistent ConversationHandler bot

Handler overhaul (#1114)

  • CommandHandler now only triggers on actual commands as defined by telegram servers (everything that the clients mark as a tabable link).

  • PrefixHandler can be used if you need to trigger on prefixes (like all messages starting with a “/” (old CommandHandler behaviour) or even custom prefixes like “#” or “!”).

Filter overhaul (#1221)

  • RegexHandler is deprecated and should be replaced with a MessageHandler with a regex filter.

  • Use update filters to filter update types instead of arguments (message_updates, channel_post_updates and edited_updates) on the handlers.

  • Completely remove allow_edited argument - it has been deprecated for a while.

  • data_filters now exist which allows filters that return data into the callback function. This is how the regex filter is implemented.

  • All this means that it no longer possible to use a list of filters in a handler. Use bitwise operators instead!

ConversationHandler

  • Removerun_async_timeout andtimed_out_behavior arguments (#1344)

  • Replace withWAITING constant and behavior from states (#1344)

  • Only emit one warning for multiple CallbackQueryHandlers in a ConversationHandler (#1319)

  • Use warnings.warn for ConversationHandler warnings (#1343)

  • Fix unresolvable promises (#1270)

Bug fixes & improvements

  • Handlers should be faster due to deduped logic.

  • Avoid compiling compiled regex in regex filter. (#1314)

  • Add missingleft_chat_member to Message.MESSAGE_TYPES (#1336)

  • Make custom timeouts actually work properly (#1330)

  • Add convenience classmethods (from_button, from_row and from_column) to InlineKeyboardMarkup

  • Small typo fix in setup.py (#1306)

  • Add Conflict error (HTTP error code 409) (#1154)

  • Change MAX_CAPTION_LENGTH to 1024 (#1262)

  • Remove some unnecessary clauses (#1247,#1239)

  • Allow filenames without dots in them when sending files (#1228)

  • Fix uploading files with unicode filenames (#1214)

  • Replace http.server with Tornado (#1191)

  • Allow SOCKSConnection to parse username and password from URL (#1211)

  • Fix for arguments in passport/data.py (#1213)

  • Improve message entity parsing by adding text_mention (#1206)

  • Documentation fixes (#1348,#1397,#1436)

  • Merged filters short-circuit (#1350)

  • Fix webhook listen with tornado (#1383)

  • Call task_done() on update queue after update processing finished (#1428)

  • Fix send_location() - latitude may be 0 (#1437)

  • Make MessageEntity objects comparable (#1465)

  • Add prefix to thread names (#1358)

Buf fixes since v12.0.0b1

  • Fix setting bot on ShippingQuery (#1355)

  • Fix _trigger_timeout() missing 1 required positional argument: ‘job’ (#1367)

  • Add missing message.text check in PrefixHandler check_update (#1375)

  • Make updates persist even on DispatcherHandlerStop (#1463)

  • Dispatcher force updating persistence object’s chat data attribute(#1462)

Internal improvements

  • Finally fix our CI builds mostly (too many commits and PRs to list)

  • Use multiple bots for CI to improve testing times significantly.

  • Allow pypy to fail in CI.

  • Remove the last CamelCase CheckUpdate methods from the handlers we missed earlier.

  • test_official is now executed in a different job

Version 11.1.0

Released 2018-09-01

Fixes and updates for Telegram Passport: (#1198)

  • Fix passport decryption failing at random times

  • Added support for middle names.

  • Added support for translations for documents

  • Add errors for translations for documents

  • Added support for requesting names in the language of the user’s country of residence

  • Replaced the payload parameter with the new parameter nonce

  • Add hash to EncryptedPassportElement

Version 11.0.0

Released 2018-08-29

Fully support Bot API version 4.0!(also some bugfixes :))

Telegram Passport (#1174):

  • Add full support for telegram passport.
    • New types: PassportData, PassportFile, EncryptedPassportElement, EncryptedCredentials, PassportElementError, PassportElementErrorDataField, PassportElementErrorFrontSide, PassportElementErrorReverseSide, PassportElementErrorSelfie, PassportElementErrorFile and PassportElementErrorFiles.

    • New bot method: set_passport_data_errors

    • New filter: Filters.passport_data

    • Field passport_data field on Message

    • PassportData can be easily decrypted.

    • PassportFiles are automatically decrypted if originating from decrypted PassportData.

  • See new passportbot.py example for details on how to use, or go toour telegram passport wiki page for more info

  • NOTE: Passport decryption requires new dependencycryptography.

Inputfile rework (#1184):

  • Change how Inputfile is handled internally

  • This allows support for specifying the thumbnails of photos and videos using the thumb= argument in the different send_ methods.

  • Also allows Bot.send_media_group to actually finally send more than one media.

  • Add thumb to Audio, Video and Videonote

  • Add Bot.edit_message_media together with InputMediaAnimation, InputMediaAudio, and inputMediaDocument.

Other Bot API 4.0 changes:

  • Add forusquare_type to Venue, InlineQueryResultVenue, InputVenueMessageContent, and Bot.send_venue. (#1170)

  • Add vCard support by adding vcard field to Contact, InlineQueryResultContact, InputContactMessageContent, and Bot.send_contact. (#1166)

  • Support new message entities: CASHTAG and PHONE_NUMBER. (#1179)
    • Cashtag seems to be things like$USD and$GBP, but it seems telegram doesn’t currently send them to bots.

    • Phone number also seems to have limited support for now

  • Add Bot.send_animation, add width, height, and duration to Animation, and add Filters.animation. (#1172)

Non Bot API 4.0 changes:

  • Minor integer comparison fix (#1147)

  • Fix Filters.regex failing on non-text message (#1158)

  • Fix ProcessLookupError if process finishes before we kill it (#1126)

  • Add t.me links for User, Chat and Message if available and update User.mention_* (#1092)

  • Fix mention_markdown/html on py2 (#1112)

Version 10.1.0

Released 2018-05-02

Fixes changing previous behaviour:

  • Add urllib3 fix for socks5h support (#1085)

  • Fix send_sticker() timeout=20 (#1088)

Fixes:

  • Add a caption_entity filter for filtering caption entities (#1068)

  • Inputfile encode filenames (#1086)

  • InputFile: Fix proper naming of file when reading from subprocess.PIPE (#1079)

  • Remove pytest-catchlog from requirements (#1099)

  • Documentation fixes (#1061,#1078,#1081,#1096)

Version 10.0.2

Released 2018-04-17

Important fix:

  • Handle utf8 decoding errors (#1076)

New features:

  • Added Filter.regex (#1028)

  • Filters for Category and file types (#1046)

  • Added video note filter (#1067)

Fixes:

  • Fix in telegram.Message (#1042)

  • Make chat_id a positional argument inside shortcut methods of Chat and User classes (#1050)

  • Make Bot.full_name return a unicode object. (#1063)

  • CommandHandler faster check (#1074)

  • Correct documentation of Dispatcher.add_handler (#1071)

  • Various small fixes to documentation.

Version 10.0.1

Released 2018-03-05

Fixes:

  • Fix conversationhandler timeout (PR#1032)

  • Add missing docs utils (PR#912)

Version 10.0.0

Released 2018-03-02

Non backward compatabile changes and changed defaults

  • JobQueue: Remove deprecated prevent_autostart & put() (PR#1012)

  • Bot, Updater: Remove deprecated network_delay (PR#1012)

  • Remove deprecated Message.new_chat_member (PR#1012)

  • Retry bootstrap phase indefinitely (by default) on network errors (PR#1018)

New Features

  • Support v3.6 API (PR#1006)

  • User.full_name convinience property (PR#949)

  • Addsend_phone_number_to_provider andsend_email_to_provider arguments to send_invoice (PR#986)

  • Bot: Add shortcut methods reply_{markdown,html} (PR#827)

  • Bot: Add shortcut method reply_media_group (PR#994)

  • Added utils.helpers.effective_message_type (PR#826)

  • Bot.get_file now allows passing a file in addition to file_id (PR#963)

  • Add .get_file() to Audio, Document, PhotoSize, Sticker, Video, VideoNote and Voice (PR#963)

  • Add .send_*() methods to User and Chat (PR#963)

  • Get jobs by name (PR#1011)

  • Add Message caption html/markdown methods (PR#1013)

  • File.download_as_bytearray - new method to get a d/led file as bytearray (PR#1019)

  • File.download(): Now returns a meaningful return value (PR#1019)

  • Added conversation timeout in ConversationHandler (PR#895)

Changes

  • Store bot in PreCheckoutQuery (PR#953)

  • Updater: Issue INFO log upon received signal (PR#951)

  • JobQueue: Thread safety fixes (PR#977)

  • WebhookHandler: Fix exception thrown during error handling (PR#985)

  • Explicitly check update.effective_chat in ConversationHandler.check_update (PR#959)

  • Updater: Better handling of timeouts during get_updates (PR#1007)

  • Remove unnecessary to_dict() (PR#834)

  • CommandHandler - ignore strings in entities and “/” followed by whitespace (PR#1020)

  • Documentation & style fixes (PR#942, PR#956, PR#962, PR#980, PR#983)

Version 9.0.0

Released 2017-12-08

Breaking changes (possibly)

  • Drop support for python 3.3 (PR#930)

New Features

  • Support Bot API 3.5 (PR#920)

Changes

  • Fix race condition in dispatcher start/stop (#887)

  • Log error trace if there is no error handler registered (#694)

  • Update examples with consistent string formatting (#870)

  • Various changes and improvements to the docs.

Version 8.1.1

Released 2017-10-15

  • Fix Commandhandler crashing on single character messages (PR#873).

Version 8.1.0

Released 2017-10-14

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

Changes- MessageHandler & 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 improvements.- Documentation fixes.

Version 8.0.0

Released 2017-09-01

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 handlerfor errors that happen during polling (PR#810).

  • For testing we switched to pytest (PR#788).

  • Lots of small improvements to our tests and documentation.

Version 7.0.1

Released 2017-07-28

  • Fix TypeError exception in RegexHandler (PR #751).

  • Small documentation fix (PR #749).

Version 7.0.0

Released 2017-07-25

  • 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 forMessage text properties (PR #689).

  • Fixed args dispatching inMessageQueue’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 deprecatedtelegram.Emoji.

  • Removed deprecatedBotan import fromutils (Botan is still available throughcontrib).

  • Removed deprecatedReplyKeyboardHide.

  • Removed deprecatededit_message argument ofbot.set_game_score.

  • Internal restructure of files.

  • Improved documentation.

  • Improved unitests.

Pre-version 7.0

2017-06-18

Released 6.1.0

  • Fully support Bot API 3.0

  • Add more fine-grained filters for status updates

  • Bug fixes and other improvements

2017-05-29

Released 6.0.3

  • Faulty PyPI release

2017-05-29

Released 6.0.2

  • Avoid confusion with user’surllib3 by renaming vendoredurllib3 toptb_urllib3

2017-05-19

Released 6.0.1

  • Add support forUser.language_code

  • FixMessage.text_html andMessage.text_markdown for messages with emoji

2017-05-19

Released 6.0.0

  • Add support for Bot API 2.3.1

  • Add support fordeleteMessage API method

  • New, simpler API forJobQueue -#484

  • Download files into file-like objects -#459

  • Use vendorurllib3 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 nowNone by default, instead of empty strings

  • Addtext_markdown andtext_html properties toMessage -#507

  • Add support for Socks5 proxy -#518

  • Add support for filters inCommandHandler -#536

  • Add the ability to invert (not) filters -#552

  • AddFilters.group andFilters.private

  • Compatibility with GAE viaurllib3.contrib package -#583

  • Add equality rich comparision operators to telegram objects -#604

  • Several bugfixes and other improvements

  • Remove some deprecated code

2017-04-17

Released 5.3.1

  • Hotfix release due to bug introduced by urllib3 version 1.21

2016-12-11

Released 5.3

  • Implement API changes of November 21st (Bot API 2.3)

  • JobQueue now supportsdatetime.timedelta in addition to seconds

  • JobQueue now supports running jobs only on certain days

  • NewFilters.reply filter

  • Bugfix forMessage.edit_reply_markup

  • Other bugfixes

2016-10-25

Released 5.2

  • Implement API changes of October 3rd (games update)

  • AddMessage.edit_* methods

  • Filters for theMessageHandler can now be combined using bitwise operators (&and|)

  • Add a way to save user- and chat-related data temporarily

  • Other bugfixes and improvements

2016-09-24

Released 5.1

  • Drop Python 2.6 support

  • Deprecatetelegram.Emoji

  • Useujson if available

  • Add instance methods toMessage,Chat,User,InlineQuery andCallbackQuery

  • RegEx filtering forCallbackQueryHandler andInlineQueryHandler

  • NewMessageHandler filters:forwarded andentity

  • AddMessage.get_entity to correctly handle UTF-16 codepoints andMessageEntity offsets

  • Fix bug inConversationHandler when first handler ends the conversation

  • Allow multipleDispatcher instances

  • AddChatMigrated Exception

  • Properly split and handle arguments inCommandHandler

2016-07-15

Released 5.0

  • ReworkJobQueue

  • IntroduceConversationHandler

  • Introducetelegram.constants -#342

2016-07-12

Released 4.3.4

  • Fix proxy support withurllib3 when proxy requires auth

2016-07-08

Released 4.3.3

  • Fix proxy support withurllib3

2016-07-04

Released 4.3.2

  • Fix: Usetimeout parameter in all API methods

2016-06-29

Released 4.3.1

  • Update wrong requirement:urllib3>=1.10

2016-06-28

Released 4.3

  • Useurllib3.PoolManager for connection re-use

  • Rewriterun_async decorator to re-use threads

  • New requirements:urllib3 andcertifi

2016-06-10

Released 4.2.1

  • FixCallbackQuery.to_dict() bug (thanks to @jlmadurga)

  • FixeditMessageText exception when receiving aCallbackQuery

2016-05-28

Released 4.2

  • Implement Bot API 2.1

  • Movebotan module totelegram.contrib

  • New exception type:BadRequest

2016-05-22

Released 4.1.2

  • FixMessageEntity decoding with Bot API 2.1 changes

2016-05-16

Released 4.1.1

  • Fix deprecation warning inDispatcher

2016-05-15

Released 4.1

  • Implement API changes from May 6, 2016

  • Fix bug whenstart_polling withclean=True

  • Methods now have snake_case equivalent, for exampletelegram.Bot.send_message is the same astelegram.Bot.sendMessage

2016-05-01

Released 4.0.3

  • Add missing attributelocation toInlineQuery

2016-04-29

Released 4.0.2

  • Bugfixes

  • KeyboardReplyMarkup now acceptsstr again

2016-04-27

Released 4.0.1

  • Implement Bot API 2.0

  • Almost complete recode ofDispatcher

  • Please read theTransition Guide to 4.0

  • Changes from 4.0rc1
    • The syntax of filters forMessageHandler (upper/lower cases)

    • Handler groups are now identified byint only, and ordered

  • Note: v4.0 has been skipped due to a PyPI accident

2016-04-22

Released 4.0rc1

2016-03-22

Released 3.4

  • MoveUpdater,Dispatcher andJobQueue to newtelegram.ext submodule (thanks to @rahiel)

  • Adddisable_notification parameter (thanks to @aidarbiktimirov)

  • Fix bug where commands sent by Telegram Web would not be recognized (thanks to @shelomentsevd)

  • Add option to skip old updates on bot startup

  • Send files fromBufferedReader

2016-02-28

Released 3.3

  • Inline bots

  • Send any file by URL

  • Specialized exceptions:Unauthorized,InvalidToken,NetworkError andTimedOut

  • Integration for botan.io (thanks to @ollmer)

  • HTML Parsemode (thanks to @jlmadurga)

  • Bugfixes and under-the-hood improvements

Very special thanks to Noam Meltzer (@tsnoam) for all of his work!

2016-01-09

Released 3.3b1

  • Implement inline bots (beta)

2016-01-05

Released 3.2.0

  • IntroducingJobQueue (original author: @franciscod)

  • Streamlining all exceptions toTelegramError (Special thanks to @tsnoam)

  • Proper locking ofUpdater andDispatcherstart andstop methods

  • Small bugfixes

2015-12-29

Released 3.1.2

  • Fix custom path for file downloads

  • Don’t stop the dispatcher thread on uncaught errors in handlers

2015-12-21

Released 3.1.1

  • Fix a bug where asynchronous handlers could not have additional arguments

  • Addgroups andgroupdict as additional arguments for regex-based handlers

2015-12-16

Released 3.1.0

  • Thechat-field inMessage is now of typeChat. (API update Oct 8 2015)

  • Message now contains the optional fieldssupergroup_chat_created,migrate_to_chat_id,migrate_from_chat_id andchannel_chat_created. (API update Nov 2015)

2015-12-08

Released 3.0.0

  • Introducing theUpdater andDispatcher classes

2015-11-11

Released 2.9.2

  • Error handling on request timeouts has been improved

2015-11-10

Released 2.9.1

  • Add parameternetwork_delay to Bot.getUpdates for slow connections

2015-11-10

Released 2.9

  • Emoji class now usesbytes_to_native_str fromfuture 3rd party lib

  • Makeuser_from optional to work with channels

  • Raise exception if Telegram times out on long-polling

Special thanks to @jh0ker for all hard work

2015-10-08

Released 2.8.7

  • Type as optional forGroupChat class

2015-10-08

Released 2.8.6

  • Adds type toUser andGroupChat classes (pre-release Telegram feature)

2015-09-24

Released 2.8.5

  • Handles HTTP Bad Gateway (503) errors on request

  • Fixes regression onAudio andDocument for unicode fields

2015-09-20

Released 2.8.4

  • getFile andFile.download is now fully supported

2015-09-10

Released 2.8.3

  • MovedBot._requestURL to its own class (telegram.utils.request)

  • Much better, such wow, Telegram Objects tests

  • Add consistency forstr properties on Telegram Objects

  • Better design to test ifchat_id is invalid

  • Add ability to set custom filename onBot.sendDocument(..,filename='')

  • Fix Sticker asInputFile

  • Send JSON requests over urlencoded post data

  • Markdown support forBot.sendMessage(...,parse_mode=ParseMode.MARKDOWN)

  • Refactor ofTelegramError class (no more handlingIOError orURLError)

2015-09-05

Released 2.8.2

  • Fix regression on Telegram ReplyMarkup

  • Add certificate tois_inputfile method

2015-09-05

Released 2.8.1

  • Fix regression on Telegram objects with thumb properties

2015-09-04

Released 2.8

  • TelegramError whenchat_id is empty for send* methods

  • setWebhook now supports sending self-signed certificate

  • Huge redesign of existing Telegram classes

  • Added support for PyPy

  • Added docstring for existing classes

2015-08-19

Released 2.7.1

  • Fixed JSON serialization formessage

2015-08-17

Released 2.7

  • Added support forVoice object andsendVoice method

  • Due backward compatibility performer or/and title will be required forsendAudio

  • Fixed JSON serialization when forwarded message

2015-08-15

Released 2.6.1

  • Fixed parsing image header issue on < Python 2.7.3

2015-08-14

Released 2.6.0

  • Depreciation ofrequire_authentication andclearCredentials methods

  • GivingAUTHORS the proper credits for their contribution for this project

  • Message.date andMessage.forward_date are nowdatetime objects

2015-08-12

Released 2.5.3

  • telegram.Bot now supports to be unpickled

2015-08-11

Released 2.5.2

  • New changes from Telegram Bot API have been applied

  • telegram.Bot now supports to be pickled

  • Return emptystr insteadNone whenmessage.text is empty

2015-08-10

Released 2.5.1

  • Moved from GPLv2 to LGPLv3

2015-08-09

Released 2.5

  • Fixes logging calls in API

2015-08-08

Released 2.4

  • FixesEmoji class for Python 3

  • PEP8 improvements

2015-08-08

Released 2.3

  • FixesForceReply class

  • Removelogging.basicConfig from library

2015-07-25

Released 2.2

  • Allowsdebug=True when initializingtelegram.Bot

2015-07-20

Released 2.1

  • Fixto_dict forDocument andVideo

2015-07-19

Released 2.0

  • Fixes bugs

  • Improves__str__ overto_json()

  • Creates abstract classTelegramObject

2015-07-15

Released 1.9

  • Python 3 officially supported

  • PEP8 improvements

2015-07-12

Released 1.8

  • Fixes crash when replying an unicode text message (special thanks to JRoot3D)

2015-07-11

Released 1.7

  • Fixes crash whenusername is not defined onchat (special thanks to JRoot3D)

2015-07-10

Released 1.6

  • Improvements for GAE support

2015-07-10

Released 1.5

  • Fixes randomly unicode issues when usingInputFile

2015-07-10

Released 1.4

  • requests lib is no longer required

  • Google App Engine (GAE) is supported

2015-07-10

Released 1.3

  • Added support tosetWebhook (special thanks to macrojames)

2015-07-09

Released 1.2

  • CustomKeyboard classes now available

  • Emojis available

  • PEP8 improvements

2015-07-08

Released 1.1

  • PyPi package now available

2015-07-08

Released 1.0

  • Initial checkin of python-telegram-bot

On this page

[8]ページ先頭

©2009-2025 Movatter.jp