From a4a3f42c7122dcd320c061b9407605e39a39f019 Mon Sep 17 00:00:00 2001 From: JRoot Junior Date: Fri, 2 Jan 2026 02:55:00 +0200 Subject: [PATCH] Bump version --- .apiversion | 2 +- CHANGES.rst | 90 ++++++++++++++++++++++++++++++++++++++++ CHANGES/1740.bugfix.rst | 1 - CHANGES/1741.bugfix.rst | 3 -- CHANGES/1747.feature.rst | 42 ------------------- CHANGES/1748.misc.rst | 21 ---------- CHANGES/1749.misc.rst | 1 - README.rst | 2 +- aiogram/__meta__.py | 4 +- 9 files changed, 94 insertions(+), 72 deletions(-) delete mode 100644 CHANGES/1740.bugfix.rst delete mode 100644 CHANGES/1741.bugfix.rst delete mode 100644 CHANGES/1747.feature.rst delete mode 100644 CHANGES/1748.misc.rst delete mode 100644 CHANGES/1749.misc.rst diff --git a/.apiversion b/.apiversion index 1a2c3557..c3cae12b 100644 --- a/.apiversion +++ b/.apiversion @@ -1 +1 @@ -9.2 +9.3 diff --git a/CHANGES.rst b/CHANGES.rst index 3e28c02f..4369caa7 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -16,6 +16,96 @@ Changelog .. towncrier release notes start +3.24.0 (2026-01-02) +==================== + +Features +-------- + +- Added full support for Telegram Bot API 9.3 + + **Topics in Private Chats** + + Bot API 9.3 introduces forum topics functionality for private chats: + + - Added new ``sendMessageDraft`` method for streaming partial messages while being generated (requires forum topic mode enabled) + - Added ``has_topics_enabled`` field to the ``User`` class to determine if forum topic mode is enabled in private chats + - Added ``message_thread_id`` and ``is_topic_message`` fields to the ``Message`` class for private chat topic support + - Added ``message_thread_id`` parameter support to messaging methods: ``sendMessage``, ``sendPhoto``, ``sendVideo``, ``sendAnimation``, ``sendAudio``, ``sendDocument``, ``sendPaidMedia``, ``sendSticker``, ``sendVideoNote``, ``sendVoice``, ``sendLocation``, ``sendVenue``, ``sendContact``, ``sendPoll``, ``sendDice``, ``sendInvoice``, ``sendGame``, ``sendMediaGroup``, ``copyMessage``, ``copyMessages``, ``forwardMessage``, ``forwardMessages`` + - Updated ``sendChatAction`` to support ``message_thread_id`` parameter in private chats + - Updated ``editForumTopic``, ``deleteForumTopic``, ``unpinAllForumTopicMessages`` methods to manage private chat topics + - Added ``is_name_implicit`` field to ``ForumTopic`` class + + **Gifts System Enhancements** + + Enhanced gifts functionality with new methods and extended capabilities: + + - Added ``getUserGifts`` method to retrieve gifts owned and hosted by a user + - Added ``getChatGifts`` method to retrieve gifts owned by a chat + - Updated ``UniqueGiftInfo`` class: replaced ``last_resale_star_count`` with ``last_resale_currency`` and ``last_resale_amount`` fields, added "gifted_upgrade" and "offer" as origin values + - Updated ``getBusinessAccountGifts`` method: replaced ``exclude_limited`` parameter with ``exclude_limited_upgradable`` and ``exclude_limited_non_upgradable``, added ``exclude_from_blockchain`` parameter + - Added new fields to ``Gift`` class: ``personal_total_count``, ``personal_remaining_count``, ``is_premium``, ``has_colors``, ``unique_gift_variant_count``, ``gift_background`` + - Added new fields to ``UniqueGift`` class: ``gift_id``, ``is_from_blockchain``, ``is_premium``, ``colors`` + - Added new fields to gift info classes: ``is_upgrade_separate``, ``unique_gift_number`` + - Added ``gift_upgrade_sent`` field to the ``Message`` class + - Added ``gifts_from_channels`` field to the ``AcceptedGiftTypes`` class + - Added new ``UniqueGiftColors`` class for color schemes in user names and link previews + - Added new ``GiftBackground`` class for gift background styling + + **Business Accounts & Stories** + + - Added ``repostStory`` method to enable reposting stories across managed business accounts + + **Miscellaneous Updates** + + - Bots can now disable main usernames and set ``can_restrict_members`` rights in channels + - Maximum paid media price increased to 25000 Telegram Stars + - Added new ``UserRating`` class + - Added ``rating``, ``paid_message_star_count``, ``unique_gift_colors`` fields to the ``ChatFullInfo`` class + - Added support for ``message_effect_id`` parameter in forward/copy operations + - Added ``completed_by_chat`` field to the ``ChecklistTask`` class + `#1747 `_ + + +Bugfixes +-------- + +- Fixed I18n initialization with relative path + `#1740 `_ +- Fixed dependency injection for arguments that have "ForwardRef" annotations in Py3.14+ + since `inspect.getfullargspec(callback)` can't process callback if it's arguments have "ForwardRef" annotations + `#1741 `_ + + +Misc +---- + +- Migrated from ``hatch`` to ``uv`` for dependency management and development workflows. + + This change improves developer experience with significantly faster dependency resolution (10-100x faster than pip), automatic virtual environment management, and reproducible builds through lockfile support. + + **What changed for contributors:** + + - Install dependencies with ``uv sync --all-extras --group dev --group test`` instead of ``pip install -e .[dev,test,docs]`` + - Run commands with ``uv run`` prefix (e.g., ``uv run pytest``, ``uv run black``) + - All Makefile commands now use ``uv`` internally (``make install``, ``make test``, ``make lint``, etc.) + - Version bumping now uses a custom ``scripts/bump_version.py`` script instead of ``hatch version`` + + **What stayed the same:** + + - Build backend remains ``hatchling`` (no changes to package building) + - Dynamic version reading from ``aiogram/__meta__.py`` still works + - All GitHub Actions CI/CD workflows updated to use ``uv`` + - ReadTheDocs builds continue to work without changes + - Development dependencies (``dev``, ``test``) moved to ``[dependency-groups]`` section + - Documentation dependencies (``docs``) remain in ``[project.optional-dependencies]`` for compatibility + + Contributors can use either the traditional ``pip``/``venv`` workflow or the new ``uv`` workflow - both are documented in the contributing guide. + `#1748 `_ +- Updated type hints in the codebase to Python 3.10+ style unions and optionals. + `#1749 `_ + + 3.23.0 (2025-12-07) ==================== diff --git a/CHANGES/1740.bugfix.rst b/CHANGES/1740.bugfix.rst deleted file mode 100644 index e2b38536..00000000 --- a/CHANGES/1740.bugfix.rst +++ /dev/null @@ -1 +0,0 @@ -Fix I18n initialization with relative path diff --git a/CHANGES/1741.bugfix.rst b/CHANGES/1741.bugfix.rst deleted file mode 100644 index 5ca46ee5..00000000 --- a/CHANGES/1741.bugfix.rst +++ /dev/null @@ -1,3 +0,0 @@ -`inspect.getfullargspec(callback)` can't process callback if it's arguments have "ForwardRef" annotations in Py3.14+ - -This PR replaces the old way with `inspect.signature(callback)` and add `annotation_format = annotationlib.Format.FORWARDREF` argument to it if runtime python version >=3.14. diff --git a/CHANGES/1747.feature.rst b/CHANGES/1747.feature.rst deleted file mode 100644 index 999d08a1..00000000 --- a/CHANGES/1747.feature.rst +++ /dev/null @@ -1,42 +0,0 @@ -Added full support for Telegram Bot API 9.3 - -**Topics in Private Chats** - -Bot API 9.3 introduces forum topics functionality for private chats: - -- Added new ``sendMessageDraft`` method for streaming partial messages while being generated (requires forum topic mode enabled) -- Added ``has_topics_enabled`` field to the ``User`` class to determine if forum topic mode is enabled in private chats -- Added ``message_thread_id`` and ``is_topic_message`` fields to the ``Message`` class for private chat topic support -- Added ``message_thread_id`` parameter support to messaging methods: ``sendMessage``, ``sendPhoto``, ``sendVideo``, ``sendAnimation``, ``sendAudio``, ``sendDocument``, ``sendPaidMedia``, ``sendSticker``, ``sendVideoNote``, ``sendVoice``, ``sendLocation``, ``sendVenue``, ``sendContact``, ``sendPoll``, ``sendDice``, ``sendInvoice``, ``sendGame``, ``sendMediaGroup``, ``copyMessage``, ``copyMessages``, ``forwardMessage``, ``forwardMessages`` -- Updated ``sendChatAction`` to support ``message_thread_id`` parameter in private chats -- Updated ``editForumTopic``, ``deleteForumTopic``, ``unpinAllForumTopicMessages`` methods to manage private chat topics -- Added ``is_name_implicit`` field to ``ForumTopic`` class - -**Gifts System Enhancements** - -Enhanced gifts functionality with new methods and extended capabilities: - -- Added ``getUserGifts`` method to retrieve gifts owned and hosted by a user -- Added ``getChatGifts`` method to retrieve gifts owned by a chat -- Updated ``UniqueGiftInfo`` class: replaced ``last_resale_star_count`` with ``last_resale_currency`` and ``last_resale_amount`` fields, added "gifted_upgrade" and "offer" as origin values -- Updated ``getBusinessAccountGifts`` method: replaced ``exclude_limited`` parameter with ``exclude_limited_upgradable`` and ``exclude_limited_non_upgradable``, added ``exclude_from_blockchain`` parameter -- Added new fields to ``Gift`` class: ``personal_total_count``, ``personal_remaining_count``, ``is_premium``, ``has_colors``, ``unique_gift_variant_count``, ``gift_background`` -- Added new fields to ``UniqueGift`` class: ``gift_id``, ``is_from_blockchain``, ``is_premium``, ``colors`` -- Added new fields to gift info classes: ``is_upgrade_separate``, ``unique_gift_number`` -- Added ``gift_upgrade_sent`` field to the ``Message`` class -- Added ``gifts_from_channels`` field to the ``AcceptedGiftTypes`` class -- Added new ``UniqueGiftColors`` class for color schemes in user names and link previews -- Added new ``GiftBackground`` class for gift background styling - -**Business Accounts & Stories** - -- Added ``repostStory`` method to enable reposting stories across managed business accounts - -**Miscellaneous Updates** - -- Bots can now disable main usernames and set ``can_restrict_members`` rights in channels -- Maximum paid media price increased to 25000 Telegram Stars -- Added new ``UserRating`` class -- Added ``rating``, ``paid_message_star_count``, ``unique_gift_colors`` fields to the ``ChatFullInfo`` class -- Added support for ``message_effect_id`` parameter in forward/copy operations -- Added ``completed_by_chat`` field to the ``ChecklistTask`` class diff --git a/CHANGES/1748.misc.rst b/CHANGES/1748.misc.rst deleted file mode 100644 index 21cdce84..00000000 --- a/CHANGES/1748.misc.rst +++ /dev/null @@ -1,21 +0,0 @@ -Migrated from ``hatch`` to ``uv`` for dependency management and development workflows. - -This change improves developer experience with significantly faster dependency resolution (10-100x faster than pip), automatic virtual environment management, and reproducible builds through lockfile support. - -**What changed for contributors:** - -- Install dependencies with ``uv sync --all-extras --group dev --group test`` instead of ``pip install -e .[dev,test,docs]`` -- Run commands with ``uv run`` prefix (e.g., ``uv run pytest``, ``uv run black``) -- All Makefile commands now use ``uv`` internally (``make install``, ``make test``, ``make lint``, etc.) -- Version bumping now uses a custom ``scripts/bump_version.py`` script instead of ``hatch version`` - -**What stayed the same:** - -- Build backend remains ``hatchling`` (no changes to package building) -- Dynamic version reading from ``aiogram/__meta__.py`` still works -- All GitHub Actions CI/CD workflows updated to use ``uv`` -- ReadTheDocs builds continue to work without changes -- Development dependencies (``dev``, ``test``) moved to ``[dependency-groups]`` section -- Documentation dependencies (``docs``) remain in ``[project.optional-dependencies]`` for compatibility - -Contributors can use either the traditional ``pip``/``venv`` workflow or the new ``uv`` workflow - both are documented in the contributing guide. diff --git a/CHANGES/1749.misc.rst b/CHANGES/1749.misc.rst deleted file mode 100644 index 90ba26a5..00000000 --- a/CHANGES/1749.misc.rst +++ /dev/null @@ -1 +0,0 @@ -Updated type hints in the codebase to Python 3.10+ style unions and optionals. diff --git a/README.rst b/README.rst index 350a05f8..52322104 100644 --- a/README.rst +++ b/README.rst @@ -52,7 +52,7 @@ Features - Asynchronous (`asyncio docs `_, :pep:`492`) - Has type hints (:pep:`484`) and can be used with `mypy `_ - Supports `PyPy `_ -- Supports `Telegram Bot API 9.2 `_ and gets fast updates to the latest versions of the Bot API +- Supports `Telegram Bot API 9.3 `_ and gets fast updates to the latest versions of the Bot API - Telegram Bot API integration code was `autogenerated `_ and can be easily re-generated when API gets updated - Updates router (Blueprints) - Has Finite State Machine diff --git a/aiogram/__meta__.py b/aiogram/__meta__.py index cf908980..6f449426 100644 --- a/aiogram/__meta__.py +++ b/aiogram/__meta__.py @@ -1,2 +1,2 @@ -__version__ = "3.23.0" -__api_version__ = "9.2" +__version__ = "3.24.0" +__api_version__ = "9.3"