From 8b54a6b944c3458c263a4448235e335ec095ce0b Mon Sep 17 00:00:00 2001 From: Alex Root Junior Date: Sun, 2 Jul 2023 14:07:40 +0300 Subject: [PATCH] Reformat code, removed unused imports --- aiogram/dispatcher/middlewares/user_context.py | 3 +-- aiogram/methods/add_sticker_to_set.py | 2 -- aiogram/methods/answer_callback_query.py | 2 +- aiogram/methods/answer_inline_query.py | 2 +- aiogram/methods/answer_pre_checkout_query.py | 2 +- aiogram/methods/answer_shipping_query.py | 2 +- aiogram/methods/answer_web_app_query.py | 2 -- aiogram/methods/approve_chat_join_request.py | 2 +- aiogram/methods/ban_chat_member.py | 2 +- aiogram/methods/ban_chat_sender_chat.py | 2 +- aiogram/methods/base.py | 12 +----------- aiogram/methods/close.py | 2 -- aiogram/methods/close_forum_topic.py | 2 +- aiogram/methods/close_general_forum_topic.py | 2 +- aiogram/methods/copy_message.py | 2 +- aiogram/methods/create_chat_invite_link.py | 2 +- aiogram/methods/create_forum_topic.py | 2 +- aiogram/methods/create_invoice_link.py | 2 +- aiogram/methods/create_new_sticker_set.py | 2 +- aiogram/methods/decline_chat_join_request.py | 2 +- aiogram/methods/delete_chat_photo.py | 2 +- aiogram/methods/delete_chat_sticker_set.py | 2 +- aiogram/methods/delete_forum_topic.py | 2 +- aiogram/methods/delete_message.py | 2 +- aiogram/methods/delete_my_commands.py | 2 +- aiogram/methods/delete_sticker_from_set.py | 2 -- aiogram/methods/delete_sticker_set.py | 2 -- aiogram/methods/delete_webhook.py | 2 +- aiogram/methods/edit_chat_invite_link.py | 2 +- aiogram/methods/edit_forum_topic.py | 2 +- aiogram/methods/edit_general_forum_topic.py | 2 +- aiogram/methods/edit_message_caption.py | 2 +- aiogram/methods/edit_message_live_location.py | 2 +- aiogram/methods/edit_message_media.py | 2 +- aiogram/methods/edit_message_reply_markup.py | 2 +- aiogram/methods/edit_message_text.py | 2 +- aiogram/methods/export_chat_invite_link.py | 2 +- aiogram/methods/forward_message.py | 2 +- aiogram/methods/get_chat.py | 2 +- aiogram/methods/get_chat_administrators.py | 2 +- aiogram/methods/get_chat_member.py | 2 +- aiogram/methods/get_chat_member_count.py | 2 +- aiogram/methods/get_chat_menu_button.py | 2 +- aiogram/methods/get_custom_emoji_stickers.py | 2 +- aiogram/methods/get_file.py | 2 -- aiogram/methods/get_forum_topic_icon_stickers.py | 2 +- aiogram/methods/get_game_high_scores.py | 2 +- aiogram/methods/get_me.py | 2 -- aiogram/methods/get_my_commands.py | 2 +- .../methods/get_my_default_administrator_rights.py | 2 +- aiogram/methods/get_my_description.py | 2 +- aiogram/methods/get_my_short_description.py | 2 +- aiogram/methods/get_sticker_set.py | 2 -- aiogram/methods/get_updates.py | 2 +- aiogram/methods/get_user_profile_photos.py | 2 +- aiogram/methods/get_webhook_info.py | 2 -- aiogram/methods/hide_general_forum_topic.py | 2 +- aiogram/methods/leave_chat.py | 2 +- aiogram/methods/log_out.py | 2 -- aiogram/methods/pin_chat_message.py | 2 +- aiogram/methods/promote_chat_member.py | 2 +- aiogram/methods/reopen_forum_topic.py | 2 +- aiogram/methods/reopen_general_forum_topic.py | 2 +- aiogram/methods/restrict_chat_member.py | 2 +- aiogram/methods/revoke_chat_invite_link.py | 2 +- aiogram/methods/send_animation.py | 2 +- aiogram/methods/send_audio.py | 2 +- aiogram/methods/send_chat_action.py | 2 +- aiogram/methods/send_contact.py | 2 +- aiogram/methods/send_dice.py | 2 +- aiogram/methods/send_document.py | 2 +- aiogram/methods/send_game.py | 2 +- aiogram/methods/send_invoice.py | 2 +- aiogram/methods/send_location.py | 2 +- aiogram/methods/send_media_group.py | 2 +- aiogram/methods/send_message.py | 4 +--- aiogram/methods/send_photo.py | 2 +- aiogram/methods/send_poll.py | 2 +- aiogram/methods/send_sticker.py | 2 +- aiogram/methods/send_venue.py | 2 +- aiogram/methods/send_video.py | 2 +- aiogram/methods/send_video_note.py | 2 +- aiogram/methods/send_voice.py | 2 +- .../methods/set_chat_administrator_custom_title.py | 2 +- aiogram/methods/set_chat_description.py | 2 +- aiogram/methods/set_chat_menu_button.py | 2 +- aiogram/methods/set_chat_permissions.py | 2 +- aiogram/methods/set_chat_photo.py | 2 +- aiogram/methods/set_chat_sticker_set.py | 2 +- aiogram/methods/set_chat_title.py | 2 +- .../set_custom_emoji_sticker_set_thumbnail.py | 2 +- aiogram/methods/set_game_score.py | 2 +- aiogram/methods/set_my_commands.py | 2 +- .../methods/set_my_default_administrator_rights.py | 2 +- aiogram/methods/set_my_description.py | 2 +- aiogram/methods/set_my_short_description.py | 2 +- aiogram/methods/set_passport_data_errors.py | 2 +- aiogram/methods/set_sticker_emoji_list.py | 2 +- aiogram/methods/set_sticker_keywords.py | 2 +- aiogram/methods/set_sticker_mask_position.py | 2 +- aiogram/methods/set_sticker_position_in_set.py | 2 -- aiogram/methods/set_sticker_set_thumbnail.py | 2 +- aiogram/methods/set_sticker_set_title.py | 2 -- aiogram/methods/set_webhook.py | 2 +- aiogram/methods/stop_message_live_location.py | 2 +- aiogram/methods/stop_poll.py | 2 +- aiogram/methods/unban_chat_member.py | 2 +- aiogram/methods/unban_chat_sender_chat.py | 2 +- aiogram/methods/unhide_general_forum_topic.py | 2 +- aiogram/methods/unpin_all_chat_messages.py | 2 +- aiogram/methods/unpin_all_forum_topic_messages.py | 2 +- aiogram/methods/unpin_chat_message.py | 2 +- aiogram/methods/upload_sticker_file.py | 2 -- .../bot_command_scope_all_chat_administrators.py | 2 -- aiogram/types/bot_command_scope_all_group_chats.py | 2 -- aiogram/types/bot_command_scope_all_private_chats.py | 2 -- aiogram/types/bot_command_scope_chat.py | 2 -- .../types/bot_command_scope_chat_administrators.py | 2 -- aiogram/types/bot_command_scope_chat_member.py | 2 -- aiogram/types/chat_member_administrator.py | 2 -- aiogram/types/chat_member_banned.py | 2 -- aiogram/types/chat_member_left.py | 2 -- aiogram/types/chat_member_member.py | 2 -- aiogram/types/chat_member_owner.py | 2 -- aiogram/types/chat_member_restricted.py | 2 -- aiogram/types/chat_permissions.py | 2 +- aiogram/types/force_reply.py | 4 +--- aiogram/types/inline_keyboard_button.py | 2 +- aiogram/types/inline_keyboard_markup.py | 2 +- aiogram/types/inline_query_result.py | 2 +- aiogram/types/inline_query_result_article.py | 2 -- aiogram/types/inline_query_result_audio.py | 2 -- aiogram/types/inline_query_result_cached_audio.py | 2 -- aiogram/types/inline_query_result_cached_document.py | 2 -- aiogram/types/inline_query_result_cached_gif.py | 2 -- .../types/inline_query_result_cached_mpeg4_gif.py | 2 -- aiogram/types/inline_query_result_cached_photo.py | 2 -- aiogram/types/inline_query_result_cached_sticker.py | 2 -- aiogram/types/inline_query_result_cached_video.py | 2 -- aiogram/types/inline_query_result_cached_voice.py | 2 -- aiogram/types/inline_query_result_contact.py | 2 -- aiogram/types/inline_query_result_document.py | 2 -- aiogram/types/inline_query_result_game.py | 2 -- aiogram/types/inline_query_result_gif.py | 2 -- aiogram/types/inline_query_result_location.py | 2 -- aiogram/types/inline_query_result_mpeg4_gif.py | 2 -- aiogram/types/inline_query_result_photo.py | 2 -- aiogram/types/inline_query_result_venue.py | 2 -- aiogram/types/inline_query_result_video.py | 2 -- aiogram/types/inline_query_result_voice.py | 2 -- aiogram/types/input_media.py | 2 +- aiogram/types/input_media_animation.py | 2 -- aiogram/types/input_media_audio.py | 2 -- aiogram/types/input_media_document.py | 2 -- aiogram/types/input_media_photo.py | 2 -- aiogram/types/input_media_video.py | 2 -- aiogram/types/input_message_content.py | 2 +- aiogram/types/keyboard_button.py | 2 +- aiogram/types/keyboard_button_poll_type.py | 2 +- aiogram/types/labeled_price.py | 2 +- aiogram/types/menu_button.py | 2 +- aiogram/types/menu_button_commands.py | 2 -- aiogram/types/menu_button_default.py | 2 -- aiogram/types/menu_button_web_app.py | 2 -- aiogram/types/message_entity.py | 2 +- aiogram/types/passport_element_error.py | 2 +- aiogram/types/passport_element_error_data_field.py | 2 -- aiogram/types/passport_element_error_file.py | 2 -- aiogram/types/passport_element_error_files.py | 2 -- aiogram/types/passport_element_error_front_side.py | 2 -- aiogram/types/passport_element_error_reverse_side.py | 2 -- aiogram/types/passport_element_error_selfie.py | 2 -- .../types/passport_element_error_translation_file.py | 2 -- .../passport_element_error_translation_files.py | 2 -- aiogram/types/passport_element_error_unspecified.py | 2 -- aiogram/types/reply_keyboard_markup.py | 2 +- aiogram/utils/i18n/middleware.py | 2 +- 177 files changed, 115 insertions(+), 254 deletions(-) diff --git a/aiogram/dispatcher/middlewares/user_context.py b/aiogram/dispatcher/middlewares/user_context.py index 9ede4334..12bb4864 100644 --- a/aiogram/dispatcher/middlewares/user_context.py +++ b/aiogram/dispatcher/middlewares/user_context.py @@ -1,5 +1,4 @@ -from contextlib import contextmanager -from typing import Any, Awaitable, Callable, Dict, Iterator, Optional, Tuple +from typing import Any, Awaitable, Callable, Dict, Optional, Tuple from aiogram.dispatcher.middlewares.base import BaseMiddleware from aiogram.types import Chat, TelegramObject, Update, User diff --git a/aiogram/methods/add_sticker_to_set.py b/aiogram/methods/add_sticker_to_set.py index 49759b84..2c6502a5 100644 --- a/aiogram/methods/add_sticker_to_set.py +++ b/aiogram/methods/add_sticker_to_set.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import InputSticker from .base import TelegramMethod diff --git a/aiogram/methods/answer_callback_query.py b/aiogram/methods/answer_callback_query.py index 4b3e16fd..067c8b34 100644 --- a/aiogram/methods/answer_callback_query.py +++ b/aiogram/methods/answer_callback_query.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/answer_inline_query.py b/aiogram/methods/answer_inline_query.py index 6f189b9b..53eaf5be 100644 --- a/aiogram/methods/answer_inline_query.py +++ b/aiogram/methods/answer_inline_query.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from pydantic import Field diff --git a/aiogram/methods/answer_pre_checkout_query.py b/aiogram/methods/answer_pre_checkout_query.py index a87929fb..8d1679cd 100644 --- a/aiogram/methods/answer_pre_checkout_query.py +++ b/aiogram/methods/answer_pre_checkout_query.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/answer_shipping_query.py b/aiogram/methods/answer_shipping_query.py index 4e62d0cb..81c1eaa6 100644 --- a/aiogram/methods/answer_shipping_query.py +++ b/aiogram/methods/answer_shipping_query.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import ShippingOption from .base import TelegramMethod diff --git a/aiogram/methods/answer_web_app_query.py b/aiogram/methods/answer_web_app_query.py index d45e249d..8bb1abc8 100644 --- a/aiogram/methods/answer_web_app_query.py +++ b/aiogram/methods/answer_web_app_query.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import InlineQueryResult, SentWebAppMessage from .base import TelegramMethod diff --git a/aiogram/methods/approve_chat_join_request.py b/aiogram/methods/approve_chat_join_request.py index 83e34599..4e4693f8 100644 --- a/aiogram/methods/approve_chat_join_request.py +++ b/aiogram/methods/approve_chat_join_request.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/ban_chat_member.py b/aiogram/methods/ban_chat_member.py index ecc468ee..f64791fd 100644 --- a/aiogram/methods/ban_chat_member.py +++ b/aiogram/methods/ban_chat_member.py @@ -1,7 +1,7 @@ from __future__ import annotations import datetime -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/ban_chat_sender_chat.py b/aiogram/methods/ban_chat_sender_chat.py index e63f2ecc..50d51188 100644 --- a/aiogram/methods/ban_chat_sender_chat.py +++ b/aiogram/methods/ban_chat_sender_chat.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/base.py b/aiogram/methods/base.py index 6e14357c..53175784 100644 --- a/aiogram/methods/base.py +++ b/aiogram/methods/base.py @@ -1,17 +1,7 @@ from __future__ import annotations from abc import ABC, abstractmethod -from typing import ( - TYPE_CHECKING, - Any, - Awaitable, - Callable, - Dict, - Generator, - Generic, - Optional, - TypeVar, -) +from typing import TYPE_CHECKING, Any, Dict, Generator, Generic, Optional, TypeVar from pydantic import BaseModel, ConfigDict from pydantic.functional_validators import model_validator diff --git a/aiogram/methods/close.py b/aiogram/methods/close.py index c8e9008d..7c33eca3 100644 --- a/aiogram/methods/close.py +++ b/aiogram/methods/close.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/close_forum_topic.py b/aiogram/methods/close_forum_topic.py index 7ab5a479..3f9f50ea 100644 --- a/aiogram/methods/close_forum_topic.py +++ b/aiogram/methods/close_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/close_general_forum_topic.py b/aiogram/methods/close_general_forum_topic.py index bc44bde5..3c836177 100644 --- a/aiogram/methods/close_general_forum_topic.py +++ b/aiogram/methods/close_general_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/copy_message.py b/aiogram/methods/copy_message.py index 5e34bb7d..4fc4b5b9 100644 --- a/aiogram/methods/copy_message.py +++ b/aiogram/methods/copy_message.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/create_chat_invite_link.py b/aiogram/methods/create_chat_invite_link.py index 539115bb..1bdae992 100644 --- a/aiogram/methods/create_chat_invite_link.py +++ b/aiogram/methods/create_chat_invite_link.py @@ -1,7 +1,7 @@ from __future__ import annotations import datetime -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ChatInviteLink from .base import TelegramMethod diff --git a/aiogram/methods/create_forum_topic.py b/aiogram/methods/create_forum_topic.py index f4b3f4da..ece98d43 100644 --- a/aiogram/methods/create_forum_topic.py +++ b/aiogram/methods/create_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ForumTopic from .base import TelegramMethod diff --git a/aiogram/methods/create_invoice_link.py b/aiogram/methods/create_invoice_link.py index de6497c1..8b6fc883 100644 --- a/aiogram/methods/create_invoice_link.py +++ b/aiogram/methods/create_invoice_link.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import LabeledPrice from .base import TelegramMethod diff --git a/aiogram/methods/create_new_sticker_set.py b/aiogram/methods/create_new_sticker_set.py index 6406df81..abf25d79 100644 --- a/aiogram/methods/create_new_sticker_set.py +++ b/aiogram/methods/create_new_sticker_set.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import InputSticker from .base import TelegramMethod diff --git a/aiogram/methods/decline_chat_join_request.py b/aiogram/methods/decline_chat_join_request.py index 7861b7bb..0334c299 100644 --- a/aiogram/methods/decline_chat_join_request.py +++ b/aiogram/methods/decline_chat_join_request.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/delete_chat_photo.py b/aiogram/methods/delete_chat_photo.py index 11a3836e..e146cdac 100644 --- a/aiogram/methods/delete_chat_photo.py +++ b/aiogram/methods/delete_chat_photo.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/delete_chat_sticker_set.py b/aiogram/methods/delete_chat_sticker_set.py index 681293df..2162f860 100644 --- a/aiogram/methods/delete_chat_sticker_set.py +++ b/aiogram/methods/delete_chat_sticker_set.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/delete_forum_topic.py b/aiogram/methods/delete_forum_topic.py index 4733c67d..1e4f9b46 100644 --- a/aiogram/methods/delete_forum_topic.py +++ b/aiogram/methods/delete_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/delete_message.py b/aiogram/methods/delete_message.py index 468411d5..99c972d7 100644 --- a/aiogram/methods/delete_message.py +++ b/aiogram/methods/delete_message.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/delete_my_commands.py b/aiogram/methods/delete_my_commands.py index d73814db..5fc1044e 100644 --- a/aiogram/methods/delete_my_commands.py +++ b/aiogram/methods/delete_my_commands.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import BotCommandScope from .base import TelegramMethod diff --git a/aiogram/methods/delete_sticker_from_set.py b/aiogram/methods/delete_sticker_from_set.py index 96219c15..1ab3e3a8 100644 --- a/aiogram/methods/delete_sticker_from_set.py +++ b/aiogram/methods/delete_sticker_from_set.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/delete_sticker_set.py b/aiogram/methods/delete_sticker_set.py index d5a0f67e..27b4cfc2 100644 --- a/aiogram/methods/delete_sticker_set.py +++ b/aiogram/methods/delete_sticker_set.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/delete_webhook.py b/aiogram/methods/delete_webhook.py index b9d6cd7b..ef1bdc88 100644 --- a/aiogram/methods/delete_webhook.py +++ b/aiogram/methods/delete_webhook.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/edit_chat_invite_link.py b/aiogram/methods/edit_chat_invite_link.py index 26f4ccc3..f94111ed 100644 --- a/aiogram/methods/edit_chat_invite_link.py +++ b/aiogram/methods/edit_chat_invite_link.py @@ -1,7 +1,7 @@ from __future__ import annotations import datetime -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ChatInviteLink from .base import TelegramMethod diff --git a/aiogram/methods/edit_forum_topic.py b/aiogram/methods/edit_forum_topic.py index f87d0cea..46ef0e58 100644 --- a/aiogram/methods/edit_forum_topic.py +++ b/aiogram/methods/edit_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/edit_general_forum_topic.py b/aiogram/methods/edit_general_forum_topic.py index f35c2048..1de088cf 100644 --- a/aiogram/methods/edit_general_forum_topic.py +++ b/aiogram/methods/edit_general_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/edit_message_caption.py b/aiogram/methods/edit_message_caption.py index 66cdeac9..ee2f8482 100644 --- a/aiogram/methods/edit_message_caption.py +++ b/aiogram/methods/edit_message_caption.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import UNSET_PARSE_MODE, InlineKeyboardMarkup, Message, MessageEntity from .base import TelegramMethod diff --git a/aiogram/methods/edit_message_live_location.py b/aiogram/methods/edit_message_live_location.py index e35c3225..43ff24e7 100644 --- a/aiogram/methods/edit_message_live_location.py +++ b/aiogram/methods/edit_message_live_location.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InlineKeyboardMarkup, Message from .base import TelegramMethod diff --git a/aiogram/methods/edit_message_media.py b/aiogram/methods/edit_message_media.py index f986a841..f6ab0166 100644 --- a/aiogram/methods/edit_message_media.py +++ b/aiogram/methods/edit_message_media.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InlineKeyboardMarkup, InputMedia, Message from .base import TelegramMethod diff --git a/aiogram/methods/edit_message_reply_markup.py b/aiogram/methods/edit_message_reply_markup.py index a828c9d8..7c8be63f 100644 --- a/aiogram/methods/edit_message_reply_markup.py +++ b/aiogram/methods/edit_message_reply_markup.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InlineKeyboardMarkup, Message from .base import TelegramMethod diff --git a/aiogram/methods/edit_message_text.py b/aiogram/methods/edit_message_text.py index 79887c97..357a757b 100644 --- a/aiogram/methods/edit_message_text.py +++ b/aiogram/methods/edit_message_text.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import UNSET_PARSE_MODE, InlineKeyboardMarkup, Message, MessageEntity from ..types.base import UNSET_DISABLE_WEB_PAGE_PREVIEW diff --git a/aiogram/methods/export_chat_invite_link.py b/aiogram/methods/export_chat_invite_link.py index ba4436ed..61642387 100644 --- a/aiogram/methods/export_chat_invite_link.py +++ b/aiogram/methods/export_chat_invite_link.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/forward_message.py b/aiogram/methods/forward_message.py index 45c084a0..86d33f8d 100644 --- a/aiogram/methods/forward_message.py +++ b/aiogram/methods/forward_message.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import Message from ..types.base import UNSET_PROTECT_CONTENT diff --git a/aiogram/methods/get_chat.py b/aiogram/methods/get_chat.py index a565529a..d0416238 100644 --- a/aiogram/methods/get_chat.py +++ b/aiogram/methods/get_chat.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from ..types import Chat from .base import TelegramMethod diff --git a/aiogram/methods/get_chat_administrators.py b/aiogram/methods/get_chat_administrators.py index 3e0cac3c..b6479ec8 100644 --- a/aiogram/methods/get_chat_administrators.py +++ b/aiogram/methods/get_chat_administrators.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Union +from typing import List, Union from ..types import ( ChatMemberAdministrator, diff --git a/aiogram/methods/get_chat_member.py b/aiogram/methods/get_chat_member.py index ab308024..9e8ba619 100644 --- a/aiogram/methods/get_chat_member.py +++ b/aiogram/methods/get_chat_member.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from ..types import ( ChatMemberAdministrator, diff --git a/aiogram/methods/get_chat_member_count.py b/aiogram/methods/get_chat_member_count.py index c1b08e5b..a411d0c9 100644 --- a/aiogram/methods/get_chat_member_count.py +++ b/aiogram/methods/get_chat_member_count.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/get_chat_menu_button.py b/aiogram/methods/get_chat_menu_button.py index 6679d5df..df280b66 100644 --- a/aiogram/methods/get_chat_menu_button.py +++ b/aiogram/methods/get_chat_menu_button.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import MenuButtonCommands, MenuButtonDefault, MenuButtonWebApp from .base import TelegramMethod diff --git a/aiogram/methods/get_custom_emoji_stickers.py b/aiogram/methods/get_custom_emoji_stickers.py index 3522b539..a98582d9 100644 --- a/aiogram/methods/get_custom_emoji_stickers.py +++ b/aiogram/methods/get_custom_emoji_stickers.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List +from typing import List from ..types import Sticker from .base import TelegramMethod diff --git a/aiogram/methods/get_file.py b/aiogram/methods/get_file.py index b84ff940..8358e250 100644 --- a/aiogram/methods/get_file.py +++ b/aiogram/methods/get_file.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import File from .base import TelegramMethod diff --git a/aiogram/methods/get_forum_topic_icon_stickers.py b/aiogram/methods/get_forum_topic_icon_stickers.py index 31965661..5c233215 100644 --- a/aiogram/methods/get_forum_topic_icon_stickers.py +++ b/aiogram/methods/get_forum_topic_icon_stickers.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List +from typing import List from ..types import Sticker from .base import TelegramMethod diff --git a/aiogram/methods/get_game_high_scores.py b/aiogram/methods/get_game_high_scores.py index aff1c56a..1251658c 100644 --- a/aiogram/methods/get_game_high_scores.py +++ b/aiogram/methods/get_game_high_scores.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import GameHighScore from .base import TelegramMethod diff --git a/aiogram/methods/get_me.py b/aiogram/methods/get_me.py index 1a7f1fe1..c2cc52f9 100644 --- a/aiogram/methods/get_me.py +++ b/aiogram/methods/get_me.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import User from .base import TelegramMethod diff --git a/aiogram/methods/get_my_commands.py b/aiogram/methods/get_my_commands.py index d1e5c9c3..9d4a696f 100644 --- a/aiogram/methods/get_my_commands.py +++ b/aiogram/methods/get_my_commands.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import BotCommand, BotCommandScope from .base import TelegramMethod diff --git a/aiogram/methods/get_my_default_administrator_rights.py b/aiogram/methods/get_my_default_administrator_rights.py index d20e7a15..1c7c0195 100644 --- a/aiogram/methods/get_my_default_administrator_rights.py +++ b/aiogram/methods/get_my_default_administrator_rights.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import ChatAdministratorRights from .base import TelegramMethod diff --git a/aiogram/methods/get_my_description.py b/aiogram/methods/get_my_description.py index 3b0534ff..db002daa 100644 --- a/aiogram/methods/get_my_description.py +++ b/aiogram/methods/get_my_description.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import BotDescription from .base import TelegramMethod diff --git a/aiogram/methods/get_my_short_description.py b/aiogram/methods/get_my_short_description.py index 81731142..962642e4 100644 --- a/aiogram/methods/get_my_short_description.py +++ b/aiogram/methods/get_my_short_description.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import BotShortDescription from .base import TelegramMethod diff --git a/aiogram/methods/get_sticker_set.py b/aiogram/methods/get_sticker_set.py index 87041172..43ab5311 100644 --- a/aiogram/methods/get_sticker_set.py +++ b/aiogram/methods/get_sticker_set.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import StickerSet from .base import TelegramMethod diff --git a/aiogram/methods/get_updates.py b/aiogram/methods/get_updates.py index b22c9755..80abf78c 100644 --- a/aiogram/methods/get_updates.py +++ b/aiogram/methods/get_updates.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import Update from .base import TelegramMethod diff --git a/aiogram/methods/get_user_profile_photos.py b/aiogram/methods/get_user_profile_photos.py index 47abc196..e58bd970 100644 --- a/aiogram/methods/get_user_profile_photos.py +++ b/aiogram/methods/get_user_profile_photos.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import UserProfilePhotos from .base import TelegramMethod diff --git a/aiogram/methods/get_webhook_info.py b/aiogram/methods/get_webhook_info.py index 5e4e194c..c9f0e46f 100644 --- a/aiogram/methods/get_webhook_info.py +++ b/aiogram/methods/get_webhook_info.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import WebhookInfo from .base import TelegramMethod diff --git a/aiogram/methods/hide_general_forum_topic.py b/aiogram/methods/hide_general_forum_topic.py index 2587cf9e..25e6421b 100644 --- a/aiogram/methods/hide_general_forum_topic.py +++ b/aiogram/methods/hide_general_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/leave_chat.py b/aiogram/methods/leave_chat.py index 5b2e15cf..f1784f65 100644 --- a/aiogram/methods/leave_chat.py +++ b/aiogram/methods/leave_chat.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/log_out.py b/aiogram/methods/log_out.py index 3f3ea3de..2a626535 100644 --- a/aiogram/methods/log_out.py +++ b/aiogram/methods/log_out.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/pin_chat_message.py b/aiogram/methods/pin_chat_message.py index d1641eea..24e7a7c1 100644 --- a/aiogram/methods/pin_chat_message.py +++ b/aiogram/methods/pin_chat_message.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/promote_chat_member.py b/aiogram/methods/promote_chat_member.py index d8f6096f..c74d1de9 100644 --- a/aiogram/methods/promote_chat_member.py +++ b/aiogram/methods/promote_chat_member.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/reopen_forum_topic.py b/aiogram/methods/reopen_forum_topic.py index efe1c31d..729db37c 100644 --- a/aiogram/methods/reopen_forum_topic.py +++ b/aiogram/methods/reopen_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/reopen_general_forum_topic.py b/aiogram/methods/reopen_general_forum_topic.py index 381278a9..ea3a4a47 100644 --- a/aiogram/methods/reopen_general_forum_topic.py +++ b/aiogram/methods/reopen_general_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/restrict_chat_member.py b/aiogram/methods/restrict_chat_member.py index efea2f97..9240ea60 100644 --- a/aiogram/methods/restrict_chat_member.py +++ b/aiogram/methods/restrict_chat_member.py @@ -1,7 +1,7 @@ from __future__ import annotations import datetime -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ChatPermissions from .base import TelegramMethod diff --git a/aiogram/methods/revoke_chat_invite_link.py b/aiogram/methods/revoke_chat_invite_link.py index ad31e77d..e7d9c50e 100644 --- a/aiogram/methods/revoke_chat_invite_link.py +++ b/aiogram/methods/revoke_chat_invite_link.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from ..types import ChatInviteLink from .base import TelegramMethod diff --git a/aiogram/methods/send_animation.py b/aiogram/methods/send_animation.py index 14029d25..088ce252 100644 --- a/aiogram/methods/send_animation.py +++ b/aiogram/methods/send_animation.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_audio.py b/aiogram/methods/send_audio.py index e0f4b900..e947cbde 100644 --- a/aiogram/methods/send_audio.py +++ b/aiogram/methods/send_audio.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_chat_action.py b/aiogram/methods/send_chat_action.py index d21dc68c..009fea09 100644 --- a/aiogram/methods/send_chat_action.py +++ b/aiogram/methods/send_chat_action.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/send_contact.py b/aiogram/methods/send_contact.py index 35473338..d0454674 100644 --- a/aiogram/methods/send_contact.py +++ b/aiogram/methods/send_contact.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_dice.py b/aiogram/methods/send_dice.py index 9fa2ce70..bc58d53a 100644 --- a/aiogram/methods/send_dice.py +++ b/aiogram/methods/send_dice.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_document.py b/aiogram/methods/send_document.py index 5c83beb3..cacb62a5 100644 --- a/aiogram/methods/send_document.py +++ b/aiogram/methods/send_document.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_game.py b/aiogram/methods/send_game.py index ab55a459..f713d6a6 100644 --- a/aiogram/methods/send_game.py +++ b/aiogram/methods/send_game.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import InlineKeyboardMarkup, Message from ..types.base import UNSET_PROTECT_CONTENT diff --git a/aiogram/methods/send_invoice.py b/aiogram/methods/send_invoice.py index d08002a9..aca8aa71 100644 --- a/aiogram/methods/send_invoice.py +++ b/aiogram/methods/send_invoice.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import InlineKeyboardMarkup, LabeledPrice, Message from ..types.base import UNSET_PROTECT_CONTENT diff --git a/aiogram/methods/send_location.py b/aiogram/methods/send_location.py index 845b4741..ddfb3604 100644 --- a/aiogram/methods/send_location.py +++ b/aiogram/methods/send_location.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_media_group.py b/aiogram/methods/send_media_group.py index fd8dbb25..a01e4de8 100644 --- a/aiogram/methods/send_media_group.py +++ b/aiogram/methods/send_media_group.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( InputMediaAudio, diff --git a/aiogram/methods/send_message.py b/aiogram/methods/send_message.py index 263871b0..1e460239 100644 --- a/aiogram/methods/send_message.py +++ b/aiogram/methods/send_message.py @@ -1,8 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union - -from pydantic import Field +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_photo.py b/aiogram/methods/send_photo.py index 236d8710..6ce9d928 100644 --- a/aiogram/methods/send_photo.py +++ b/aiogram/methods/send_photo.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_poll.py b/aiogram/methods/send_poll.py index fca3dc58..41d7e4c5 100644 --- a/aiogram/methods/send_poll.py +++ b/aiogram/methods/send_poll.py @@ -1,7 +1,7 @@ from __future__ import annotations import datetime -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_sticker.py b/aiogram/methods/send_sticker.py index 8429b105..384a5adb 100644 --- a/aiogram/methods/send_sticker.py +++ b/aiogram/methods/send_sticker.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_venue.py b/aiogram/methods/send_venue.py index d0859770..ac69fdc6 100644 --- a/aiogram/methods/send_venue.py +++ b/aiogram/methods/send_venue.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_video.py b/aiogram/methods/send_video.py index a894e335..1ee7c903 100644 --- a/aiogram/methods/send_video.py +++ b/aiogram/methods/send_video.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/send_video_note.py b/aiogram/methods/send_video_note.py index 761c91a2..cd270e94 100644 --- a/aiogram/methods/send_video_note.py +++ b/aiogram/methods/send_video_note.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ( ForceReply, diff --git a/aiogram/methods/send_voice.py b/aiogram/methods/send_voice.py index ae692ad6..d9c915f4 100644 --- a/aiogram/methods/send_voice.py +++ b/aiogram/methods/send_voice.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional, Union +from typing import List, Optional, Union from ..types import ( UNSET_PARSE_MODE, diff --git a/aiogram/methods/set_chat_administrator_custom_title.py b/aiogram/methods/set_chat_administrator_custom_title.py index edf79d8c..5415594f 100644 --- a/aiogram/methods/set_chat_administrator_custom_title.py +++ b/aiogram/methods/set_chat_administrator_custom_title.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_description.py b/aiogram/methods/set_chat_description.py index 05b51a69..81eaf263 100644 --- a/aiogram/methods/set_chat_description.py +++ b/aiogram/methods/set_chat_description.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_menu_button.py b/aiogram/methods/set_chat_menu_button.py index 6eeb3a10..4fdd086b 100644 --- a/aiogram/methods/set_chat_menu_button.py +++ b/aiogram/methods/set_chat_menu_button.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import MenuButtonCommands, MenuButtonDefault, MenuButtonWebApp from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_permissions.py b/aiogram/methods/set_chat_permissions.py index af13ddb7..3c3ed008 100644 --- a/aiogram/methods/set_chat_permissions.py +++ b/aiogram/methods/set_chat_permissions.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import ChatPermissions from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_photo.py b/aiogram/methods/set_chat_photo.py index ba7b8de3..dc07a445 100644 --- a/aiogram/methods/set_chat_photo.py +++ b/aiogram/methods/set_chat_photo.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from ..types import InputFile from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_sticker_set.py b/aiogram/methods/set_chat_sticker_set.py index a7f3d216..6df42a0a 100644 --- a/aiogram/methods/set_chat_sticker_set.py +++ b/aiogram/methods/set_chat_sticker_set.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/set_chat_title.py b/aiogram/methods/set_chat_title.py index 07507d0f..b4ce0a4a 100644 --- a/aiogram/methods/set_chat_title.py +++ b/aiogram/methods/set_chat_title.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/set_custom_emoji_sticker_set_thumbnail.py b/aiogram/methods/set_custom_emoji_sticker_set_thumbnail.py index 10a4a267..8c8fa479 100644 --- a/aiogram/methods/set_custom_emoji_sticker_set_thumbnail.py +++ b/aiogram/methods/set_custom_emoji_sticker_set_thumbnail.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/set_game_score.py b/aiogram/methods/set_game_score.py index 170988ec..590ca59d 100644 --- a/aiogram/methods/set_game_score.py +++ b/aiogram/methods/set_game_score.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import Message from .base import TelegramMethod diff --git a/aiogram/methods/set_my_commands.py b/aiogram/methods/set_my_commands.py index a62e7a84..c668852d 100644 --- a/aiogram/methods/set_my_commands.py +++ b/aiogram/methods/set_my_commands.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import BotCommand, BotCommandScope from .base import TelegramMethod diff --git a/aiogram/methods/set_my_default_administrator_rights.py b/aiogram/methods/set_my_default_administrator_rights.py index 0b1468bc..8817a9dc 100644 --- a/aiogram/methods/set_my_default_administrator_rights.py +++ b/aiogram/methods/set_my_default_administrator_rights.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import ChatAdministratorRights from .base import TelegramMethod diff --git a/aiogram/methods/set_my_description.py b/aiogram/methods/set_my_description.py index 2af2ed44..fba6b8d3 100644 --- a/aiogram/methods/set_my_description.py +++ b/aiogram/methods/set_my_description.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/set_my_short_description.py b/aiogram/methods/set_my_short_description.py index 19e5b254..0c697d4b 100644 --- a/aiogram/methods/set_my_short_description.py +++ b/aiogram/methods/set_my_short_description.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from .base import TelegramMethod diff --git a/aiogram/methods/set_passport_data_errors.py b/aiogram/methods/set_passport_data_errors.py index ae127d2b..f829fa47 100644 --- a/aiogram/methods/set_passport_data_errors.py +++ b/aiogram/methods/set_passport_data_errors.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List +from typing import List from ..types import PassportElementError from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_emoji_list.py b/aiogram/methods/set_sticker_emoji_list.py index f23033c7..b88f609e 100644 --- a/aiogram/methods/set_sticker_emoji_list.py +++ b/aiogram/methods/set_sticker_emoji_list.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List +from typing import List from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_keywords.py b/aiogram/methods/set_sticker_keywords.py index 0ebef118..1179613b 100644 --- a/aiogram/methods/set_sticker_keywords.py +++ b/aiogram/methods/set_sticker_keywords.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_mask_position.py b/aiogram/methods/set_sticker_mask_position.py index f3147f2d..7e82b061 100644 --- a/aiogram/methods/set_sticker_mask_position.py +++ b/aiogram/methods/set_sticker_mask_position.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional +from typing import Optional from ..types import MaskPosition from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_position_in_set.py b/aiogram/methods/set_sticker_position_in_set.py index ed5792ae..395d2e05 100644 --- a/aiogram/methods/set_sticker_position_in_set.py +++ b/aiogram/methods/set_sticker_position_in_set.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_set_thumbnail.py b/aiogram/methods/set_sticker_set_thumbnail.py index 7da1c397..3624bce4 100644 --- a/aiogram/methods/set_sticker_set_thumbnail.py +++ b/aiogram/methods/set_sticker_set_thumbnail.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InputFile from .base import TelegramMethod diff --git a/aiogram/methods/set_sticker_set_title.py b/aiogram/methods/set_sticker_set_title.py index 978432ff..1136353f 100644 --- a/aiogram/methods/set_sticker_set_title.py +++ b/aiogram/methods/set_sticker_set_title.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from .base import TelegramMethod diff --git a/aiogram/methods/set_webhook.py b/aiogram/methods/set_webhook.py index 6e63a75a..66ec86ff 100644 --- a/aiogram/methods/set_webhook.py +++ b/aiogram/methods/set_webhook.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, List, Optional +from typing import List, Optional from ..types import InputFile from .base import TelegramMethod diff --git a/aiogram/methods/stop_message_live_location.py b/aiogram/methods/stop_message_live_location.py index 8a16f586..9361dfae 100644 --- a/aiogram/methods/stop_message_live_location.py +++ b/aiogram/methods/stop_message_live_location.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InlineKeyboardMarkup, Message from .base import TelegramMethod diff --git a/aiogram/methods/stop_poll.py b/aiogram/methods/stop_poll.py index 19ef26ac..2e93f087 100644 --- a/aiogram/methods/stop_poll.py +++ b/aiogram/methods/stop_poll.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from ..types import InlineKeyboardMarkup, Poll from .base import TelegramMethod diff --git a/aiogram/methods/unban_chat_member.py b/aiogram/methods/unban_chat_member.py index 768eea22..19ef9ef7 100644 --- a/aiogram/methods/unban_chat_member.py +++ b/aiogram/methods/unban_chat_member.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/unban_chat_sender_chat.py b/aiogram/methods/unban_chat_sender_chat.py index fbd3f1d3..e81278d3 100644 --- a/aiogram/methods/unban_chat_sender_chat.py +++ b/aiogram/methods/unban_chat_sender_chat.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/unhide_general_forum_topic.py b/aiogram/methods/unhide_general_forum_topic.py index 82524758..cebcec25 100644 --- a/aiogram/methods/unhide_general_forum_topic.py +++ b/aiogram/methods/unhide_general_forum_topic.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/unpin_all_chat_messages.py b/aiogram/methods/unpin_all_chat_messages.py index f8566e33..76927e63 100644 --- a/aiogram/methods/unpin_all_chat_messages.py +++ b/aiogram/methods/unpin_all_chat_messages.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/unpin_all_forum_topic_messages.py b/aiogram/methods/unpin_all_forum_topic_messages.py index 6b735e98..09729e2c 100644 --- a/aiogram/methods/unpin_all_forum_topic_messages.py +++ b/aiogram/methods/unpin_all_forum_topic_messages.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Union +from typing import Union from .base import TelegramMethod diff --git a/aiogram/methods/unpin_chat_message.py b/aiogram/methods/unpin_chat_message.py index 0d5d2b0a..3fb70154 100644 --- a/aiogram/methods/unpin_chat_message.py +++ b/aiogram/methods/unpin_chat_message.py @@ -1,6 +1,6 @@ from __future__ import annotations -from typing import TYPE_CHECKING, Optional, Union +from typing import Optional, Union from .base import TelegramMethod diff --git a/aiogram/methods/upload_sticker_file.py b/aiogram/methods/upload_sticker_file.py index 2194e35f..fd1a229e 100644 --- a/aiogram/methods/upload_sticker_file.py +++ b/aiogram/methods/upload_sticker_file.py @@ -1,7 +1,5 @@ from __future__ import annotations -from typing import TYPE_CHECKING - from ..types import File, InputFile from .base import TelegramMethod diff --git a/aiogram/types/bot_command_scope_all_chat_administrators.py b/aiogram/types/bot_command_scope_all_chat_administrators.py index 9d033a2a..ed3dd181 100644 --- a/aiogram/types/bot_command_scope_all_chat_administrators.py +++ b/aiogram/types/bot_command_scope_all_chat_administrators.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/bot_command_scope_all_group_chats.py b/aiogram/types/bot_command_scope_all_group_chats.py index 479e38b6..3393266a 100644 --- a/aiogram/types/bot_command_scope_all_group_chats.py +++ b/aiogram/types/bot_command_scope_all_group_chats.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/bot_command_scope_all_private_chats.py b/aiogram/types/bot_command_scope_all_private_chats.py index 6399e5ab..c53303d1 100644 --- a/aiogram/types/bot_command_scope_all_private_chats.py +++ b/aiogram/types/bot_command_scope_all_private_chats.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/bot_command_scope_chat.py b/aiogram/types/bot_command_scope_chat.py index 6fa2677b..f0ef7b58 100644 --- a/aiogram/types/bot_command_scope_chat.py +++ b/aiogram/types/bot_command_scope_chat.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal, Union -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/bot_command_scope_chat_administrators.py b/aiogram/types/bot_command_scope_chat_administrators.py index 09873f2a..65513db2 100644 --- a/aiogram/types/bot_command_scope_chat_administrators.py +++ b/aiogram/types/bot_command_scope_chat_administrators.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal, Union -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/bot_command_scope_chat_member.py b/aiogram/types/bot_command_scope_chat_member.py index b76dd883..efb97870 100644 --- a/aiogram/types/bot_command_scope_chat_member.py +++ b/aiogram/types/bot_command_scope_chat_member.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal, Union -from pydantic import Field - from ..enums import BotCommandScopeType from .bot_command_scope import BotCommandScope diff --git a/aiogram/types/chat_member_administrator.py b/aiogram/types/chat_member_administrator.py index 33aa999d..ae98e79d 100644 --- a/aiogram/types/chat_member_administrator.py +++ b/aiogram/types/chat_member_administrator.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_member_banned.py b/aiogram/types/chat_member_banned.py index 038bbef1..33e85f45 100644 --- a/aiogram/types/chat_member_banned.py +++ b/aiogram/types/chat_member_banned.py @@ -3,8 +3,6 @@ from __future__ import annotations import datetime from typing import TYPE_CHECKING, Literal -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_member_left.py b/aiogram/types/chat_member_left.py index 2abe1f23..af501917 100644 --- a/aiogram/types/chat_member_left.py +++ b/aiogram/types/chat_member_left.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_member_member.py b/aiogram/types/chat_member_member.py index 1f9f032b..e2c7418e 100644 --- a/aiogram/types/chat_member_member.py +++ b/aiogram/types/chat_member_member.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_member_owner.py b/aiogram/types/chat_member_owner.py index 605c9a8b..66450550 100644 --- a/aiogram/types/chat_member_owner.py +++ b/aiogram/types/chat_member_owner.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_member_restricted.py b/aiogram/types/chat_member_restricted.py index 963bf123..17db73fb 100644 --- a/aiogram/types/chat_member_restricted.py +++ b/aiogram/types/chat_member_restricted.py @@ -3,8 +3,6 @@ from __future__ import annotations import datetime from typing import TYPE_CHECKING, Literal -from pydantic import Field - from ..enums import ChatMemberStatus from .chat_member import ChatMember diff --git a/aiogram/types/chat_permissions.py b/aiogram/types/chat_permissions.py index 0ff4e7c4..762fe208 100644 --- a/aiogram/types/chat_permissions.py +++ b/aiogram/types/chat_permissions.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class ChatPermissions(MutableTelegramObject): diff --git a/aiogram/types/force_reply.py b/aiogram/types/force_reply.py index ae6428e6..cd13b658 100644 --- a/aiogram/types/force_reply.py +++ b/aiogram/types/force_reply.py @@ -2,9 +2,7 @@ from __future__ import annotations from typing import Literal, Optional -from pydantic import Field - -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class ForceReply(MutableTelegramObject): diff --git a/aiogram/types/inline_keyboard_button.py b/aiogram/types/inline_keyboard_button.py index afe3be79..977fae8d 100644 --- a/aiogram/types/inline_keyboard_button.py +++ b/aiogram/types/inline_keyboard_button.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .callback_game import CallbackGame diff --git a/aiogram/types/inline_keyboard_markup.py b/aiogram/types/inline_keyboard_markup.py index ff0387dd..473e292c 100644 --- a/aiogram/types/inline_keyboard_markup.py +++ b/aiogram/types/inline_keyboard_markup.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, List -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .inline_keyboard_button import InlineKeyboardButton diff --git a/aiogram/types/inline_query_result.py b/aiogram/types/inline_query_result.py index b53e4aab..b615aa2b 100644 --- a/aiogram/types/inline_query_result.py +++ b/aiogram/types/inline_query_result.py @@ -1,6 +1,6 @@ from __future__ import annotations -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class InlineQueryResult(MutableTelegramObject): diff --git a/aiogram/types/inline_query_result_article.py b/aiogram/types/inline_query_result_article.py index 8b65d35b..be084aed 100644 --- a/aiogram/types/inline_query_result_article.py +++ b/aiogram/types/inline_query_result_article.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_audio.py b/aiogram/types/inline_query_result_audio.py index fa275c05..74cea130 100644 --- a/aiogram/types/inline_query_result_audio.py +++ b/aiogram/types/inline_query_result_audio.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_audio.py b/aiogram/types/inline_query_result_cached_audio.py index 1f163947..8d4819cc 100644 --- a/aiogram/types/inline_query_result_cached_audio.py +++ b/aiogram/types/inline_query_result_cached_audio.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_document.py b/aiogram/types/inline_query_result_cached_document.py index cd9a2682..cedb45a8 100644 --- a/aiogram/types/inline_query_result_cached_document.py +++ b/aiogram/types/inline_query_result_cached_document.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_gif.py b/aiogram/types/inline_query_result_cached_gif.py index 299e9c13..acbcb6fa 100644 --- a/aiogram/types/inline_query_result_cached_gif.py +++ b/aiogram/types/inline_query_result_cached_gif.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_mpeg4_gif.py b/aiogram/types/inline_query_result_cached_mpeg4_gif.py index e4d09b70..f9605d68 100644 --- a/aiogram/types/inline_query_result_cached_mpeg4_gif.py +++ b/aiogram/types/inline_query_result_cached_mpeg4_gif.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_photo.py b/aiogram/types/inline_query_result_cached_photo.py index 1f0d294a..96b6d208 100644 --- a/aiogram/types/inline_query_result_cached_photo.py +++ b/aiogram/types/inline_query_result_cached_photo.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_sticker.py b/aiogram/types/inline_query_result_cached_sticker.py index 6d27d10e..27f95c09 100644 --- a/aiogram/types/inline_query_result_cached_sticker.py +++ b/aiogram/types/inline_query_result_cached_sticker.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_video.py b/aiogram/types/inline_query_result_cached_video.py index 2f94ddc3..c1afd26e 100644 --- a/aiogram/types/inline_query_result_cached_video.py +++ b/aiogram/types/inline_query_result_cached_video.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_cached_voice.py b/aiogram/types/inline_query_result_cached_voice.py index 0b5d3d46..354b6f39 100644 --- a/aiogram/types/inline_query_result_cached_voice.py +++ b/aiogram/types/inline_query_result_cached_voice.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_contact.py b/aiogram/types/inline_query_result_contact.py index fb2edf83..121dfba9 100644 --- a/aiogram/types/inline_query_result_contact.py +++ b/aiogram/types/inline_query_result_contact.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_document.py b/aiogram/types/inline_query_result_document.py index 12edb742..13a4e7c5 100644 --- a/aiogram/types/inline_query_result_document.py +++ b/aiogram/types/inline_query_result_document.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_game.py b/aiogram/types/inline_query_result_game.py index 58fee484..b5ae90fc 100644 --- a/aiogram/types/inline_query_result_game.py +++ b/aiogram/types/inline_query_result_game.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_gif.py b/aiogram/types/inline_query_result_gif.py index 9136b3a9..1120369f 100644 --- a/aiogram/types/inline_query_result_gif.py +++ b/aiogram/types/inline_query_result_gif.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_location.py b/aiogram/types/inline_query_result_location.py index 6841434b..1dbda6a8 100644 --- a/aiogram/types/inline_query_result_location.py +++ b/aiogram/types/inline_query_result_location.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_mpeg4_gif.py b/aiogram/types/inline_query_result_mpeg4_gif.py index 682b1dfa..d14491c6 100644 --- a/aiogram/types/inline_query_result_mpeg4_gif.py +++ b/aiogram/types/inline_query_result_mpeg4_gif.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_photo.py b/aiogram/types/inline_query_result_photo.py index 38533f85..086118f0 100644 --- a/aiogram/types/inline_query_result_photo.py +++ b/aiogram/types/inline_query_result_photo.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_venue.py b/aiogram/types/inline_query_result_venue.py index 2972b435..6f0aeb66 100644 --- a/aiogram/types/inline_query_result_venue.py +++ b/aiogram/types/inline_query_result_venue.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_video.py b/aiogram/types/inline_query_result_video.py index 8326f748..b1c6775e 100644 --- a/aiogram/types/inline_query_result_video.py +++ b/aiogram/types/inline_query_result_video.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/inline_query_result_voice.py b/aiogram/types/inline_query_result_voice.py index eef9eef3..e97a994e 100644 --- a/aiogram/types/inline_query_result_voice.py +++ b/aiogram/types/inline_query_result_voice.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional -from pydantic import Field - from ..enums import InlineQueryResultType from .base import UNSET_PARSE_MODE from .inline_query_result import InlineQueryResult diff --git a/aiogram/types/input_media.py b/aiogram/types/input_media.py index 90fe5ac3..f7523c9e 100644 --- a/aiogram/types/input_media.py +++ b/aiogram/types/input_media.py @@ -1,6 +1,6 @@ from __future__ import annotations -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class InputMedia(MutableTelegramObject): diff --git a/aiogram/types/input_media_animation.py b/aiogram/types/input_media_animation.py index dfd6f118..f0e1b860 100644 --- a/aiogram/types/input_media_animation.py +++ b/aiogram/types/input_media_animation.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional, Union -from pydantic import Field - from ..enums import InputMediaType from .base import UNSET_PARSE_MODE from .input_media import InputMedia diff --git a/aiogram/types/input_media_audio.py b/aiogram/types/input_media_audio.py index b43b99c7..4bfa74c2 100644 --- a/aiogram/types/input_media_audio.py +++ b/aiogram/types/input_media_audio.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional, Union -from pydantic import Field - from ..enums import InputMediaType from .base import UNSET_PARSE_MODE from .input_media import InputMedia diff --git a/aiogram/types/input_media_document.py b/aiogram/types/input_media_document.py index 704e098d..b749cdcb 100644 --- a/aiogram/types/input_media_document.py +++ b/aiogram/types/input_media_document.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional, Union -from pydantic import Field - from ..enums import InputMediaType from .base import UNSET_PARSE_MODE from .input_media import InputMedia diff --git a/aiogram/types/input_media_photo.py b/aiogram/types/input_media_photo.py index ab04991d..9128627b 100644 --- a/aiogram/types/input_media_photo.py +++ b/aiogram/types/input_media_photo.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional, Union -from pydantic import Field - from ..enums import InputMediaType from .base import UNSET_PARSE_MODE from .input_media import InputMedia diff --git a/aiogram/types/input_media_video.py b/aiogram/types/input_media_video.py index 1a2b5cce..b7479607 100644 --- a/aiogram/types/input_media_video.py +++ b/aiogram/types/input_media_video.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Literal, Optional, Union -from pydantic import Field - from ..enums import InputMediaType from .base import UNSET_PARSE_MODE from .input_media import InputMedia diff --git a/aiogram/types/input_message_content.py b/aiogram/types/input_message_content.py index c331d449..858524a5 100644 --- a/aiogram/types/input_message_content.py +++ b/aiogram/types/input_message_content.py @@ -1,6 +1,6 @@ from __future__ import annotations -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class InputMessageContent(MutableTelegramObject): diff --git a/aiogram/types/keyboard_button.py b/aiogram/types/keyboard_button.py index 6afa0f54..08d4ce37 100644 --- a/aiogram/types/keyboard_button.py +++ b/aiogram/types/keyboard_button.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .keyboard_button_poll_type import KeyboardButtonPollType diff --git a/aiogram/types/keyboard_button_poll_type.py b/aiogram/types/keyboard_button_poll_type.py index c0540ebc..2747adfb 100644 --- a/aiogram/types/keyboard_button_poll_type.py +++ b/aiogram/types/keyboard_button_poll_type.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class KeyboardButtonPollType(MutableTelegramObject): diff --git a/aiogram/types/labeled_price.py b/aiogram/types/labeled_price.py index 9d4c85c9..3dcffb89 100644 --- a/aiogram/types/labeled_price.py +++ b/aiogram/types/labeled_price.py @@ -1,6 +1,6 @@ from __future__ import annotations -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class LabeledPrice(MutableTelegramObject): diff --git a/aiogram/types/menu_button.py b/aiogram/types/menu_button.py index db3bd059..b37c2390 100644 --- a/aiogram/types/menu_button.py +++ b/aiogram/types/menu_button.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .web_app_info import WebAppInfo diff --git a/aiogram/types/menu_button_commands.py b/aiogram/types/menu_button_commands.py index 099f9d5a..e37e48cd 100644 --- a/aiogram/types/menu_button_commands.py +++ b/aiogram/types/menu_button_commands.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from ..enums import MenuButtonType from .menu_button import MenuButton diff --git a/aiogram/types/menu_button_default.py b/aiogram/types/menu_button_default.py index 2bb26731..7b68803e 100644 --- a/aiogram/types/menu_button_default.py +++ b/aiogram/types/menu_button_default.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from ..enums import MenuButtonType from .menu_button import MenuButton diff --git a/aiogram/types/menu_button_web_app.py b/aiogram/types/menu_button_web_app.py index 3fa8857e..ab908afe 100644 --- a/aiogram/types/menu_button_web_app.py +++ b/aiogram/types/menu_button_web_app.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import TYPE_CHECKING, Literal -from pydantic import Field - from ..enums import MenuButtonType from .menu_button import MenuButton diff --git a/aiogram/types/message_entity.py b/aiogram/types/message_entity.py index 161844e0..39773a66 100644 --- a/aiogram/types/message_entity.py +++ b/aiogram/types/message_entity.py @@ -3,7 +3,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, Optional from ..utils.text_decorations import add_surrogates, remove_surrogates -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .user import User diff --git a/aiogram/types/passport_element_error.py b/aiogram/types/passport_element_error.py index 8fcff6c5..36a1db86 100644 --- a/aiogram/types/passport_element_error.py +++ b/aiogram/types/passport_element_error.py @@ -1,6 +1,6 @@ from __future__ import annotations -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject class PassportElementError(MutableTelegramObject): diff --git a/aiogram/types/passport_element_error_data_field.py b/aiogram/types/passport_element_error_data_field.py index ace16328..370a100a 100644 --- a/aiogram/types/passport_element_error_data_field.py +++ b/aiogram/types/passport_element_error_data_field.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_file.py b/aiogram/types/passport_element_error_file.py index 72196b68..e2016dd9 100644 --- a/aiogram/types/passport_element_error_file.py +++ b/aiogram/types/passport_element_error_file.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_files.py b/aiogram/types/passport_element_error_files.py index 5add9547..4b97c095 100644 --- a/aiogram/types/passport_element_error_files.py +++ b/aiogram/types/passport_element_error_files.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import List, Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_front_side.py b/aiogram/types/passport_element_error_front_side.py index 55eecb10..4d46cc94 100644 --- a/aiogram/types/passport_element_error_front_side.py +++ b/aiogram/types/passport_element_error_front_side.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_reverse_side.py b/aiogram/types/passport_element_error_reverse_side.py index 69bc20b8..7584f567 100644 --- a/aiogram/types/passport_element_error_reverse_side.py +++ b/aiogram/types/passport_element_error_reverse_side.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_selfie.py b/aiogram/types/passport_element_error_selfie.py index 08b0a313..37cd1c95 100644 --- a/aiogram/types/passport_element_error_selfie.py +++ b/aiogram/types/passport_element_error_selfie.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_translation_file.py b/aiogram/types/passport_element_error_translation_file.py index b981c691..92b82ad6 100644 --- a/aiogram/types/passport_element_error_translation_file.py +++ b/aiogram/types/passport_element_error_translation_file.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_translation_files.py b/aiogram/types/passport_element_error_translation_files.py index 3fa62191..a9dbece8 100644 --- a/aiogram/types/passport_element_error_translation_files.py +++ b/aiogram/types/passport_element_error_translation_files.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import List, Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/passport_element_error_unspecified.py b/aiogram/types/passport_element_error_unspecified.py index 2df05d45..c287f96c 100644 --- a/aiogram/types/passport_element_error_unspecified.py +++ b/aiogram/types/passport_element_error_unspecified.py @@ -2,8 +2,6 @@ from __future__ import annotations from typing import Literal -from pydantic import Field - from .passport_element_error import PassportElementError diff --git a/aiogram/types/reply_keyboard_markup.py b/aiogram/types/reply_keyboard_markup.py index 0c65c531..da2f6214 100644 --- a/aiogram/types/reply_keyboard_markup.py +++ b/aiogram/types/reply_keyboard_markup.py @@ -2,7 +2,7 @@ from __future__ import annotations from typing import TYPE_CHECKING, List, Optional -from .base import MutableTelegramObject, TelegramObject +from .base import MutableTelegramObject if TYPE_CHECKING: from .keyboard_button import KeyboardButton diff --git a/aiogram/utils/i18n/middleware.py b/aiogram/utils/i18n/middleware.py index 5968cf8a..68be22bc 100644 --- a/aiogram/utils/i18n/middleware.py +++ b/aiogram/utils/i18n/middleware.py @@ -1,5 +1,5 @@ from abc import ABC, abstractmethod -from typing import Any, Awaitable, Callable, Dict, Optional, Set, cast +from typing import Any, Awaitable, Callable, Dict, Optional, Set try: from babel import Locale, UnknownLocaleError