mirror of
https://github.com/aiogram/aiogram.git
synced 2026-04-08 16:37:47 +00:00
Merge branch 'dev-3.x' into scenes
This commit is contained in:
commit
91f804df18
82 changed files with 2311 additions and 1238 deletions
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
emoji_status_expiration_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
expire_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
until_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
until_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
until_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,8 +2,8 @@ annotations:
|
|||
date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
forward_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
close_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,4 +2,4 @@ annotations:
|
|||
start_date:
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
|
|
|
|||
|
|
@ -2,5 +2,5 @@ annotations:
|
|||
last_error_date: &date
|
||||
parsed_type:
|
||||
type: std
|
||||
name: datetime.datetime
|
||||
name: DateTime
|
||||
last_synchronization_error_date: *date
|
||||
|
|
|
|||
2
CHANGES/1277.bugfix.rst
Normal file
2
CHANGES/1277.bugfix.rst
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
Replaced :code:`datetime.datetime` with `DateTime` type wrapper across types to make dumped JSONs object
|
||||
more compatible with data that is sent by Telegram.
|
||||
1
CHANGES/1281.bugfix.rst
Normal file
1
CHANGES/1281.bugfix.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
Fixed magic :code:`.as_(...)` operation for values that can be interpreted as `False` (e.g. `0`).
|
||||
1
CHANGES/1282.bugfix.rst
Normal file
1
CHANGES/1282.bugfix.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
Italic markdown from utils now uses correct decorators
|
||||
1
CHANGES/1284.bugfix.rst
Normal file
1
CHANGES/1284.bugfix.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
Fixed method :code:`Message.send_copy` for stickers.
|
||||
1
CHANGES/1286.bugfix.rst
Normal file
1
CHANGES/1286.bugfix.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
Fixed :code:`Message.send_copy` method, which was not working properly with stories, so not you can copy stories too (forwards messages).
|
||||
1
CHANGES/1290.bugfix.rst
Normal file
1
CHANGES/1290.bugfix.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
Fixed error overlapping when validation error is caused by remove_unset root validator in base types and methods.
|
||||
12
README.rst
12
README.rst
|
|
@ -1,6 +1,6 @@
|
|||
#######################
|
||||
aiogram |version badge|
|
||||
#######################
|
||||
#######
|
||||
aiogram
|
||||
#######
|
||||
|
||||
.. image:: https://img.shields.io/pypi/l/aiogram.svg?style=flat-square
|
||||
:target: https://opensource.org/licenses/MIT
|
||||
|
|
@ -56,7 +56,7 @@ Features
|
|||
- Telegram Bot API integration code was `autogenerated <https://github.com/aiogram/tg-codegen>`_ and can be easily re-generated when API gets updated
|
||||
- Updates router (Blueprints)
|
||||
- Has Finite State Machine
|
||||
- Uses powerful `magic filters <https://docs.aiogram.dev/en/dev-3.x/dispatcher/filters/magic_filters.html#magic-filters>`
|
||||
- Uses powerful `magic filters <https://docs.aiogram.dev/en/latest/dispatcher/filters/magic_filters.html#magic-filters>`_
|
||||
- Middlewares (incoming updates and API calls)
|
||||
- Provides `Replies into Webhook <https://core.telegram.org/bots/faq#how-can-i-make-requests-in-response-to-updates>`_
|
||||
- Integrated I18n/L10n support with GNU Gettext (or Fluent)
|
||||
|
|
@ -78,7 +78,3 @@ Features
|
|||
- 🇮🇷 `@aiogram_fa <https://t.me/aiogram_fa>`_
|
||||
- 🇮🇹 `@aiogram_it <https://t.me/aiogram_it>`_
|
||||
- 🇧🇷 `@aiogram_br <https://t.me/aiogram_br>`_
|
||||
|
||||
|
||||
.. |version badge| image:: https://img.shields.io/badge/-release%20candidate-yellow
|
||||
:alt: Release Candidate badge
|
||||
|
|
|
|||
|
|
@ -1,2 +1,2 @@
|
|||
__version__ = "3.0.0rc2"
|
||||
__version__ = "3.0.0"
|
||||
__api_version__ = "6.8"
|
||||
|
|
|
|||
|
|
@ -61,6 +61,8 @@ class TelegramMethod(BotContextController, BaseModel, Generic[TelegramType], ABC
|
|||
but UNSET might be passing to a model initialization from `Bot.method_name`,
|
||||
so we must take care of it and remove it before fields validation.
|
||||
"""
|
||||
if not isinstance(values, dict):
|
||||
return values
|
||||
return {k: v for k, v in values.items() if not isinstance(v, UNSET_TYPE)}
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@ from .chat_photo import ChatPhoto
|
|||
from .chat_shared import ChatShared
|
||||
from .chosen_inline_result import ChosenInlineResult
|
||||
from .contact import Contact
|
||||
from .custom import DateTime
|
||||
from .dice import Dice
|
||||
from .document import Document
|
||||
from .downloadable import Downloadable
|
||||
|
|
@ -197,6 +198,7 @@ __all__ = (
|
|||
"ChosenInlineResult",
|
||||
"Contact",
|
||||
"ContentType",
|
||||
"DateTime",
|
||||
"Dice",
|
||||
"Document",
|
||||
"Downloadable",
|
||||
|
|
|
|||
|
|
@ -28,6 +28,8 @@ class TelegramObject(BotContextController, BaseModel):
|
|||
but UNSET might be passed to a model initialization from `Bot.method_name`,
|
||||
so we must take care of it and remove it before fields validation.
|
||||
"""
|
||||
if not isinstance(values, dict):
|
||||
return values
|
||||
return {k: v for k, v in values.items() if not isinstance(v, UNSET_TYPE)}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -4,6 +4,7 @@ import datetime
|
|||
from typing import TYPE_CHECKING, Any, List, Optional, Union
|
||||
|
||||
from .base import TelegramObject
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from ..methods import (
|
||||
|
|
@ -33,8 +34,8 @@ if TYPE_CHECKING:
|
|||
UnbanChatMember,
|
||||
UnbanChatSenderChat,
|
||||
UnpinAllChatMessages,
|
||||
UnpinChatMessage,
|
||||
UnpinAllGeneralForumTopicMessages,
|
||||
UnpinChatMessage,
|
||||
)
|
||||
from .chat_location import ChatLocation
|
||||
from .chat_permissions import ChatPermissions
|
||||
|
|
@ -70,7 +71,7 @@ class Chat(TelegramObject):
|
|||
"""*Optional*. If non-empty, the list of all `active chat usernames <https://telegram.org/blog/topics-in-groups-collectible-usernames#collectible-usernames>`_; for private chats, supergroups and channels. Returned only in :class:`aiogram.methods.get_chat.GetChat`."""
|
||||
emoji_status_custom_emoji_id: Optional[str] = None
|
||||
"""*Optional*. Custom emoji identifier of emoji status of the other party in a private chat. Returned only in :class:`aiogram.methods.get_chat.GetChat`."""
|
||||
emoji_status_expiration_date: Optional[datetime.datetime] = None
|
||||
emoji_status_expiration_date: Optional[DateTime] = None
|
||||
"""*Optional*. Expiration date of the emoji status of the other party in a private chat, if any. Returned only in :class:`aiogram.methods.get_chat.GetChat`."""
|
||||
bio: Optional[str] = None
|
||||
"""*Optional*. Bio of the other party in a private chat. Returned only in :class:`aiogram.methods.get_chat.GetChat`."""
|
||||
|
|
@ -126,7 +127,7 @@ class Chat(TelegramObject):
|
|||
photo: Optional[ChatPhoto] = None,
|
||||
active_usernames: Optional[List[str]] = None,
|
||||
emoji_status_custom_emoji_id: Optional[str] = None,
|
||||
emoji_status_expiration_date: Optional[datetime.datetime] = None,
|
||||
emoji_status_expiration_date: Optional[DateTime] = None,
|
||||
bio: Optional[str] = None,
|
||||
has_private_forwards: Optional[bool] = None,
|
||||
has_restricted_voice_and_video_messages: Optional[bool] = None,
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any, Optional
|
||||
|
||||
from .base import TelegramObject
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from .user import User
|
||||
|
|
@ -28,7 +28,7 @@ class ChatInviteLink(TelegramObject):
|
|||
""":code:`True`, if the link is revoked"""
|
||||
name: Optional[str] = None
|
||||
"""*Optional*. Invite link name"""
|
||||
expire_date: Optional[datetime.datetime] = None
|
||||
expire_date: Optional[DateTime] = None
|
||||
"""*Optional*. Point in time (Unix timestamp) when the link will expire or has been expired"""
|
||||
member_limit: Optional[int] = None
|
||||
"""*Optional*. The maximum number of users that can be members of the chat simultaneously after joining the chat via this invite link; 1-99999"""
|
||||
|
|
@ -48,7 +48,7 @@ class ChatInviteLink(TelegramObject):
|
|||
is_primary: bool,
|
||||
is_revoked: bool,
|
||||
name: Optional[str] = None,
|
||||
expire_date: Optional[datetime.datetime] = None,
|
||||
expire_date: Optional[DateTime] = None,
|
||||
member_limit: Optional[int] = None,
|
||||
pending_join_request_count: Optional[int] = None,
|
||||
**__pydantic_kwargs: Any,
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ from .base import (
|
|||
UNSET_PROTECT_CONTENT,
|
||||
TelegramObject,
|
||||
)
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from ..methods import (
|
||||
|
|
@ -63,7 +64,7 @@ class ChatJoinRequest(TelegramObject):
|
|||
"""User that sent the join request"""
|
||||
user_chat_id: int
|
||||
"""Identifier of a private chat with the user who sent the join request. This number may have more than 32 significant bits and some programming languages may have difficulty/silent defects in interpreting it. But it has at most 52 significant bits, so a 64-bit integer or double-precision float type are safe for storing this identifier. The bot can use this identifier for 24 hours to send messages until the join request is processed, assuming no other administrator contacted the user."""
|
||||
date: datetime.datetime
|
||||
date: DateTime
|
||||
"""Date the request was sent in Unix time"""
|
||||
bio: Optional[str] = None
|
||||
"""*Optional*. Bio of the user."""
|
||||
|
|
@ -80,7 +81,7 @@ class ChatJoinRequest(TelegramObject):
|
|||
chat: Chat,
|
||||
from_user: User,
|
||||
user_chat_id: int,
|
||||
date: datetime.datetime,
|
||||
date: DateTime,
|
||||
bio: Optional[str] = None,
|
||||
invite_link: Optional[ChatInviteLink] = None,
|
||||
**__pydantic_kwargs: Any,
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any, Literal
|
||||
|
||||
from ..enums import ChatMemberStatus
|
||||
from .chat_member import ChatMember
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from .user import User
|
||||
|
|
@ -21,7 +21,7 @@ class ChatMemberBanned(ChatMember):
|
|||
"""The member's status in the chat, always 'kicked'"""
|
||||
user: User
|
||||
"""Information about the user"""
|
||||
until_date: datetime.datetime
|
||||
until_date: DateTime
|
||||
"""Date when restrictions will be lifted for this user; unix time. If 0, then the user is banned forever"""
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
@ -33,7 +33,7 @@ class ChatMemberBanned(ChatMember):
|
|||
*,
|
||||
status: Literal[ChatMemberStatus.KICKED] = ChatMemberStatus.KICKED,
|
||||
user: User,
|
||||
until_date: datetime.datetime,
|
||||
until_date: DateTime,
|
||||
**__pydantic_kwargs: Any,
|
||||
) -> None:
|
||||
# DO NOT EDIT MANUALLY!!!
|
||||
|
|
|
|||
|
|
@ -1,10 +1,10 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any, Literal
|
||||
|
||||
from ..enums import ChatMemberStatus
|
||||
from .chat_member import ChatMember
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from .user import User
|
||||
|
|
@ -51,7 +51,7 @@ class ChatMemberRestricted(ChatMember):
|
|||
""":code:`True`, if the user is allowed to pin messages"""
|
||||
can_manage_topics: bool
|
||||
""":code:`True`, if the user is allowed to create forum topics"""
|
||||
until_date: datetime.datetime
|
||||
until_date: DateTime
|
||||
"""Date when restrictions will be lifted for this user; unix time. If 0, then the user is restricted forever"""
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
@ -78,7 +78,7 @@ class ChatMemberRestricted(ChatMember):
|
|||
can_invite_users: bool,
|
||||
can_pin_messages: bool,
|
||||
can_manage_topics: bool,
|
||||
until_date: datetime.datetime,
|
||||
until_date: DateTime,
|
||||
**__pydantic_kwargs: Any,
|
||||
) -> None:
|
||||
# DO NOT EDIT MANUALLY!!!
|
||||
|
|
|
|||
|
|
@ -11,6 +11,7 @@ from .base import (
|
|||
UNSET_PROTECT_CONTENT,
|
||||
TelegramObject,
|
||||
)
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from ..methods import (
|
||||
|
|
@ -65,7 +66,7 @@ class ChatMemberUpdated(TelegramObject):
|
|||
"""Chat the user belongs to"""
|
||||
from_user: User = Field(..., alias="from")
|
||||
"""Performer of the action, which resulted in the change"""
|
||||
date: datetime.datetime
|
||||
date: DateTime
|
||||
"""Date the change was done in Unix time"""
|
||||
old_chat_member: Union[
|
||||
ChatMemberOwner,
|
||||
|
|
@ -99,7 +100,7 @@ class ChatMemberUpdated(TelegramObject):
|
|||
*,
|
||||
chat: Chat,
|
||||
from_user: User,
|
||||
date: datetime.datetime,
|
||||
date: DateTime,
|
||||
old_chat_member: Union[
|
||||
ChatMemberOwner,
|
||||
ChatMemberAdministrator,
|
||||
|
|
|
|||
14
aiogram/types/custom.py
Normal file
14
aiogram/types/custom.py
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
from datetime import datetime
|
||||
|
||||
from pydantic import PlainSerializer
|
||||
from typing_extensions import Annotated
|
||||
|
||||
# Make datetime compatible with Telegram Bot API (unixtime)
|
||||
DateTime = Annotated[
|
||||
datetime,
|
||||
PlainSerializer(
|
||||
func=lambda dt: int(dt.timestamp()),
|
||||
return_type=int,
|
||||
when_used="json-unless-none",
|
||||
),
|
||||
]
|
||||
|
|
@ -18,6 +18,7 @@ from .base import (
|
|||
UNSET_PROTECT_CONTENT,
|
||||
TelegramObject,
|
||||
)
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from ..methods import (
|
||||
|
|
@ -109,7 +110,7 @@ class Message(TelegramObject):
|
|||
|
||||
message_id: int
|
||||
"""Unique message identifier inside this chat"""
|
||||
date: datetime.datetime
|
||||
date: DateTime
|
||||
"""Date the message was sent in Unix time"""
|
||||
chat: Chat
|
||||
"""Conversation the message belongs to"""
|
||||
|
|
@ -129,7 +130,7 @@ class Message(TelegramObject):
|
|||
"""*Optional*. For forwarded messages that were originally sent in channels or by an anonymous chat administrator, signature of the message sender if present"""
|
||||
forward_sender_name: Optional[str] = None
|
||||
"""*Optional*. Sender's name for messages forwarded from users who disallow adding a link to their account in forwarded messages"""
|
||||
forward_date: Optional[datetime.datetime] = None
|
||||
forward_date: Optional[DateTime] = None
|
||||
"""*Optional*. For forwarded messages, date the original message was sent in Unix time"""
|
||||
is_topic_message: Optional[bool] = None
|
||||
"""*Optional*. :code:`True`, if the message is sent to a forum topic"""
|
||||
|
|
@ -260,7 +261,7 @@ class Message(TelegramObject):
|
|||
__pydantic__self__,
|
||||
*,
|
||||
message_id: int,
|
||||
date: datetime.datetime,
|
||||
date: DateTime,
|
||||
chat: Chat,
|
||||
message_thread_id: Optional[int] = None,
|
||||
from_user: Optional[User] = None,
|
||||
|
|
@ -270,7 +271,7 @@ class Message(TelegramObject):
|
|||
forward_from_message_id: Optional[int] = None,
|
||||
forward_signature: Optional[str] = None,
|
||||
forward_sender_name: Optional[str] = None,
|
||||
forward_date: Optional[datetime.datetime] = None,
|
||||
forward_date: Optional[DateTime] = None,
|
||||
is_topic_message: Optional[bool] = None,
|
||||
is_automatic_forward: Optional[bool] = None,
|
||||
reply_to_message: Optional[Message] = None,
|
||||
|
|
@ -2803,6 +2804,7 @@ class Message(TelegramObject):
|
|||
allow_sending_without_reply: Optional[bool] = None,
|
||||
message_thread_id: Optional[int] = None,
|
||||
) -> Union[
|
||||
ForwardMessage,
|
||||
SendAnimation,
|
||||
SendAudio,
|
||||
SendContact,
|
||||
|
|
@ -2838,6 +2840,7 @@ class Message(TelegramObject):
|
|||
:return:
|
||||
"""
|
||||
from ..methods import (
|
||||
ForwardMessage,
|
||||
SendAnimation,
|
||||
SendAudio,
|
||||
SendContact,
|
||||
|
|
@ -2864,7 +2867,11 @@ class Message(TelegramObject):
|
|||
}
|
||||
|
||||
if self.text:
|
||||
return SendMessage(text=self.text, entities=self.entities, **kwargs).as_(self._bot)
|
||||
return SendMessage(
|
||||
text=self.text,
|
||||
entities=self.entities,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.audio:
|
||||
return SendAudio(
|
||||
audio=self.audio.file_id,
|
||||
|
|
@ -2897,7 +2904,10 @@ class Message(TelegramObject):
|
|||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.sticker:
|
||||
return SendSticker(sticker=self.sticker.file_id, **kwargs)
|
||||
return SendSticker(
|
||||
sticker=self.sticker.file_id,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.video:
|
||||
return SendVideo(
|
||||
video=self.video.file_id,
|
||||
|
|
@ -2906,9 +2916,15 @@ class Message(TelegramObject):
|
|||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.video_note:
|
||||
return SendVideoNote(video_note=self.video_note.file_id, **kwargs).as_(self._bot)
|
||||
return SendVideoNote(
|
||||
video_note=self.video_note.file_id,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.voice:
|
||||
return SendVoice(voice=self.voice.file_id, **kwargs).as_(self._bot)
|
||||
return SendVoice(
|
||||
voice=self.voice.file_id,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.contact:
|
||||
return SendContact(
|
||||
phone_number=self.contact.phone_number,
|
||||
|
|
@ -2929,7 +2945,9 @@ class Message(TelegramObject):
|
|||
).as_(self._bot)
|
||||
if self.location:
|
||||
return SendLocation(
|
||||
latitude=self.location.latitude, longitude=self.location.longitude, **kwargs
|
||||
latitude=self.location.latitude,
|
||||
longitude=self.location.longitude,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.poll:
|
||||
return SendPoll(
|
||||
|
|
@ -2938,7 +2956,15 @@ class Message(TelegramObject):
|
|||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.dice: # Dice value can't be controlled
|
||||
return SendDice(**kwargs).as_(self._bot)
|
||||
return SendDice(
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
if self.story:
|
||||
return ForwardMessage(
|
||||
from_chat_id=self.chat.id,
|
||||
message_id=self.message_id,
|
||||
**kwargs,
|
||||
).as_(self._bot)
|
||||
|
||||
raise TypeError("This type of message can't be copied.")
|
||||
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any, List, Optional
|
||||
|
||||
from .base import TelegramObject
|
||||
from .custom import DateTime
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from .message_entity import MessageEntity
|
||||
|
|
@ -41,7 +41,7 @@ class Poll(TelegramObject):
|
|||
"""*Optional*. Special entities like usernames, URLs, bot commands, etc. that appear in the *explanation*"""
|
||||
open_period: Optional[int] = None
|
||||
"""*Optional*. Amount of time in seconds the poll will be active after creation"""
|
||||
close_date: Optional[datetime.datetime] = None
|
||||
close_date: Optional[DateTime] = None
|
||||
"""*Optional*. Point in time (Unix timestamp) when the poll will be automatically closed"""
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
@ -63,7 +63,7 @@ class Poll(TelegramObject):
|
|||
explanation: Optional[str] = None,
|
||||
explanation_entities: Optional[List[MessageEntity]] = None,
|
||||
open_period: Optional[int] = None,
|
||||
close_date: Optional[datetime.datetime] = None,
|
||||
close_date: Optional[DateTime] = None,
|
||||
**__pydantic_kwargs: Any,
|
||||
) -> None:
|
||||
# DO NOT EDIT MANUALLY!!!
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any
|
||||
|
||||
from .base import TelegramObject
|
||||
from .custom import DateTime
|
||||
|
||||
|
||||
class VideoChatScheduled(TelegramObject):
|
||||
|
|
@ -13,7 +13,7 @@ class VideoChatScheduled(TelegramObject):
|
|||
Source: https://core.telegram.org/bots/api#videochatscheduled
|
||||
"""
|
||||
|
||||
start_date: datetime.datetime
|
||||
start_date: DateTime
|
||||
"""Point in time (Unix timestamp) when the video chat is supposed to be started by a chat administrator"""
|
||||
|
||||
if TYPE_CHECKING:
|
||||
|
|
@ -21,7 +21,7 @@ class VideoChatScheduled(TelegramObject):
|
|||
# This section was auto-generated via `butcher`
|
||||
|
||||
def __init__(
|
||||
__pydantic__self__, *, start_date: datetime.datetime, **__pydantic_kwargs: Any
|
||||
__pydantic__self__, *, start_date: DateTime, **__pydantic_kwargs: Any
|
||||
) -> None:
|
||||
# DO NOT EDIT MANUALLY!!!
|
||||
# This method was auto-generated via `butcher`
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
from __future__ import annotations
|
||||
|
||||
import datetime
|
||||
from typing import TYPE_CHECKING, Any, List, Optional
|
||||
|
||||
from .base import TelegramObject
|
||||
from .custom import DateTime
|
||||
|
||||
|
||||
class WebhookInfo(TelegramObject):
|
||||
|
|
@ -21,11 +21,11 @@ class WebhookInfo(TelegramObject):
|
|||
"""Number of updates awaiting delivery"""
|
||||
ip_address: Optional[str] = None
|
||||
"""*Optional*. Currently used webhook IP address"""
|
||||
last_error_date: Optional[datetime.datetime] = None
|
||||
last_error_date: Optional[DateTime] = None
|
||||
"""*Optional*. Unix time for the most recent error that happened when trying to deliver an update via webhook"""
|
||||
last_error_message: Optional[str] = None
|
||||
"""*Optional*. Error message in human-readable format for the most recent error that happened when trying to deliver an update via webhook"""
|
||||
last_synchronization_error_date: Optional[datetime.datetime] = None
|
||||
last_synchronization_error_date: Optional[DateTime] = None
|
||||
"""*Optional*. Unix time of the most recent error that happened when trying to synchronize available updates with Telegram datacenters"""
|
||||
max_connections: Optional[int] = None
|
||||
"""*Optional*. The maximum allowed number of simultaneous HTTPS connections to the webhook for update delivery"""
|
||||
|
|
@ -43,9 +43,9 @@ class WebhookInfo(TelegramObject):
|
|||
has_custom_certificate: bool,
|
||||
pending_update_count: int,
|
||||
ip_address: Optional[str] = None,
|
||||
last_error_date: Optional[datetime.datetime] = None,
|
||||
last_error_date: Optional[DateTime] = None,
|
||||
last_error_message: Optional[str] = None,
|
||||
last_synchronization_error_date: Optional[datetime.datetime] = None,
|
||||
last_synchronization_error_date: Optional[DateTime] = None,
|
||||
max_connections: Optional[int] = None,
|
||||
allowed_updates: Optional[List[str]] = None,
|
||||
**__pydantic_kwargs: Any,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
from typing import Any
|
||||
from typing import Any, Iterable
|
||||
|
||||
from magic_filter import MagicFilter as _MagicFilter
|
||||
from magic_filter import MagicT as _MagicT
|
||||
|
|
@ -12,7 +12,7 @@ class AsFilterResultOperation(BaseOperation):
|
|||
self.name = name
|
||||
|
||||
def resolve(self, value: Any, initial_value: Any) -> Any:
|
||||
if not value:
|
||||
if value is None or (isinstance(value, Iterable) and not value):
|
||||
return None
|
||||
return {self.name: value}
|
||||
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ def italic(*content: Any, sep: str = " ") -> str:
|
|||
:param sep:
|
||||
:return:
|
||||
"""
|
||||
return markdown_decoration.italic(value=html_decoration.quote(_join(*content, sep=sep)))
|
||||
return markdown_decoration.italic(value=markdown_decoration.quote(_join(*content, sep=sep)))
|
||||
|
||||
|
||||
def hitalic(*content: Any, sep: str = " ") -> str:
|
||||
|
|
|
|||
|
|
@ -4,14 +4,14 @@ Dispatcher
|
|||
|
||||
Dispatcher is root :obj:`Router` and in code Dispatcher can be used directly for routing updates or attach another routers into dispatcher.
|
||||
|
||||
Here is only listed base information about Dispatcher. All about writing handlers, filters and etc. you can found in next pages:
|
||||
Here is only listed base information about Dispatcher. All about writing handlers, filters and etc. you can find in next pages:
|
||||
|
||||
- `Router <router.html>`__
|
||||
- `Observer <observer.html>`__
|
||||
- :ref:`Router <Router>`
|
||||
- :ref:`Filtering events`
|
||||
|
||||
|
||||
.. autoclass:: aiogram.dispatcher.dispatcher.Dispatcher
|
||||
:members: __init__, feed_update, feed_raw_update, feed_webhook_update, start_polling, run_polling
|
||||
:members: __init__, feed_update, feed_raw_update, feed_webhook_update, start_polling, run_polling, stop_polling
|
||||
|
||||
|
||||
Simple usage
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
.. _callback-data-factory
|
||||
.. _Callback data factory:
|
||||
|
||||
==============================
|
||||
Callback Data Factory & Filter
|
||||
|
|
|
|||
|
|
@ -2,6 +2,27 @@
|
|||
ChatMemberUpdated
|
||||
=================
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Handle user leave or join events
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
from aiogram.filters import IS_MEMBER, IS_NOT_MEMBER
|
||||
|
||||
@router.chat_member(ChatMemberUpdatedFilter(IS_MEMBER >> IS_NOT_MEMBER))
|
||||
async def on_user_leave(event: ChatMemberUpdated): ...
|
||||
|
||||
@router.chat_member(ChatMemberUpdatedFilter(IS_NOT_MEMBER >> IS_MEMBER))
|
||||
async def on_user_join(event: ChatMemberUpdated): ...
|
||||
|
||||
Or construct your own terms via using pre-defined set of statuses and transitions.
|
||||
|
||||
|
||||
Explanation
|
||||
===========
|
||||
|
||||
.. autoclass:: aiogram.filters.chat_member_updated.ChatMemberUpdatedFilter
|
||||
:members:
|
||||
:member-order: bysource
|
||||
|
|
@ -77,22 +98,6 @@ will produce swap of old and new statuses.
|
|||
Note that if you define the status unions (via :code:`|`) you will need to add brackets for the statement
|
||||
before use shift operator in due to operator priorities.
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
Handle user leave or join events
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
from aiogram.filters import IS_MEMBER, IS_NOT_MEMBER
|
||||
|
||||
@router.chat_member(ChatMemberUpdatedFilter(IS_MEMBER >> IS_NOT_MEMBER))
|
||||
async def on_user_leave(event: ChatMemberUpdated): ...
|
||||
|
||||
@router.chat_member(ChatMemberUpdatedFilter(IS_NOT_MEMBER >> IS_MEMBER))
|
||||
async def on_user_join(event: ChatMemberUpdated): ...
|
||||
|
||||
Or construct your own terms via using pre-defined set of statuses and transitions.
|
||||
|
||||
Allowed handlers
|
||||
================
|
||||
|
|
|
|||
|
|
@ -2,19 +2,6 @@
|
|||
Command
|
||||
=======
|
||||
|
||||
.. autoclass:: aiogram.filters.command.Command
|
||||
:members: __init__
|
||||
:member-order: bysource
|
||||
:undoc-members: False
|
||||
|
||||
When filter is passed the :class:`aiogram.filters.command.CommandObject` will be passed to the handler argument :code:`command`
|
||||
|
||||
.. autoclass:: aiogram.filters.command.CommandObject
|
||||
:members:
|
||||
:member-order: bysource
|
||||
:undoc-members: False
|
||||
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
|
|
@ -28,6 +15,19 @@ Usage
|
|||
|
||||
Command cannot include spaces or any whitespace
|
||||
|
||||
|
||||
.. autoclass:: aiogram.filters.command.Command
|
||||
:members: __init__
|
||||
:member-order: bysource
|
||||
:undoc-members: False
|
||||
|
||||
When filter is passed the :class:`aiogram.filters.command.CommandObject` will be passed to the handler argument :code:`command`
|
||||
|
||||
.. autoclass:: aiogram.filters.command.CommandObject
|
||||
:members:
|
||||
:member-order: bysource
|
||||
:undoc-members: False
|
||||
|
||||
Allowed handlers
|
||||
================
|
||||
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
.. _Filtering events:
|
||||
|
||||
================
|
||||
Filtering events
|
||||
================
|
||||
|
|
|
|||
|
|
@ -2,6 +2,14 @@
|
|||
MagicData
|
||||
=========
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
#. :code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Note that :code:`config` should be passed from middleware)
|
||||
|
||||
Explanation
|
||||
===========
|
||||
|
||||
.. autoclass:: aiogram.filters.magic_data.MagicData
|
||||
:members:
|
||||
:member-order: bysource
|
||||
|
|
@ -11,11 +19,6 @@ Can be imported:
|
|||
|
||||
- :code:`from aiogram.filters import MagicData`
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
#. :code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Note that :code:`config` should be passed from middleware)
|
||||
|
||||
|
||||
Allowed handlers
|
||||
================
|
||||
|
|
|
|||
|
|
@ -1,3 +1,5 @@
|
|||
.. _Finite State Machine:
|
||||
|
||||
====================
|
||||
Finite State Machine
|
||||
====================
|
||||
|
|
|
|||
|
|
@ -26,12 +26,12 @@ So, you can use both of them with *aiogram*.
|
|||
|
||||
router
|
||||
dispatcher
|
||||
class_based_handlers/index
|
||||
dependency_injection
|
||||
filters/index
|
||||
middlewares
|
||||
finite_state_machine/index
|
||||
flags
|
||||
errors
|
||||
long_polling
|
||||
webhook
|
||||
dependency_injection
|
||||
finite_state_machine/index
|
||||
middlewares
|
||||
errors
|
||||
flags
|
||||
class_based_handlers/index
|
||||
|
|
|
|||
|
|
@ -1,7 +1,23 @@
|
|||
.. _Router:
|
||||
|
||||
######
|
||||
Router
|
||||
######
|
||||
|
||||
Usage:
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
from aiogram import Router
|
||||
from aiogram.types import Message
|
||||
|
||||
my_router = Router(name=__name__)
|
||||
|
||||
@my_router.message()
|
||||
async def message_handler(message: Message) -> Any:
|
||||
await message.answer('Hello from my router!')
|
||||
|
||||
|
||||
.. autoclass:: aiogram.dispatcher.router.Router
|
||||
:members: __init__, include_router, include_routers, resolve_used_update_types
|
||||
:show-inheritance:
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ From PyPI
|
|||
|
||||
.. code-block:: bash
|
||||
|
||||
pip install -U --pre aiogram
|
||||
pip install -U aiogram
|
||||
|
||||
From GitHub
|
||||
-----------
|
||||
|
|
|
|||
|
|
@ -0,0 +1,94 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:3
|
||||
msgid "unpinAllGeneralForumTopicMessages"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:5
|
||||
msgid "Returns: :obj:`bool`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages:1
|
||||
#: of
|
||||
msgid ""
|
||||
"Use this method to clear the list of pinned messages in a General forum "
|
||||
"topic. The bot must be an administrator in the chat for this to work and "
|
||||
"must have the *can_pin_messages* administrator right in the supergroup. "
|
||||
"Returns :code:`True` on success."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages:3
|
||||
#: of
|
||||
msgid ""
|
||||
"Source: "
|
||||
"https://core.telegram.org/bots/api#unpinallgeneralforumtopicmessages"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages.chat_id:1
|
||||
#: of
|
||||
msgid ""
|
||||
"Unique identifier for the target chat or username of the target "
|
||||
"supergroup (in the format :code:`@supergroupusername`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:15
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:18
|
||||
msgid "As bot method"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:26
|
||||
msgid "Method as object"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:28
|
||||
msgid "Imports:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:30
|
||||
msgid ""
|
||||
":code:`from aiogram.methods.unpin_all_general_forum_topic_messages import"
|
||||
" UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:31
|
||||
msgid ""
|
||||
"alias: :code:`from aiogram.methods import "
|
||||
"UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:34
|
||||
msgid "With specific bot"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:41
|
||||
msgid "As reply into Webhook in handler"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:49
|
||||
msgid "As shortcut from received object"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:51
|
||||
msgid ":meth:`aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages`"
|
||||
msgstr ""
|
||||
|
|
@ -8,14 +8,14 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-03-11 01:52+0200\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.11.0\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/chat.rst:3
|
||||
msgid "Chat"
|
||||
|
|
@ -88,6 +88,13 @@ msgid ""
|
|||
":class:`aiogram.methods.get_chat.GetChat`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.chat.Chat.emoji_status_expiration_date:1 of
|
||||
msgid ""
|
||||
"*Optional*. Expiration date of the emoji status of the other party in a "
|
||||
"private chat, if any. Returned only in "
|
||||
":class:`aiogram.methods.get_chat.GetChat`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.chat.Chat.bio:1 of
|
||||
msgid ""
|
||||
"*Optional*. Bio of the other party in a private chat. Returned only in "
|
||||
|
|
@ -264,6 +271,7 @@ msgstr ""
|
|||
#: aiogram.types.chat.Chat.set_sticker_set:4
|
||||
#: aiogram.types.chat.Chat.set_title:4 aiogram.types.chat.Chat.unban:4
|
||||
#: aiogram.types.chat.Chat.unban_sender_chat:4
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:4
|
||||
#: aiogram.types.chat.Chat.unpin_all_messages:4
|
||||
#: aiogram.types.chat.Chat.unpin_message:4 of
|
||||
msgid ":code:`chat_id`"
|
||||
|
|
@ -320,6 +328,7 @@ msgstr ""
|
|||
#: aiogram.types.chat.Chat.set_permissions aiogram.types.chat.Chat.set_photo
|
||||
#: aiogram.types.chat.Chat.set_sticker_set aiogram.types.chat.Chat.set_title
|
||||
#: aiogram.types.chat.Chat.unban aiogram.types.chat.Chat.unban_sender_chat
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages
|
||||
#: aiogram.types.chat.Chat.unpin_all_messages
|
||||
#: aiogram.types.chat.Chat.unpin_message of
|
||||
msgid "Returns"
|
||||
|
|
@ -1269,6 +1278,33 @@ msgstr ""
|
|||
msgid "instance of method :class:`aiogram.methods.set_chat_photo.SetChatPhoto`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:1 of
|
||||
msgid ""
|
||||
"Shortcut for method "
|
||||
":class:`aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages`"
|
||||
" will automatically fill method attributes:"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:6 of
|
||||
msgid ""
|
||||
"Use this method to clear the list of pinned messages in a General forum "
|
||||
"topic. The bot must be an administrator in the chat for this to work and "
|
||||
"must have the *can_pin_messages* administrator right in the supergroup. "
|
||||
"Returns :code:`True` on success."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:8 of
|
||||
msgid ""
|
||||
"Source: "
|
||||
"https://core.telegram.org/bots/api#unpinallgeneralforumtopicmessages"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:10 of
|
||||
msgid ""
|
||||
"instance of method "
|
||||
":class:`aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Use this method to get information "
|
||||
#~ "about a member of a chat. The "
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-06 16:52+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -173,6 +173,10 @@ msgstr ""
|
|||
msgid "*Optional*. Message is a sticker, information about the sticker"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.message.Message.story:1 of
|
||||
msgid "*Optional*. Message is a forwarded story"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.message.Message.video:1 of
|
||||
msgid "*Optional*. Message is a video, information about the video"
|
||||
msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,14 +8,14 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-01 22:51+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/poll_answer.rst:3
|
||||
msgid "PollAnswer"
|
||||
|
|
@ -33,12 +33,29 @@ msgstr ""
|
|||
msgid "Unique poll identifier"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.user:1 of
|
||||
msgid "The user, who changed the answer to the poll"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.option_ids:1 of
|
||||
msgid ""
|
||||
"0-based identifiers of answer options, chosen by the user. May be empty "
|
||||
"if the user retracted their vote."
|
||||
"0-based identifiers of chosen answer options. May be empty if the vote "
|
||||
"was retracted."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.voter_chat:1 of
|
||||
msgid ""
|
||||
"*Optional*. The chat that changed the answer to the poll, if the voter is"
|
||||
" anonymous"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.user:1 of
|
||||
msgid ""
|
||||
"*Optional*. The user that changed the answer to the poll, if the voter "
|
||||
"isn't anonymous"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "The user, who changed the answer to the poll"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "0-based identifiers of answer options, "
|
||||
#~ "chosen by the user. May be empty"
|
||||
#~ " if the user retracted their vote."
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
32
docs/locale/en/LC_MESSAGES/api/types/story.po
Normal file
32
docs/locale/en/LC_MESSAGES/api/types/story.po
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/story.rst:3
|
||||
msgid "Story"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.story.Story:1 of
|
||||
msgid ""
|
||||
"This object represents a message about a forwarded story in the chat. "
|
||||
"Currently holds no information."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.story.Story:3 of
|
||||
msgid "Source: https://core.telegram.org/bots/api#story"
|
||||
msgstr ""
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -78,112 +78,112 @@ msgstr ""
|
|||
msgid "Activate the environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:38
|
||||
msgid "Linux/ macOS:"
|
||||
#: ../../contributing.rst:38 ../../contributing.rst:77
|
||||
msgid "Linux / macOS:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:44
|
||||
msgid "Windows PoweShell"
|
||||
msgid "Windows cmd"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:50
|
||||
msgid ""
|
||||
"To check it worked, use described command, it should show the :code:`pip`"
|
||||
" location inside the isolated environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:53
|
||||
msgid "Linux, macOS:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:59
|
||||
msgid "Windows PowerShell"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:65
|
||||
#: ../../contributing.rst:56
|
||||
msgid ""
|
||||
"Also make you shure you have the latest pip version in your virtual "
|
||||
"To check it worked, use described command, it should show the :code:`pip`"
|
||||
" version and location inside the isolated environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:64
|
||||
msgid ""
|
||||
"Also make sure you have the latest pip version in your virtual "
|
||||
"environment to avoid errors on next steps:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:74
|
||||
#: ../../contributing.rst:73
|
||||
msgid "Setup project"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:76
|
||||
#: ../../contributing.rst:75
|
||||
msgid ""
|
||||
"After activating the environment install `aiogram` from sources and their"
|
||||
" dependencies:"
|
||||
" dependencies."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:82
|
||||
#: ../../contributing.rst:83
|
||||
msgid "Windows:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:89
|
||||
msgid ""
|
||||
"It will install :code:`aiogram` in editable mode into your virtual "
|
||||
"environment and all dependencies."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:85
|
||||
#: ../../contributing.rst:92
|
||||
msgid "Making changes in code"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:87
|
||||
#: ../../contributing.rst:94
|
||||
msgid ""
|
||||
"At this point you can make any changes in the code that you want, it can "
|
||||
"be any fixes, implementing new features or experimenting."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:92
|
||||
#: ../../contributing.rst:99
|
||||
msgid "Format the code (code-style)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:94
|
||||
#: ../../contributing.rst:101
|
||||
msgid ""
|
||||
"Note that this project is Black-formatted, so you should follow that "
|
||||
"code-style, too be sure You're correctly doing this let's reformat the "
|
||||
"code automatically:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:104
|
||||
#: ../../contributing.rst:111
|
||||
msgid "Run tests"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:106
|
||||
#: ../../contributing.rst:113
|
||||
msgid "All changes should be tested:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:112
|
||||
#: ../../contributing.rst:119
|
||||
msgid ""
|
||||
"Also if you are doing something with Redis-storage, you will need to test"
|
||||
" everything works with Redis:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:119
|
||||
#: ../../contributing.rst:126
|
||||
msgid "Docs"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:121
|
||||
#: ../../contributing.rst:128
|
||||
msgid ""
|
||||
"We are using `Sphinx` to render docs in different languages, all sources "
|
||||
"located in `docs` directory, you can change the sources and to test it "
|
||||
"you can start live-preview server and look what you are doing:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:130
|
||||
#: ../../contributing.rst:137
|
||||
msgid "Docs translations"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:132
|
||||
#: ../../contributing.rst:139
|
||||
msgid ""
|
||||
"Translation of the documentation is very necessary and cannot be done "
|
||||
"without the help of the community from all over the world, so you are "
|
||||
"welcome to translate the documentation into different languages."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:136
|
||||
#: ../../contributing.rst:143
|
||||
msgid "Before start, let's up to date all texts:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:144
|
||||
#: ../../contributing.rst:151
|
||||
msgid ""
|
||||
"Change the :code:`<language_code>` in example below to the target "
|
||||
"language code, after that you can modify texts inside "
|
||||
|
|
@ -192,120 +192,120 @@ msgid ""
|
|||
"example via `poedit <https://poedit.net/>`_."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:149
|
||||
#: ../../contributing.rst:156
|
||||
msgid "To view results:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:157
|
||||
#: ../../contributing.rst:164
|
||||
msgid "Describe changes"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:159
|
||||
#: ../../contributing.rst:166
|
||||
msgid ""
|
||||
"Describe your changes in one or more sentences so that bot developers "
|
||||
"know what's changed in their favorite framework - create "
|
||||
"`<code>.<category>.rst` file and write the description."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:162
|
||||
#: ../../contributing.rst:169
|
||||
msgid ""
|
||||
":code:`<code>` is Issue or Pull-request number, after release link to "
|
||||
"this issue will be published to the *Changelog* page."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:165
|
||||
#: ../../contributing.rst:172
|
||||
msgid ":code:`<category>` is a changes category marker, it can be one of:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:167
|
||||
#: ../../contributing.rst:174
|
||||
msgid ":code:`feature` - when you are implementing new feature"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:168
|
||||
#: ../../contributing.rst:175
|
||||
msgid ":code:`bugfix` - when you fix a bug"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:169
|
||||
#: ../../contributing.rst:176
|
||||
msgid ":code:`doc` - when you improve the docs"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:170
|
||||
#: ../../contributing.rst:177
|
||||
msgid ":code:`removal` - when you remove something from the framework"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:171
|
||||
#: ../../contributing.rst:178
|
||||
msgid ""
|
||||
":code:`misc` - when changed something inside the Core or project "
|
||||
"configuration"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:173
|
||||
#: ../../contributing.rst:180
|
||||
msgid ""
|
||||
"If you have troubles with changing category feel free to ask Core-"
|
||||
"contributors to help with choosing it."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:176
|
||||
#: ../../contributing.rst:183
|
||||
msgid "Complete"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:178
|
||||
#: ../../contributing.rst:185
|
||||
msgid ""
|
||||
"After you have made all your changes, publish them to the repository and "
|
||||
"create a pull request as mentioned at the beginning of the article and "
|
||||
"wait for a review of these changes."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:183
|
||||
#: ../../contributing.rst:190
|
||||
msgid "Star on GitHub"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:185
|
||||
#: ../../contributing.rst:192
|
||||
msgid ""
|
||||
"You can \"star\" repository on GitHub - "
|
||||
"https://github.com/aiogram/aiogram (click the star button at the top "
|
||||
"right)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:187
|
||||
#: ../../contributing.rst:194
|
||||
msgid ""
|
||||
"Adding stars makes it easier for other people to find this project and "
|
||||
"understand how useful it is."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:190
|
||||
#: ../../contributing.rst:197
|
||||
msgid "Guides"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:192
|
||||
#: ../../contributing.rst:199
|
||||
msgid ""
|
||||
"You can write guides how to develop Bots on top of aiogram and publish it"
|
||||
" into YouTube, Medium, GitHub Books, any Courses platform or any other "
|
||||
"platform that you know."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:195
|
||||
#: ../../contributing.rst:202
|
||||
msgid ""
|
||||
"This will help more people learn about the framework and learn how to use"
|
||||
" it"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:199
|
||||
#: ../../contributing.rst:206
|
||||
msgid "Take answers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:201
|
||||
#: ../../contributing.rst:208
|
||||
msgid ""
|
||||
"The developers is always asks for any question in our chats or any other "
|
||||
"platforms like GitHub Discussions, StackOverflow and others, feel free to"
|
||||
" answer to this questions."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:205
|
||||
#: ../../contributing.rst:212
|
||||
msgid "Funding"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:207
|
||||
#: ../../contributing.rst:214
|
||||
msgid ""
|
||||
"The development of the project is free and not financed by commercial "
|
||||
"organizations, it is my personal initiative (`@JRootJunior "
|
||||
|
|
@ -313,7 +313,7 @@ msgid ""
|
|||
"project in my free time."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:211
|
||||
#: ../../contributing.rst:218
|
||||
msgid ""
|
||||
"So, if you want to financially support the project, or, for example, give"
|
||||
" me a pizza or a beer, you can do it on `OpenCollective "
|
||||
|
|
@ -328,3 +328,31 @@ msgstr ""
|
|||
#~ "<https://opencollective.com/aiogram>`_ or `Patreon "
|
||||
#~ "<https://www.patreon.com/aiogram>`_."
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Linux/ macOS:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Windows PoweShell"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "To check it worked, use described "
|
||||
#~ "command, it should show the :code:`pip`"
|
||||
#~ " location inside the isolated environment"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Linux, macOS:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Also make you shure you have the"
|
||||
#~ " latest pip version in your virtual"
|
||||
#~ " environment to avoid errors on next"
|
||||
#~ " steps:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "After activating the environment install "
|
||||
#~ "`aiogram` from sources and their "
|
||||
#~ "dependencies:"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -0,0 +1,96 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:3
|
||||
msgid "Dependency injection"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:5
|
||||
msgid ""
|
||||
"Dependency injection is a programming technique that makes a class "
|
||||
"independent of its dependencies. It achieves that by decoupling the usage"
|
||||
" of an object from its creation. This helps you to follow `SOLID's "
|
||||
"<https://en.wikipedia.org/wiki/SOLID>`_ dependency inversion and single "
|
||||
"responsibility principles."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:12
|
||||
msgid "How it works in aiogram"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:14
|
||||
msgid ""
|
||||
"For each update :class:`aiogram.dispatcher.dispatcher.Dispatcher` passes "
|
||||
"handling context data. Filters and middleware can also make changes to "
|
||||
"the context."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:17
|
||||
msgid ""
|
||||
"To access contextual data you should specify corresponding keyword "
|
||||
"parameter in handler or filter. For example, to get "
|
||||
":class:`aiogram.fsm.context.FSMContext` we do it like that:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:30
|
||||
msgid "Injecting own dependencies"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:32
|
||||
msgid "Aiogram provides several ways to complement / modify contextual data."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:34
|
||||
msgid ""
|
||||
"The first and easiest way is to simply specify the named arguments in "
|
||||
":class:`aiogram.dispatcher.dispatcher.Dispatcher` initialization, polling"
|
||||
" start methods or "
|
||||
":class:`aiogram.webhook.aiohttp_server.SimpleRequestHandler` "
|
||||
"initialization if you use webhooks."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:46
|
||||
msgid "Analogy for webhook:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:55
|
||||
msgid ""
|
||||
":class:`aiogram.dispatcher.dispatcher.Dispatcher`'s workflow data also "
|
||||
"can be supplemented by setting values as in a dictionary:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:63
|
||||
msgid ""
|
||||
"The middlewares updates the context quite often. You can read more about "
|
||||
"them on this page:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:66
|
||||
msgid ":ref:`Middlewares <middlewares>`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:68
|
||||
msgid "The last way is to return a dictionary from the filter:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:72
|
||||
msgid ""
|
||||
"...or using :ref:`MagicFilter <magic-filters>` with :code:`.as_(...)` "
|
||||
"method."
|
||||
msgstr ""
|
||||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -34,11 +34,11 @@ msgid ""
|
|||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dispatcher.rst:9
|
||||
msgid "`Router <router.html>`__"
|
||||
msgid ":ref:`Router <Router>`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dispatcher.rst:10
|
||||
msgid "`Observer <observer.html>`__"
|
||||
msgid ":ref:`Filtering events`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.dispatcher.dispatcher.Dispatcher:1
|
||||
|
|
@ -176,3 +176,9 @@ msgstr ""
|
|||
|
||||
#~ msgid "Poling timeout"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "`Router <router.html>`__"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "`Observer <observer.html>`__"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,90 +8,108 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-01 22:51+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:3
|
||||
msgid "ChatMemberUpdated"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:10
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:6
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:8
|
||||
msgid "Handle user leave or join events"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:20
|
||||
msgid ""
|
||||
"Or construct your own terms via using pre-defined set of statuses and "
|
||||
"transitions."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:24
|
||||
msgid "Explanation"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:31
|
||||
msgid ""
|
||||
"You can import from :code:`aiogram.filters` all available variants of "
|
||||
"`statuses`_, `status groups`_ or `transitions`_:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:14
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:35
|
||||
msgid "Statuses"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:17
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:62
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:38
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:63
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "name"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:17
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:62
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:38
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:63
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "Description"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:19
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:40
|
||||
msgid ":code:`CREATOR`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:19
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:40
|
||||
msgid "Chat owner"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:21
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
msgid ":code:`ADMINISTRATOR`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:21
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
msgid "Chat administrator"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:23
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
msgid ":code:`MEMBER`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:23
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
msgid "Member of the chat"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:25
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
msgid ":code:`RESTRICTED`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:25
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
msgid "Restricted user (can be not member)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:27
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
msgid ":code:`LEFT`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:27
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
msgid "Isn't member of the chat"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:29
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:50
|
||||
msgid ":code:`KICKED`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:29
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:50
|
||||
msgid "Kicked member by administrators"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:32
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:53
|
||||
msgid ""
|
||||
"Statuses can be extended with `is_member` flag by prefixing with "
|
||||
":code:`+` (for :code:`is_member == True)` or :code:`-` (for "
|
||||
|
|
@ -99,47 +117,47 @@ msgid ""
|
|||
":code:`-RESTRICTED`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:37
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:58
|
||||
msgid "Status groups"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:39
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:60
|
||||
msgid ""
|
||||
"The particular statuses can be combined via bitwise :code:`or` operator, "
|
||||
"like :code:`CREATOR | ADMINISTRATOR`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:65
|
||||
msgid ":code:`IS_MEMBER`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:65
|
||||
msgid ""
|
||||
"Combination of :code:`(CREATOR | ADMINISTRATOR | MEMBER | +RESTRICTED)` "
|
||||
"statuses."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
msgid ":code:`IS_ADMIN`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
msgid "Combination of :code:`(CREATOR | ADMINISTRATOR)` statuses."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:69
|
||||
msgid ":code:`IS_NOT_MEMBER`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:69
|
||||
msgid "Combination of :code:`(LEFT | KICKED | -RESTRICTED)` statuses."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:52
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:73
|
||||
msgid "Transitions"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:54
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:75
|
||||
msgid ""
|
||||
"Transitions can be defined via bitwise shift operators :code:`>>` and "
|
||||
":code:`<<`. Old chat member status should be defined in the left side for"
|
||||
|
|
@ -148,77 +166,63 @@ msgid ""
|
|||
":code:`<<`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:58
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:79
|
||||
msgid ""
|
||||
"The direction of transition can be changed via bitwise inversion "
|
||||
"operator: :code:`~JOIN_TRANSITION` will produce swap of old and new "
|
||||
"statuses."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:64
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:85
|
||||
msgid ":code:`JOIN_TRANSITION`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:64
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:85
|
||||
msgid ""
|
||||
"Means status changed from :code:`IS_NOT_MEMBER` to :code:`IS_MEMBER` "
|
||||
"(:code:`IS_NOT_MEMBER >> IS_MEMBER`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:88
|
||||
msgid ":code:`LEAVE_TRANSITION`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:88
|
||||
msgid ""
|
||||
"Means status changed from :code:`IS_MEMBER` to :code:`IS_NOT_MEMBER` "
|
||||
"(:code:`~JOIN_TRANSITION`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:70
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:91
|
||||
msgid ":code:`PROMOTED_TRANSITION`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:70
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:91
|
||||
msgid ""
|
||||
"Means status changed from :code:`(MEMBER | RESTRICTED | LEFT | KICKED) >>"
|
||||
" ADMINISTRATOR` (:code:`(MEMBER | RESTRICTED | LEFT | KICKED) >> "
|
||||
"ADMINISTRATOR`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:77
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:98
|
||||
msgid ""
|
||||
"Note that if you define the status unions (via :code:`|`) you will need "
|
||||
"to add brackets for the statement before use shift operator in due to "
|
||||
"operator priorities."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:81
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "Handle user leave or join events"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:95
|
||||
msgid ""
|
||||
"Or construct your own terms via using pre-defined set of statuses and "
|
||||
"transitions."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:98
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:103
|
||||
msgid "Allowed handlers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:100
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:105
|
||||
msgid "Allowed update types for this filter:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:102
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:107
|
||||
msgid "`my_chat_member`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:103
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:108
|
||||
msgid "`chat_member`"
|
||||
msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,106 +8,110 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-25 22:10+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:3
|
||||
msgid "MagicData"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:6
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:8
|
||||
msgid ""
|
||||
":code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Note that "
|
||||
":code:`config` should be passed from middleware)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:11
|
||||
msgid "Explanation"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.filters.magic_data.MagicData:1 of
|
||||
msgid "This filter helps to filter event with contextual data"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:10
|
||||
#: ../../dispatcher/filters/magic_data.rst:18
|
||||
msgid "Can be imported:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:12
|
||||
#: ../../dispatcher/filters/magic_data.rst:20
|
||||
msgid ":code:`from aiogram.filters import MagicData`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:15
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:17
|
||||
msgid ""
|
||||
":code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Note that "
|
||||
":code:`config` should be passed from middleware)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:21
|
||||
#: ../../dispatcher/filters/magic_data.rst:24
|
||||
msgid "Allowed handlers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:23
|
||||
#: ../../dispatcher/filters/magic_data.rst:26
|
||||
msgid "Allowed update types for this filter:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:25
|
||||
#: ../../dispatcher/filters/magic_data.rst:28
|
||||
msgid ":code:`message`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:26
|
||||
#: ../../dispatcher/filters/magic_data.rst:29
|
||||
msgid ":code:`edited_message`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:27
|
||||
#: ../../dispatcher/filters/magic_data.rst:30
|
||||
msgid ":code:`channel_post`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:28
|
||||
#: ../../dispatcher/filters/magic_data.rst:31
|
||||
msgid ":code:`edited_channel_post`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:29
|
||||
#: ../../dispatcher/filters/magic_data.rst:32
|
||||
msgid ":code:`inline_query`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:30
|
||||
#: ../../dispatcher/filters/magic_data.rst:33
|
||||
msgid ":code:`chosen_inline_result`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:31
|
||||
#: ../../dispatcher/filters/magic_data.rst:34
|
||||
msgid ":code:`callback_query`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:32
|
||||
#: ../../dispatcher/filters/magic_data.rst:35
|
||||
msgid ":code:`shipping_query`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:33
|
||||
#: ../../dispatcher/filters/magic_data.rst:36
|
||||
msgid ":code:`pre_checkout_query`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:34
|
||||
#: ../../dispatcher/filters/magic_data.rst:37
|
||||
msgid ":code:`poll`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:35
|
||||
#: ../../dispatcher/filters/magic_data.rst:38
|
||||
msgid ":code:`poll_answer`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:36
|
||||
#: ../../dispatcher/filters/magic_data.rst:39
|
||||
msgid ":code:`my_chat_member`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:37
|
||||
#: ../../dispatcher/filters/magic_data.rst:40
|
||||
msgid ":code:`chat_member`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:38
|
||||
#: ../../dispatcher/filters/magic_data.rst:41
|
||||
msgid ":code:`chat_join_request`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:39
|
||||
#: ../../dispatcher/filters/magic_data.rst:42
|
||||
msgid ":code:`error`"
|
||||
msgstr ""
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -17,10 +17,14 @@ msgstr ""
|
|||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/router.rst:3
|
||||
#: ../../dispatcher/router.rst:5
|
||||
msgid "Router"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:7
|
||||
msgid "Usage:"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.dispatcher.router.Router:1 of
|
||||
msgid "Bases: :py:class:`object`"
|
||||
msgstr ""
|
||||
|
|
@ -86,11 +90,11 @@ msgstr ""
|
|||
msgid "set of registered names"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:13
|
||||
#: ../../dispatcher/router.rst:29
|
||||
msgid "Event observers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:17
|
||||
#: ../../dispatcher/router.rst:33
|
||||
msgid ""
|
||||
"All handlers always should be asynchronous. The name of the handler "
|
||||
"function is not important. The event argument name is also not important "
|
||||
|
|
@ -98,145 +102,145 @@ msgid ""
|
|||
" to function can not accept two arguments with the same name."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:20
|
||||
#: ../../dispatcher/router.rst:36
|
||||
msgid ""
|
||||
"Here is the list of available observers and examples of how to register "
|
||||
"handlers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:22
|
||||
#: ../../dispatcher/router.rst:38
|
||||
msgid ""
|
||||
"In these examples only decorator-style registering handlers are used, but"
|
||||
" if you don't like @decorators just use :obj:`<event type>.register(...)`"
|
||||
" method instead."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:25
|
||||
#: ../../dispatcher/router.rst:41
|
||||
msgid "Message"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:30
|
||||
#: ../../dispatcher/router.rst:46
|
||||
msgid "Be attentive with filtering this event"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:32
|
||||
#: ../../dispatcher/router.rst:48
|
||||
msgid ""
|
||||
"You should expect that this event can be with different sets of "
|
||||
"attributes in different cases"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:34
|
||||
#: ../../dispatcher/router.rst:50
|
||||
msgid ""
|
||||
"(For example text, sticker and document are always of different content "
|
||||
"types of message)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:36
|
||||
#: ../../dispatcher/router.rst:52
|
||||
msgid ""
|
||||
"Recommended way to check field availability before usage, for example via"
|
||||
" :ref:`magic filter <magic-filters>`: :code:`F.text` to handle text, "
|
||||
":code:`F.sticker` to handle stickers only and etc."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:47
|
||||
#: ../../dispatcher/router.rst:63
|
||||
msgid "Edited message"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:55
|
||||
#: ../../dispatcher/router.rst:71
|
||||
msgid "Channel post"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:63
|
||||
#: ../../dispatcher/router.rst:79
|
||||
msgid "Edited channel post"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:72
|
||||
#: ../../dispatcher/router.rst:88
|
||||
msgid "Inline query"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:80
|
||||
#: ../../dispatcher/router.rst:96
|
||||
msgid "Chosen inline query"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:88
|
||||
#: ../../dispatcher/router.rst:104
|
||||
msgid "Callback query"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:96
|
||||
#: ../../dispatcher/router.rst:112
|
||||
msgid "Shipping query"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:104
|
||||
#: ../../dispatcher/router.rst:120
|
||||
msgid "Pre checkout query"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:112
|
||||
#: ../../dispatcher/router.rst:128
|
||||
msgid "Poll"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:120
|
||||
#: ../../dispatcher/router.rst:136
|
||||
msgid "Poll answer"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:128
|
||||
#: ../../dispatcher/router.rst:144
|
||||
msgid "Errors"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:135
|
||||
#: ../../dispatcher/router.rst:151
|
||||
msgid ""
|
||||
"Is useful for handling errors from other handlers, error event described "
|
||||
":ref:`here <error-event>`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:142
|
||||
#: ../../dispatcher/router.rst:158
|
||||
msgid "Nested routers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:147
|
||||
#: ../../dispatcher/router.rst:163
|
||||
msgid ""
|
||||
"Routers by the way can be nested to an another routers with some "
|
||||
"limitations:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:147
|
||||
#: ../../dispatcher/router.rst:163
|
||||
msgid ""
|
||||
"1. Router **CAN NOT** include itself 1. Routers **CAN NOT** be used for "
|
||||
"circular including (router 1 include router 2, router 2 include router 3,"
|
||||
" router 3 include router 1)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:151
|
||||
#: ../../dispatcher/router.rst:167
|
||||
msgid "Example:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:153
|
||||
#: ../../dispatcher/router.rst:169
|
||||
msgid "module_1.py"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:163
|
||||
#: ../../dispatcher/router.rst:179
|
||||
msgid "module_2.py"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:175
|
||||
#: ../../dispatcher/router.rst:191
|
||||
msgid "Update"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:184
|
||||
#: ../../dispatcher/router.rst:200
|
||||
msgid "The only root Router (Dispatcher) can handle this type of event."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:188
|
||||
#: ../../dispatcher/router.rst:204
|
||||
msgid ""
|
||||
"Dispatcher already has default handler for this event type, so you can "
|
||||
"use it for handling all updates that are not handled by any other "
|
||||
"handlers."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:191
|
||||
#: ../../dispatcher/router.rst:207
|
||||
msgid "How it works?"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:193
|
||||
#: ../../dispatcher/router.rst:209
|
||||
msgid ""
|
||||
"For example, dispatcher has 2 routers, the last router also has one "
|
||||
"nested router:"
|
||||
|
|
@ -246,7 +250,7 @@ msgstr ""
|
|||
msgid "Nested routers example"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:198
|
||||
#: ../../dispatcher/router.rst:214
|
||||
msgid "In this case update propagation flow will have form:"
|
||||
msgstr ""
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -18,15 +18,7 @@ msgstr ""
|
|||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../../README.rst:3
|
||||
msgid "aiogram |beta badge|"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:94
|
||||
msgid "Beta badge"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:6
|
||||
msgid "This version is still in development!"
|
||||
msgid "aiogram"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:-1
|
||||
|
|
@ -61,7 +53,7 @@ msgstr ""
|
|||
msgid "Codecov"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:40
|
||||
#: ../../../README.rst:37
|
||||
msgid ""
|
||||
"**aiogram** is a modern and fully asynchronous framework for `Telegram "
|
||||
"Bot API <https://core.telegram.org/bots/api>`_ written in Python 3.8 "
|
||||
|
|
@ -69,136 +61,124 @@ msgid ""
|
|||
"`aiohttp <https://github.com/aio-libs/aiohttp>`_."
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:45
|
||||
#: ../../../README.rst:42
|
||||
msgid "Make your bots faster and more powerful!"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:50
|
||||
#: ../../../README.rst:47
|
||||
msgid "Documentation:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:48
|
||||
#: ../../../README.rst:45
|
||||
msgid "🇺🇸 `English <https://docs.aiogram.dev/en/dev-3.x/>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:49
|
||||
#: ../../../README.rst:46
|
||||
msgid "🇺🇦 `Ukrainian <https://docs.aiogram.dev/uk_UA/dev-3.x/>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:54
|
||||
msgid "**Breaking News:**"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:56
|
||||
msgid "*aiogram* 3.0 has breaking changes."
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:58
|
||||
msgid "It breaks backward compatibility by introducing new breaking changes!"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:61
|
||||
#: ../../../README.rst:50
|
||||
msgid "Features"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:63
|
||||
#: ../../../README.rst:52
|
||||
msgid ""
|
||||
"Asynchronous (`asyncio docs "
|
||||
"<https://docs.python.org/3/library/asyncio.html>`_, :pep:`492`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:64
|
||||
#: ../../../README.rst:53
|
||||
msgid ""
|
||||
"Has type hints (:pep:`484`) and can be used with `mypy <http://mypy-"
|
||||
"lang.org/>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:65
|
||||
#: ../../../README.rst:54
|
||||
msgid "Supports `PyPy <https://www.pypy.org/>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:66
|
||||
#: ../../../README.rst:55
|
||||
msgid ""
|
||||
"Supports `Telegram Bot API 6.7 <https://core.telegram.org/bots/api>`_ and"
|
||||
"Supports `Telegram Bot API 6.8 <https://core.telegram.org/bots/api>`_ and"
|
||||
" gets fast updates to the latest versions of the Bot API"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:67
|
||||
#: ../../../README.rst:56
|
||||
msgid ""
|
||||
"Telegram Bot API integration code was `autogenerated "
|
||||
"<https://github.com/aiogram/tg-codegen>`_ and can be easily re-generated "
|
||||
"when API gets updated"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:68
|
||||
#: ../../../README.rst:57
|
||||
msgid "Updates router (Blueprints)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:69
|
||||
#: ../../../README.rst:58
|
||||
msgid "Has Finite State Machine"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:70
|
||||
#: ../../../README.rst:59
|
||||
msgid ""
|
||||
"Uses powerful `magic filters "
|
||||
"<https://docs.aiogram.dev/en/dev-3.x/dispatcher/filters/magic_filters.html"
|
||||
"#magic-filters>`"
|
||||
"<https://docs.aiogram.dev/en/latest/dispatcher/filters/magic_filters.html"
|
||||
"#magic-filters>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:71
|
||||
#: ../../../README.rst:60
|
||||
msgid "Middlewares (incoming updates and API calls)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:72
|
||||
#: ../../../README.rst:61
|
||||
msgid ""
|
||||
"Provides `Replies into Webhook <https://core.telegram.org/bots/faq#how-"
|
||||
"can-i-make-requests-in-response-to-updates>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:73
|
||||
#: ../../../README.rst:62
|
||||
msgid "Integrated I18n/L10n support with GNU Gettext (or Fluent)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:78
|
||||
#: ../../../README.rst:67
|
||||
msgid ""
|
||||
"It is strongly advised that you have prior experience working with "
|
||||
"`asyncio <https://docs.python.org/3/library/asyncio.html>`_ before "
|
||||
"beginning to use **aiogram**."
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:82
|
||||
#: ../../../README.rst:71
|
||||
msgid "If you have any questions, you can visit our community chats on Telegram:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:84
|
||||
#: ../../../README.rst:73
|
||||
msgid "🇺🇸 `@aiogram <https://t.me/aiogram>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:85
|
||||
#: ../../../README.rst:74
|
||||
msgid "🇺🇦 `@aiogramua <https://t.me/aiogramua>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:86
|
||||
#: ../../../README.rst:75
|
||||
msgid "🇺🇿 `@aiogram_uz <https://t.me/aiogram_uz>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:87
|
||||
#: ../../../README.rst:76
|
||||
msgid "🇰🇿 `@aiogram_kz <https://t.me/aiogram_kz>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:88
|
||||
#: ../../../README.rst:77
|
||||
msgid "🇷🇺 `@aiogram_ru <https://t.me/aiogram_ru>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:89
|
||||
#: ../../../README.rst:78
|
||||
msgid "🇮🇷 `@aiogram_fa <https://t.me/aiogram_fa>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:90
|
||||
#: ../../../README.rst:79
|
||||
msgid "🇮🇹 `@aiogram_it <https://t.me/aiogram_it>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:91
|
||||
#: ../../../README.rst:80
|
||||
msgid "🇧🇷 `@aiogram_br <https://t.me/aiogram_br>`_"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -236,3 +216,34 @@ msgstr ""
|
|||
#~ " updates to the latest versions of"
|
||||
#~ " the Bot API"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "aiogram |beta badge|"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Beta badge"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "This version is still in development!"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "**Breaking News:**"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "*aiogram* 3.0 has breaking changes."
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "It breaks backward compatibility by introducing new breaking changes!"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Supports `Telegram Bot API 6.7 "
|
||||
#~ "<https://core.telegram.org/bots/api>`_ and gets fast"
|
||||
#~ " updates to the latest versions of"
|
||||
#~ " the Bot API"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Uses powerful `magic filters "
|
||||
#~ "<https://docs.aiogram.dev/en/dev-3.x/dispatcher/filters/magic_filters.html"
|
||||
#~ "#magic-filters>`"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -99,17 +99,24 @@ msgid ""
|
|||
"accessed via :code:`data[\"bot\"]`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:46
|
||||
#: ../../migration_2_to_3.rst:43
|
||||
msgid ""
|
||||
"Now to skip pending updates, you should call the "
|
||||
":class:`aiogram.methods.delete_webhook.DeleteWebhook` method directly "
|
||||
"instead of passing :code:`skip_updates=True` to start polling method."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:47
|
||||
msgid "Filtering events"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:48
|
||||
#: ../../migration_2_to_3.rst:49
|
||||
msgid ""
|
||||
"Keyword filters can no more be used, use filters explicitly. (`Read more "
|
||||
"» <https://github.com/aiogram/aiogram/issues/942>`_)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:49
|
||||
#: ../../migration_2_to_3.rst:50
|
||||
msgid ""
|
||||
"In due to keyword filters was removed all enabled by default filters "
|
||||
"(state and content_type now is not enabled), so you should specify them "
|
||||
|
|
@ -118,19 +125,19 @@ msgid ""
|
|||
"use :code:`@router.message(F.photo)`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:53
|
||||
#: ../../migration_2_to_3.rst:54
|
||||
msgid ""
|
||||
"Most of common filters is replaced by \"magic filter\". (:ref:`Read more "
|
||||
"» <magic-filters>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:54
|
||||
#: ../../migration_2_to_3.rst:55
|
||||
msgid ""
|
||||
"Now by default message handler receives any content type, if you want "
|
||||
"specific one just add the filters (Magic or any other)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:56
|
||||
#: ../../migration_2_to_3.rst:57
|
||||
msgid ""
|
||||
"State filter now is not enabled by default, that's mean if you using "
|
||||
":code:`state=\"*\"` in v2 then you should not pass any state filter in "
|
||||
|
|
@ -138,38 +145,38 @@ msgid ""
|
|||
"specify the state."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:59
|
||||
#: ../../migration_2_to_3.rst:60
|
||||
msgid ""
|
||||
"Added possibility to register per-router global filters, that helps to "
|
||||
"reduces the number of repetitions in the code and makes easily way to "
|
||||
"control for what each router will be used."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:65
|
||||
#: ../../migration_2_to_3.rst:66
|
||||
msgid "Bot API"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:67
|
||||
#: ../../migration_2_to_3.rst:68
|
||||
msgid ""
|
||||
"Now all API methods is classes with validation (via `pydantic "
|
||||
"<https://docs.pydantic.dev/>`_) (all API calls is also available as "
|
||||
"methods in the Bot class)."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:69
|
||||
#: ../../migration_2_to_3.rst:70
|
||||
msgid ""
|
||||
"Added more pre-defined Enums and moved into `aiogram.enums` sub-package. "
|
||||
"For example chat type enum now is :class:`aiogram.enums.ChatType` instead"
|
||||
" of :class:`aiogram.types.chat.ChatType`. (:ref:`Read more » <enums>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:72
|
||||
#: ../../migration_2_to_3.rst:73
|
||||
msgid ""
|
||||
"Separated HTTP client session into container that can be reused between "
|
||||
"different Bot instances in the application."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:74
|
||||
#: ../../migration_2_to_3.rst:75
|
||||
msgid ""
|
||||
"API Exceptions is no more classified by specific message in due to "
|
||||
"Telegram has no documented error codes. But all errors is classified by "
|
||||
|
|
@ -179,17 +186,17 @@ msgid ""
|
|||
"types>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:81
|
||||
#: ../../migration_2_to_3.rst:82
|
||||
msgid "Middlewares"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:83
|
||||
#: ../../migration_2_to_3.rst:84
|
||||
msgid ""
|
||||
"Middlewares can now control a execution context, e.g. using context "
|
||||
"managers (:ref:`Read more » <middlewares>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:84
|
||||
#: ../../migration_2_to_3.rst:85
|
||||
msgid ""
|
||||
"All contextual data now is shared between middlewares, filters and "
|
||||
"handlers to end-to-end use. For example now you can easily pass some data"
|
||||
|
|
@ -197,75 +204,102 @@ msgid ""
|
|||
"same way as in the handlers via keyword arguments."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:87
|
||||
#: ../../migration_2_to_3.rst:88
|
||||
msgid ""
|
||||
"Added mechanism named **flags**, that helps to customize handler behavior"
|
||||
" in conjunction with middlewares. (:ref:`Read more » <flags>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:92
|
||||
#: ../../migration_2_to_3.rst:93
|
||||
msgid "Keyboard Markup"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:94
|
||||
#: ../../migration_2_to_3.rst:95
|
||||
msgid ""
|
||||
"Now :class:`aiogram.types.inline_keyboard_markup.InlineKeyboardMarkup` "
|
||||
"and :class:`aiogram.types.reply_keyboard_markup.ReplyKeyboardMarkup` has "
|
||||
"no methods to extend it, instead you have to use markup builders "
|
||||
":class:`aiogram.utils.keyboard.ReplyKeyboardBuilder` and "
|
||||
":class:`aiogram.utils.keyboard.KeyboardBuilder` respectively (:ref:`Read "
|
||||
"more » <keyboard-builder>`)"
|
||||
"more » <Keyboard builder>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:102
|
||||
#: ../../migration_2_to_3.rst:103
|
||||
msgid "Callbacks data"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:104
|
||||
#: ../../migration_2_to_3.rst:105
|
||||
msgid ""
|
||||
"Callback data factory now is strictly typed via `pydantic "
|
||||
"<https://docs.pydantic.dev/>`_ models (:ref:`Read more » <callback-data-"
|
||||
"<https://docs.pydantic.dev/>`_ models (:ref:`Read more » <Callback data "
|
||||
"factory>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:109
|
||||
#: ../../migration_2_to_3.rst:110
|
||||
msgid "Finite State machine"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:111
|
||||
#: ../../migration_2_to_3.rst:112
|
||||
msgid ""
|
||||
"State filter will no more added to all handlers, you will need to specify"
|
||||
" state if you want"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:112
|
||||
#: ../../migration_2_to_3.rst:113
|
||||
msgid ""
|
||||
"Added possibility to change FSM strategy, for example if you want to "
|
||||
"control state for each user in chat topics instead of user in chat you "
|
||||
"can specify it in the Dispatcher."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:117
|
||||
#: ../../migration_2_to_3.rst:115
|
||||
msgid ""
|
||||
"Now :class:`aiogram.fsm.state.State` and "
|
||||
":class:`aiogram.fsm.state.StateGroup` don't have helper methods like "
|
||||
":code:`.set()`, :code:`.next()`, etc."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:118
|
||||
msgid ""
|
||||
"Instead of this you should set states by passing them directly to "
|
||||
":class:`aiogram.fsm.context.FSMContext` (:ref:`Read more » <Finite State "
|
||||
"Machine>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:120
|
||||
msgid ""
|
||||
"State proxy is deprecated, you should update the state data by calling "
|
||||
":code:`state.set_data(...)` and :code:`state.get_data()` respectively."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:125
|
||||
msgid "Sending Files"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:119
|
||||
#: ../../migration_2_to_3.rst:127
|
||||
msgid ""
|
||||
"From now you should wrap sending files into InputFile object before send "
|
||||
"instead of passing IO object directly to the API method. (:ref:`Read more"
|
||||
" » <sending-files>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:124
|
||||
#: ../../migration_2_to_3.rst:132
|
||||
msgid "Webhook"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:126
|
||||
#: ../../migration_2_to_3.rst:134
|
||||
msgid "Simplified aiohttp web app configuration"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:127
|
||||
#: ../../migration_2_to_3.rst:135
|
||||
msgid ""
|
||||
"By default added possibility to upload files when you use reply into "
|
||||
"webhook"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Callback data factory now is strictly"
|
||||
#~ " typed via `pydantic "
|
||||
#~ "<https://docs.pydantic.dev/>`_ models (:ref:`Read "
|
||||
#~ "more » <callback-data-factory>`)"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -0,0 +1,94 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:3
|
||||
msgid "unpinAllGeneralForumTopicMessages"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:5
|
||||
msgid "Returns: :obj:`bool`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages:1
|
||||
#: of
|
||||
msgid ""
|
||||
"Use this method to clear the list of pinned messages in a General forum "
|
||||
"topic. The bot must be an administrator in the chat for this to work and "
|
||||
"must have the *can_pin_messages* administrator right in the supergroup. "
|
||||
"Returns :code:`True` on success."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages:3
|
||||
#: of
|
||||
msgid ""
|
||||
"Source: "
|
||||
"https://core.telegram.org/bots/api#unpinallgeneralforumtopicmessages"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring
|
||||
#: aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages.chat_id:1
|
||||
#: of
|
||||
msgid ""
|
||||
"Unique identifier for the target chat or username of the target "
|
||||
"supergroup (in the format :code:`@supergroupusername`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:15
|
||||
msgid "Usage"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:18
|
||||
msgid "As bot method"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:26
|
||||
msgid "Method as object"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:28
|
||||
msgid "Imports:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:30
|
||||
msgid ""
|
||||
":code:`from aiogram.methods.unpin_all_general_forum_topic_messages import"
|
||||
" UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:31
|
||||
msgid ""
|
||||
"alias: :code:`from aiogram.methods import "
|
||||
"UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:34
|
||||
msgid "With specific bot"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:41
|
||||
msgid "As reply into Webhook in handler"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:49
|
||||
msgid "As shortcut from received object"
|
||||
msgstr ""
|
||||
|
||||
#: ../../api/methods/unpin_all_general_forum_topic_messages.rst:51
|
||||
msgid ":meth:`aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages`"
|
||||
msgstr ""
|
||||
|
|
@ -8,14 +8,14 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-02-12 00:22+0200\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.9.1\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/chat.rst:3
|
||||
msgid "Chat"
|
||||
|
|
@ -88,6 +88,13 @@ msgid ""
|
|||
":class:`aiogram.methods.get_chat.GetChat`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.chat.Chat.emoji_status_expiration_date:1 of
|
||||
msgid ""
|
||||
"*Optional*. Expiration date of the emoji status of the other party in a "
|
||||
"private chat, if any. Returned only in "
|
||||
":class:`aiogram.methods.get_chat.GetChat`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.chat.Chat.bio:1 of
|
||||
msgid ""
|
||||
"*Optional*. Bio of the other party in a private chat. Returned only in "
|
||||
|
|
@ -264,6 +271,7 @@ msgstr ""
|
|||
#: aiogram.types.chat.Chat.set_sticker_set:4
|
||||
#: aiogram.types.chat.Chat.set_title:4 aiogram.types.chat.Chat.unban:4
|
||||
#: aiogram.types.chat.Chat.unban_sender_chat:4
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:4
|
||||
#: aiogram.types.chat.Chat.unpin_all_messages:4
|
||||
#: aiogram.types.chat.Chat.unpin_message:4 of
|
||||
msgid ":code:`chat_id`"
|
||||
|
|
@ -320,6 +328,7 @@ msgstr ""
|
|||
#: aiogram.types.chat.Chat.set_permissions aiogram.types.chat.Chat.set_photo
|
||||
#: aiogram.types.chat.Chat.set_sticker_set aiogram.types.chat.Chat.set_title
|
||||
#: aiogram.types.chat.Chat.unban aiogram.types.chat.Chat.unban_sender_chat
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages
|
||||
#: aiogram.types.chat.Chat.unpin_all_messages
|
||||
#: aiogram.types.chat.Chat.unpin_message of
|
||||
msgid "Returns"
|
||||
|
|
@ -1269,6 +1278,33 @@ msgstr ""
|
|||
msgid "instance of method :class:`aiogram.methods.set_chat_photo.SetChatPhoto`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:1 of
|
||||
msgid ""
|
||||
"Shortcut for method "
|
||||
":class:`aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages`"
|
||||
" will automatically fill method attributes:"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:6 of
|
||||
msgid ""
|
||||
"Use this method to clear the list of pinned messages in a General forum "
|
||||
"topic. The bot must be an administrator in the chat for this to work and "
|
||||
"must have the *can_pin_messages* administrator right in the supergroup. "
|
||||
"Returns :code:`True` on success."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:8 of
|
||||
msgid ""
|
||||
"Source: "
|
||||
"https://core.telegram.org/bots/api#unpinallgeneralforumtopicmessages"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.chat.Chat.unpin_all_general_forum_topic_messages:10 of
|
||||
msgid ""
|
||||
"instance of method "
|
||||
":class:`aiogram.methods.unpin_all_general_forum_topic_messages.UnpinAllGeneralForumTopicMessages`"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Use this method to get information "
|
||||
#~ "about a member of a chat. The "
|
||||
|
|
@ -1288,4 +1324,3 @@ msgstr ""
|
|||
#~ "by administrators that were appointed by"
|
||||
#~ " him)"
|
||||
#~ msgstr ""
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-06 16:52+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -173,6 +173,10 @@ msgstr ""
|
|||
msgid "*Optional*. Message is a sticker, information about the sticker"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.message.Message.story:1 of
|
||||
msgid "*Optional*. Message is a forwarded story"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.message.Message.video:1 of
|
||||
msgid "*Optional*. Message is a video, information about the video"
|
||||
msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,14 +8,14 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-01 22:51+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/poll_answer.rst:3
|
||||
msgid "PollAnswer"
|
||||
|
|
@ -33,12 +33,29 @@ msgstr ""
|
|||
msgid "Unique poll identifier"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.user:1 of
|
||||
msgid "The user, who changed the answer to the poll"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.option_ids:1 of
|
||||
msgid ""
|
||||
"0-based identifiers of answer options, chosen by the user. May be empty "
|
||||
"if the user retracted their vote."
|
||||
"0-based identifiers of chosen answer options. May be empty if the vote "
|
||||
"was retracted."
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.voter_chat:1 of
|
||||
msgid ""
|
||||
"*Optional*. The chat that changed the answer to the poll, if the voter is"
|
||||
" anonymous"
|
||||
msgstr ""
|
||||
|
||||
#: ../../docstring aiogram.types.poll_answer.PollAnswer.user:1 of
|
||||
msgid ""
|
||||
"*Optional*. The user that changed the answer to the poll, if the voter "
|
||||
"isn't anonymous"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid "The user, who changed the answer to the poll"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "0-based identifiers of answer options, "
|
||||
#~ "chosen by the user. May be empty"
|
||||
#~ " if the user retracted their vote."
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
32
docs/locale/uk_UA/LC_MESSAGES/api/types/story.po
Normal file
32
docs/locale/uk_UA/LC_MESSAGES/api/types/story.po
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../api/types/story.rst:3
|
||||
msgid "Story"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.story.Story:1 of
|
||||
msgid ""
|
||||
"This object represents a message about a forwarded story in the chat. "
|
||||
"Currently holds no information."
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.types.story.Story:3 of
|
||||
msgid "Source: https://core.telegram.org/bots/api#story"
|
||||
msgstr ""
|
||||
File diff suppressed because it is too large
Load diff
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -78,112 +78,112 @@ msgstr ""
|
|||
msgid "Activate the environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:38
|
||||
msgid "Linux/ macOS:"
|
||||
#: ../../contributing.rst:38 ../../contributing.rst:77
|
||||
msgid "Linux / macOS:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:44
|
||||
msgid "Windows PoweShell"
|
||||
msgid "Windows cmd"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:50
|
||||
msgid ""
|
||||
"To check it worked, use described command, it should show the :code:`pip`"
|
||||
" location inside the isolated environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:53
|
||||
msgid "Linux, macOS:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:59
|
||||
msgid "Windows PowerShell"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:65
|
||||
#: ../../contributing.rst:56
|
||||
msgid ""
|
||||
"Also make you shure you have the latest pip version in your virtual "
|
||||
"To check it worked, use described command, it should show the :code:`pip`"
|
||||
" version and location inside the isolated environment"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:64
|
||||
msgid ""
|
||||
"Also make sure you have the latest pip version in your virtual "
|
||||
"environment to avoid errors on next steps:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:74
|
||||
#: ../../contributing.rst:73
|
||||
msgid "Setup project"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:76
|
||||
#: ../../contributing.rst:75
|
||||
msgid ""
|
||||
"After activating the environment install `aiogram` from sources and their"
|
||||
" dependencies:"
|
||||
" dependencies."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:82
|
||||
#: ../../contributing.rst:83
|
||||
msgid "Windows:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:89
|
||||
msgid ""
|
||||
"It will install :code:`aiogram` in editable mode into your virtual "
|
||||
"environment and all dependencies."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:85
|
||||
#: ../../contributing.rst:92
|
||||
msgid "Making changes in code"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:87
|
||||
#: ../../contributing.rst:94
|
||||
msgid ""
|
||||
"At this point you can make any changes in the code that you want, it can "
|
||||
"be any fixes, implementing new features or experimenting."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:92
|
||||
#: ../../contributing.rst:99
|
||||
msgid "Format the code (code-style)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:94
|
||||
#: ../../contributing.rst:101
|
||||
msgid ""
|
||||
"Note that this project is Black-formatted, so you should follow that "
|
||||
"code-style, too be sure You're correctly doing this let's reformat the "
|
||||
"code automatically:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:104
|
||||
#: ../../contributing.rst:111
|
||||
msgid "Run tests"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:106
|
||||
#: ../../contributing.rst:113
|
||||
msgid "All changes should be tested:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:112
|
||||
#: ../../contributing.rst:119
|
||||
msgid ""
|
||||
"Also if you are doing something with Redis-storage, you will need to test"
|
||||
" everything works with Redis:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:119
|
||||
#: ../../contributing.rst:126
|
||||
msgid "Docs"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:121
|
||||
#: ../../contributing.rst:128
|
||||
msgid ""
|
||||
"We are using `Sphinx` to render docs in different languages, all sources "
|
||||
"located in `docs` directory, you can change the sources and to test it "
|
||||
"you can start live-preview server and look what you are doing:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:130
|
||||
#: ../../contributing.rst:137
|
||||
msgid "Docs translations"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:132
|
||||
#: ../../contributing.rst:139
|
||||
msgid ""
|
||||
"Translation of the documentation is very necessary and cannot be done "
|
||||
"without the help of the community from all over the world, so you are "
|
||||
"welcome to translate the documentation into different languages."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:136
|
||||
#: ../../contributing.rst:143
|
||||
msgid "Before start, let's up to date all texts:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:144
|
||||
#: ../../contributing.rst:151
|
||||
msgid ""
|
||||
"Change the :code:`<language_code>` in example below to the target "
|
||||
"language code, after that you can modify texts inside "
|
||||
|
|
@ -192,120 +192,120 @@ msgid ""
|
|||
"example via `poedit <https://poedit.net/>`_."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:149
|
||||
#: ../../contributing.rst:156
|
||||
msgid "To view results:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:157
|
||||
#: ../../contributing.rst:164
|
||||
msgid "Describe changes"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:159
|
||||
#: ../../contributing.rst:166
|
||||
msgid ""
|
||||
"Describe your changes in one or more sentences so that bot developers "
|
||||
"know what's changed in their favorite framework - create "
|
||||
"`<code>.<category>.rst` file and write the description."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:162
|
||||
#: ../../contributing.rst:169
|
||||
msgid ""
|
||||
":code:`<code>` is Issue or Pull-request number, after release link to "
|
||||
"this issue will be published to the *Changelog* page."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:165
|
||||
#: ../../contributing.rst:172
|
||||
msgid ":code:`<category>` is a changes category marker, it can be one of:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:167
|
||||
#: ../../contributing.rst:174
|
||||
msgid ":code:`feature` - when you are implementing new feature"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:168
|
||||
#: ../../contributing.rst:175
|
||||
msgid ":code:`bugfix` - when you fix a bug"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:169
|
||||
#: ../../contributing.rst:176
|
||||
msgid ":code:`doc` - when you improve the docs"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:170
|
||||
#: ../../contributing.rst:177
|
||||
msgid ":code:`removal` - when you remove something from the framework"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:171
|
||||
#: ../../contributing.rst:178
|
||||
msgid ""
|
||||
":code:`misc` - when changed something inside the Core or project "
|
||||
"configuration"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:173
|
||||
#: ../../contributing.rst:180
|
||||
msgid ""
|
||||
"If you have troubles with changing category feel free to ask Core-"
|
||||
"contributors to help with choosing it."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:176
|
||||
#: ../../contributing.rst:183
|
||||
msgid "Complete"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:178
|
||||
#: ../../contributing.rst:185
|
||||
msgid ""
|
||||
"After you have made all your changes, publish them to the repository and "
|
||||
"create a pull request as mentioned at the beginning of the article and "
|
||||
"wait for a review of these changes."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:183
|
||||
#: ../../contributing.rst:190
|
||||
msgid "Star on GitHub"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:185
|
||||
#: ../../contributing.rst:192
|
||||
msgid ""
|
||||
"You can \"star\" repository on GitHub - "
|
||||
"https://github.com/aiogram/aiogram (click the star button at the top "
|
||||
"right)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:187
|
||||
#: ../../contributing.rst:194
|
||||
msgid ""
|
||||
"Adding stars makes it easier for other people to find this project and "
|
||||
"understand how useful it is."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:190
|
||||
#: ../../contributing.rst:197
|
||||
msgid "Guides"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:192
|
||||
#: ../../contributing.rst:199
|
||||
msgid ""
|
||||
"You can write guides how to develop Bots on top of aiogram and publish it"
|
||||
" into YouTube, Medium, GitHub Books, any Courses platform or any other "
|
||||
"platform that you know."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:195
|
||||
#: ../../contributing.rst:202
|
||||
msgid ""
|
||||
"This will help more people learn about the framework and learn how to use"
|
||||
" it"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:199
|
||||
#: ../../contributing.rst:206
|
||||
msgid "Take answers"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:201
|
||||
#: ../../contributing.rst:208
|
||||
msgid ""
|
||||
"The developers is always asks for any question in our chats or any other "
|
||||
"platforms like GitHub Discussions, StackOverflow and others, feel free to"
|
||||
" answer to this questions."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:205
|
||||
#: ../../contributing.rst:212
|
||||
msgid "Funding"
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:207
|
||||
#: ../../contributing.rst:214
|
||||
msgid ""
|
||||
"The development of the project is free and not financed by commercial "
|
||||
"organizations, it is my personal initiative (`@JRootJunior "
|
||||
|
|
@ -313,7 +313,7 @@ msgid ""
|
|||
"project in my free time."
|
||||
msgstr ""
|
||||
|
||||
#: ../../contributing.rst:211
|
||||
#: ../../contributing.rst:218
|
||||
msgid ""
|
||||
"So, if you want to financially support the project, or, for example, give"
|
||||
" me a pizza or a beer, you can do it on `OpenCollective "
|
||||
|
|
@ -328,3 +328,31 @@ msgstr ""
|
|||
#~ "<https://opencollective.com/aiogram>`_ or `Patreon "
|
||||
#~ "<https://www.patreon.com/aiogram>`_."
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Linux/ macOS:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Windows PoweShell"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "To check it worked, use described "
|
||||
#~ "command, it should show the :code:`pip`"
|
||||
#~ " location inside the isolated environment"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Linux, macOS:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Also make you shure you have the"
|
||||
#~ " latest pip version in your virtual"
|
||||
#~ " environment to avoid errors on next"
|
||||
#~ " steps:"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "After activating the environment install "
|
||||
#~ "`aiogram` from sources and their "
|
||||
#~ "dependencies:"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -0,0 +1,96 @@
|
|||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) 2023, aiogram Team
|
||||
# This file is distributed under the same license as the aiogram package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:3
|
||||
msgid "Dependency injection"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:5
|
||||
msgid ""
|
||||
"Dependency injection is a programming technique that makes a class "
|
||||
"independent of its dependencies. It achieves that by decoupling the usage"
|
||||
" of an object from its creation. This helps you to follow `SOLID's "
|
||||
"<https://en.wikipedia.org/wiki/SOLID>`_ dependency inversion and single "
|
||||
"responsibility principles."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:12
|
||||
msgid "How it works in aiogram"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:14
|
||||
msgid ""
|
||||
"For each update :class:`aiogram.dispatcher.dispatcher.Dispatcher` passes "
|
||||
"handling context data. Filters and middleware can also make changes to "
|
||||
"the context."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:17
|
||||
msgid ""
|
||||
"To access contextual data you should specify corresponding keyword "
|
||||
"parameter in handler or filter. For example, to get "
|
||||
":class:`aiogram.fsm.context.FSMContext` we do it like that:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:30
|
||||
msgid "Injecting own dependencies"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:32
|
||||
msgid "Aiogram provides several ways to complement / modify contextual data."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:34
|
||||
msgid ""
|
||||
"The first and easiest way is to simply specify the named arguments in "
|
||||
":class:`aiogram.dispatcher.dispatcher.Dispatcher` initialization, polling"
|
||||
" start methods or "
|
||||
":class:`aiogram.webhook.aiohttp_server.SimpleRequestHandler` "
|
||||
"initialization if you use webhooks."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:46
|
||||
msgid "Analogy for webhook:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:55
|
||||
msgid ""
|
||||
":class:`aiogram.dispatcher.dispatcher.Dispatcher`'s workflow data also "
|
||||
"can be supplemented by setting values as in a dictionary:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:63
|
||||
msgid ""
|
||||
"The middlewares updates the context quite often. You can read more about "
|
||||
"them on this page:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:66
|
||||
msgid ":ref:`Middlewares <middlewares>`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:68
|
||||
msgid "The last way is to return a dictionary from the filter:"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/dependency_injection.rst:72
|
||||
msgid ""
|
||||
"...or using :ref:`MagicFilter <magic-filters>` with :code:`.as_(...)` "
|
||||
"method."
|
||||
msgstr ""
|
||||
|
|
@ -7,7 +7,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: 2022-12-10 19:44+0200\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
|
|
@ -38,12 +38,13 @@ msgstr ""
|
|||
"обробників, фільтрів і т.п. ви можете знайти на наступних сторінках:"
|
||||
|
||||
#: ../../dispatcher/dispatcher.rst:9
|
||||
msgid "`Router <router.html>`__"
|
||||
#, fuzzy
|
||||
msgid ":ref:`Router <Router>`"
|
||||
msgstr "`Router <router.html>`__"
|
||||
|
||||
#: ../../dispatcher/dispatcher.rst:10
|
||||
msgid "`Observer <observer.html>`__"
|
||||
msgstr "`Observer <observer.html>`__"
|
||||
msgid ":ref:`Filtering events`"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.dispatcher.dispatcher.Dispatcher:1
|
||||
#: aiogram.dispatcher.dispatcher.Dispatcher.__init__:1 of
|
||||
|
|
@ -186,3 +187,6 @@ msgstr ""
|
|||
|
||||
#~ msgid "Poling timeout"
|
||||
#~ msgstr "Час очікування на відповідь"
|
||||
|
||||
#~ msgid "`Observer <observer.html>`__"
|
||||
#~ msgstr "`Observer <observer.html>`__"
|
||||
|
|
|
|||
|
|
@ -5,23 +5,42 @@
|
|||
#
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: aiogram\n"
|
||||
"Project-Id-Version: aiogram\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-01 22:51+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: 2022-10-25 18:00+0300\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"X-Generator: Poedit 3.1.1\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:3
|
||||
msgid "ChatMemberUpdated"
|
||||
msgstr "Зміна статусу користувача в чаті"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:10
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:6
|
||||
msgid "Usage"
|
||||
msgstr "Використання"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:8
|
||||
msgid "Handle user leave or join events"
|
||||
msgstr "Керуйте подіями, які залишають користувачів або приєднуються"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:20
|
||||
msgid ""
|
||||
"Or construct your own terms via using pre-defined set of statuses and "
|
||||
"transitions."
|
||||
msgstr ""
|
||||
"Або створіть власні умови, використовуючи попередньо визначений набір "
|
||||
"статусів і переходів."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:24
|
||||
msgid "Explanation"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:31
|
||||
msgid ""
|
||||
"You can import from :code:`aiogram.filters` all available variants of "
|
||||
"`statuses`_, `status groups`_ or `transitions`_:"
|
||||
|
|
@ -29,98 +48,98 @@ msgstr ""
|
|||
"Ви можете імпортувати з :code:`aiogram.filters` усі доступні варіанти "
|
||||
"`statuses`_, `status group`_ або `transitions`_:"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:14
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:35
|
||||
msgid "Statuses"
|
||||
msgstr "Статуси"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:17
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:62
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:38
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:63
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "name"
|
||||
msgstr "ім'я"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:17
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:62
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:38
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:63
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "Description"
|
||||
msgstr "Опис"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:19
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:40
|
||||
msgid ":code:`CREATOR`"
|
||||
msgstr ":code:`CREATOR`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:19
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:40
|
||||
msgid "Chat owner"
|
||||
msgstr "Власник чату"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:21
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
msgid ":code:`ADMINISTRATOR`"
|
||||
msgstr ":code:`ADMINISTRATOR`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:21
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:42
|
||||
msgid "Chat administrator"
|
||||
msgstr "Адміністратор чату"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:23
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
msgid ":code:`MEMBER`"
|
||||
msgstr ":code:`MEMBER`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:23
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
msgid "Member of the chat"
|
||||
msgstr "Учасник чату"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:25
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
msgid ":code:`RESTRICTED`"
|
||||
msgstr ":code:`RESTRICTED`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:25
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
msgid "Restricted user (can be not member)"
|
||||
msgstr "Обмежений користувач (може бути не учасником)"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:27
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
msgid ":code:`LEFT`"
|
||||
msgstr ":code:`LEFT`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:27
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
msgid "Isn't member of the chat"
|
||||
msgstr "Не є учасником чату"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:29
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:50
|
||||
msgid ":code:`KICKED`"
|
||||
msgstr ":code:`KICKED`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:29
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:50
|
||||
msgid "Kicked member by administrators"
|
||||
msgstr "Вигнанийадміністраторами учасник"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:32
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:53
|
||||
msgid ""
|
||||
"Statuses can be extended with `is_member` flag by prefixing with :code:`"
|
||||
"+` (for :code:`is_member == True)` or :code:`-` (for :code:`is_member == "
|
||||
"False`) symbol, like :code:`+RESTRICTED` or :code:`-RESTRICTED`"
|
||||
"Statuses can be extended with `is_member` flag by prefixing with "
|
||||
":code:`+` (for :code:`is_member == True)` or :code:`-` (for "
|
||||
":code:`is_member == False`) symbol, like :code:`+RESTRICTED` or "
|
||||
":code:`-RESTRICTED`"
|
||||
msgstr ""
|
||||
"Статуси можна розширити маркером `is_member`, додавши префікс :"
|
||||
"code:`+` (для :code:`is_member == True)` або :code:`-` (для :code:"
|
||||
"`is_member == False`) , наприклад :code:`+RESTRICTED` або :code:`-"
|
||||
"RESTRICTED`"
|
||||
"Статуси можна розширити маркером `is_member`, додавши префікс :code:`+` "
|
||||
"(для :code:`is_member == True)` або :code:`-` (для :code:`is_member == "
|
||||
"False`) , наприклад :code:`+RESTRICTED` або :code:`-RESTRICTED`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:37
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:58
|
||||
msgid "Status groups"
|
||||
msgstr "Групи статусів"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:39
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:60
|
||||
msgid ""
|
||||
"The particular statuses can be combined via bitwise :code:`or` operator, "
|
||||
"like :code:`CREATOR | ADMINISTRATOR`"
|
||||
msgstr ""
|
||||
"Окремі статуси можна комбінувати за допомогою побітового оператора :code:"
|
||||
"`or`, наприклад :code:`CREATOR | ADMINISTRATOR`"
|
||||
"Окремі статуси можна комбінувати за допомогою побітового оператора "
|
||||
":code:`or`, наприклад :code:`CREATOR | ADMINISTRATOR`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:65
|
||||
msgid ":code:`IS_MEMBER`"
|
||||
msgstr ":code:`IS_MEMBER`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:44
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:65
|
||||
msgid ""
|
||||
"Combination of :code:`(CREATOR | ADMINISTRATOR | MEMBER | +RESTRICTED)` "
|
||||
"statuses."
|
||||
|
|
@ -128,41 +147,41 @@ msgstr ""
|
|||
"Комбінація статусів :code:`(CREATOR | ADMINISTRATOR | MEMBER | "
|
||||
"+RESTRICTED)`."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
msgid ":code:`IS_ADMIN`"
|
||||
msgstr ":code:`IS_ADMIN`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:46
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
msgid "Combination of :code:`(CREATOR | ADMINISTRATOR)` statuses."
|
||||
msgstr "Комбінація статусів :code:`(CREATOR | ADMINISTRATOR)`."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:69
|
||||
msgid ":code:`IS_NOT_MEMBER`"
|
||||
msgstr ":code:`IS_NOT_MEMBER`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:48
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:69
|
||||
msgid "Combination of :code:`(LEFT | KICKED | -RESTRICTED)` statuses."
|
||||
msgstr "Комбінація статусів :code:`(LEFT | KICKED | -RESTRICTED)` ."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:52
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:73
|
||||
msgid "Transitions"
|
||||
msgstr "Переходи"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:54
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:75
|
||||
msgid ""
|
||||
"Transitions can be defined via bitwise shift operators :code:`>>` and :"
|
||||
"code:`<<`. Old chat member status should be defined in the left side "
|
||||
"for :code:`>>` operator (right side for :code:`<<`) and new status "
|
||||
"should be specified on the right side for :code:`>>` operator (left side "
|
||||
"for :code:`<<`)"
|
||||
"Transitions can be defined via bitwise shift operators :code:`>>` and "
|
||||
":code:`<<`. Old chat member status should be defined in the left side for"
|
||||
" :code:`>>` operator (right side for :code:`<<`) and new status should be"
|
||||
" specified on the right side for :code:`>>` operator (left side for "
|
||||
":code:`<<`)"
|
||||
msgstr ""
|
||||
"Переходи можна визначити за допомогою операторів порозрядного зсуву :"
|
||||
"code:`>>` і :code:`<<`. Старий статус учасника чату має бути визначений "
|
||||
"Переходи можна визначити за допомогою операторів порозрядного зсуву "
|
||||
":code:`>>` і :code:`<<`. Старий статус учасника чату має бути визначений "
|
||||
"ліворуч для оператора :code:`>>` (праворуч для :code:`<<`), а новий "
|
||||
"статус має бути вказаний праворуч для :code:`>>` оператор (ліворуч для :"
|
||||
"code:`<<`)"
|
||||
"статус має бути вказаний праворуч для :code:`>>` оператор (ліворуч для "
|
||||
":code:`<<`)"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:58
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:79
|
||||
msgid ""
|
||||
"The direction of transition can be changed via bitwise inversion "
|
||||
"operator: :code:`~JOIN_TRANSITION` will produce swap of old and new "
|
||||
|
|
@ -172,45 +191,45 @@ msgstr ""
|
|||
"інверсії: :code:`~JOIN_TRANSITION` призведе до обміну старих і нових "
|
||||
"статусів."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:64
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:85
|
||||
msgid ":code:`JOIN_TRANSITION`"
|
||||
msgstr ":code:`JOIN_TRANSITION`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:64
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:85
|
||||
msgid ""
|
||||
"Means status changed from :code:`IS_NOT_MEMBER` to :code:`IS_MEMBER` (:"
|
||||
"code:`IS_NOT_MEMBER >> IS_MEMBER`)"
|
||||
"Means status changed from :code:`IS_NOT_MEMBER` to :code:`IS_MEMBER` "
|
||||
"(:code:`IS_NOT_MEMBER >> IS_MEMBER`)"
|
||||
msgstr ""
|
||||
"Означає, що статус змінено з :code:`IS_NOT_MEMBER` на :code:`IS_MEMBER` "
|
||||
"(:code:`IS_NOT_MEMBER >> IS_MEMBER`)"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:88
|
||||
msgid ":code:`LEAVE_TRANSITION`"
|
||||
msgstr ":code:`LEAVE_TRANSITION`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:67
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:88
|
||||
msgid ""
|
||||
"Means status changed from :code:`IS_MEMBER` to :code:`IS_NOT_MEMBER` (:"
|
||||
"code:`~JOIN_TRANSITION`)"
|
||||
"Means status changed from :code:`IS_MEMBER` to :code:`IS_NOT_MEMBER` "
|
||||
"(:code:`~JOIN_TRANSITION`)"
|
||||
msgstr ""
|
||||
"Означає, що статус змінено з :code:`IS_MEMBER` на :code:`IS_NOT_MEMBER` "
|
||||
"(:code:`~JOIN_TRANSITION`)"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:70
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:91
|
||||
msgid ":code:`PROMOTED_TRANSITION`"
|
||||
msgstr ":code:`PROMOTED_TRANSITION`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:70
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:91
|
||||
msgid ""
|
||||
"Means status changed from :code:`(MEMBER | RESTRICTED | LEFT | KICKED) "
|
||||
">> ADMINISTRATOR` (:code:`(MEMBER | RESTRICTED | LEFT | KICKED) >> "
|
||||
"Means status changed from :code:`(MEMBER | RESTRICTED | LEFT | KICKED) >>"
|
||||
" ADMINISTRATOR` (:code:`(MEMBER | RESTRICTED | LEFT | KICKED) >> "
|
||||
"ADMINISTRATOR`)"
|
||||
msgstr ""
|
||||
"Означає, що статус змінено з :code:`(MEMBER | RESTRICTED | LEFT | "
|
||||
"KICKED) >> ADMINISTRATOR` (:code:`(MEMBER | RESTRICTED | LEFT | KICKED) "
|
||||
">> ADMINISTRATOR`)"
|
||||
"Означає, що статус змінено з :code:`(MEMBER | RESTRICTED | LEFT | KICKED)"
|
||||
" >> ADMINISTRATOR` (:code:`(MEMBER | RESTRICTED | LEFT | KICKED) >> "
|
||||
"ADMINISTRATOR`)"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:77
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:98
|
||||
msgid ""
|
||||
"Note that if you define the status unions (via :code:`|`) you will need "
|
||||
"to add brackets for the statement before use shift operator in due to "
|
||||
|
|
@ -220,34 +239,18 @@ msgstr ""
|
|||
"вам потрібно буде додати дужки для оператора перед використанням "
|
||||
"оператора зсуву через пріоритети оператора."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:81
|
||||
msgid "Usage"
|
||||
msgstr "Використання"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:83
|
||||
msgid "Handle user leave or join events"
|
||||
msgstr "Керуйте подіями, які залишають користувачів або приєднуються"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:95
|
||||
msgid ""
|
||||
"Or construct your own terms via using pre-defined set of statuses and "
|
||||
"transitions."
|
||||
msgstr ""
|
||||
"Або створіть власні умови, використовуючи попередньо визначений набір "
|
||||
"статусів і переходів."
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:98
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:103
|
||||
msgid "Allowed handlers"
|
||||
msgstr "Дозволені обробники"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:100
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:105
|
||||
msgid "Allowed update types for this filter:"
|
||||
msgstr "Дозволені типи оновлень для цього фільтра:"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:102
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:107
|
||||
msgid "`my_chat_member`"
|
||||
msgstr "`my_chat_member`"
|
||||
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:103
|
||||
#: ../../dispatcher/filters/chat_member_updated.rst:108
|
||||
msgid "`chat_member`"
|
||||
msgstr "`chat_member`"
|
||||
|
|
|
|||
|
|
@ -7,36 +7,24 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2022-10-25 22:10+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: 2022-10-25 16:00+0300\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=utf-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.10.3\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:3
|
||||
msgid "MagicData"
|
||||
msgstr "MagicData"
|
||||
|
||||
#: aiogram.filters.magic_data.MagicData:1 of
|
||||
msgid "This filter helps to filter event with contextual data"
|
||||
msgstr "Цей фільтр допомагає фільтрувати події з контекстними даними"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:10
|
||||
msgid "Can be imported:"
|
||||
msgstr "Можна імпортувати:"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:12
|
||||
msgid ":code:`from aiogram.filters import MagicData`"
|
||||
msgstr ":code:`from aiogram.filters import MagicData`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:15
|
||||
#: ../../dispatcher/filters/magic_data.rst:6
|
||||
msgid "Usage"
|
||||
msgstr "Використання"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:17
|
||||
#: ../../dispatcher/filters/magic_data.rst:8
|
||||
msgid ""
|
||||
":code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Note that "
|
||||
":code:`config` should be passed from middleware)"
|
||||
|
|
@ -44,70 +32,86 @@ msgstr ""
|
|||
":code:`MagicData(F.event.from_user.id == F.config.admin_id)` (Зауважте, "
|
||||
"що :code:`config` слід передати з проміжної програми)"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:21
|
||||
#: ../../dispatcher/filters/magic_data.rst:11
|
||||
msgid "Explanation"
|
||||
msgstr ""
|
||||
|
||||
#: aiogram.filters.magic_data.MagicData:1 of
|
||||
msgid "This filter helps to filter event with contextual data"
|
||||
msgstr "Цей фільтр допомагає фільтрувати події з контекстними даними"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:18
|
||||
msgid "Can be imported:"
|
||||
msgstr "Можна імпортувати:"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:20
|
||||
msgid ":code:`from aiogram.filters import MagicData`"
|
||||
msgstr ":code:`from aiogram.filters import MagicData`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:24
|
||||
msgid "Allowed handlers"
|
||||
msgstr "Дозволені типи обробників (handler)"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:23
|
||||
#: ../../dispatcher/filters/magic_data.rst:26
|
||||
msgid "Allowed update types for this filter:"
|
||||
msgstr "Дозволені типи оновлень для цього фільтра:"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:25
|
||||
#: ../../dispatcher/filters/magic_data.rst:28
|
||||
msgid ":code:`message`"
|
||||
msgstr ":code:`message`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:26
|
||||
#: ../../dispatcher/filters/magic_data.rst:29
|
||||
msgid ":code:`edited_message`"
|
||||
msgstr ":code:`edited_message`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:27
|
||||
#: ../../dispatcher/filters/magic_data.rst:30
|
||||
msgid ":code:`channel_post`"
|
||||
msgstr ":code:`channel_post`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:28
|
||||
#: ../../dispatcher/filters/magic_data.rst:31
|
||||
msgid ":code:`edited_channel_post`"
|
||||
msgstr ":code:`edited_channel_post`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:29
|
||||
#: ../../dispatcher/filters/magic_data.rst:32
|
||||
msgid ":code:`inline_query`"
|
||||
msgstr ":code:`inline_query`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:30
|
||||
#: ../../dispatcher/filters/magic_data.rst:33
|
||||
msgid ":code:`chosen_inline_result`"
|
||||
msgstr ":code:`chosen_inline_result`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:31
|
||||
#: ../../dispatcher/filters/magic_data.rst:34
|
||||
msgid ":code:`callback_query`"
|
||||
msgstr ":code:`callback_query`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:32
|
||||
#: ../../dispatcher/filters/magic_data.rst:35
|
||||
msgid ":code:`shipping_query`"
|
||||
msgstr ":code:`shipping_query`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:33
|
||||
#: ../../dispatcher/filters/magic_data.rst:36
|
||||
msgid ":code:`pre_checkout_query`"
|
||||
msgstr ":code:`pre_checkout_query`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:34
|
||||
#: ../../dispatcher/filters/magic_data.rst:37
|
||||
msgid ":code:`poll`"
|
||||
msgstr ":code:`poll`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:35
|
||||
#: ../../dispatcher/filters/magic_data.rst:38
|
||||
msgid ":code:`poll_answer`"
|
||||
msgstr ":code:`poll_answer`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:36
|
||||
#: ../../dispatcher/filters/magic_data.rst:39
|
||||
msgid ":code:`my_chat_member`"
|
||||
msgstr ":code:`my_chat_member`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:37
|
||||
#: ../../dispatcher/filters/magic_data.rst:40
|
||||
msgid ":code:`chat_member`"
|
||||
msgstr ":code:`chat_member`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:38
|
||||
#: ../../dispatcher/filters/magic_data.rst:41
|
||||
msgid ":code:`chat_join_request`"
|
||||
msgstr ":code:`chat_join_request`"
|
||||
|
||||
#: ../../dispatcher/filters/magic_data.rst:39
|
||||
#: ../../dispatcher/filters/magic_data.rst:42
|
||||
msgid ":code:`error`"
|
||||
msgstr ":code:`error`"
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: 2022-12-10 20:41+0200\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
|
|
@ -16,10 +16,15 @@ msgstr ""
|
|||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../dispatcher/router.rst:3
|
||||
#: ../../dispatcher/router.rst:5
|
||||
msgid "Router"
|
||||
msgstr "Маршрутизатор"
|
||||
|
||||
#: ../../dispatcher/router.rst:7
|
||||
#, fuzzy
|
||||
msgid "Usage:"
|
||||
msgstr "Повідомлення"
|
||||
|
||||
#: aiogram.dispatcher.router.Router:1 of
|
||||
msgid "Bases: :py:class:`object`"
|
||||
msgstr "Базується на :py:class:`object`"
|
||||
|
|
@ -91,11 +96,11 @@ msgstr ""
|
|||
msgid "set of registered names"
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:13
|
||||
#: ../../dispatcher/router.rst:29
|
||||
msgid "Event observers"
|
||||
msgstr "Обсервери подій"
|
||||
|
||||
#: ../../dispatcher/router.rst:17
|
||||
#: ../../dispatcher/router.rst:33
|
||||
msgid ""
|
||||
"All handlers always should be asynchronous. The name of the handler "
|
||||
"function is not important. The event argument name is also not important "
|
||||
|
|
@ -107,7 +112,7 @@ msgstr ""
|
|||
"накладати назву на контекстні дані, оскільки функція не може прийняти два"
|
||||
" аргументи з однаковою назвою."
|
||||
|
||||
#: ../../dispatcher/router.rst:20
|
||||
#: ../../dispatcher/router.rst:36
|
||||
msgid ""
|
||||
"Here is the list of available observers and examples of how to register "
|
||||
"handlers"
|
||||
|
|
@ -115,7 +120,7 @@ msgstr ""
|
|||
"Ось список доступних обсерверів і приклади того, як зареєструвати "
|
||||
"обробники"
|
||||
|
||||
#: ../../dispatcher/router.rst:22
|
||||
#: ../../dispatcher/router.rst:38
|
||||
msgid ""
|
||||
"In these examples only decorator-style registering handlers are used, but"
|
||||
" if you don't like @decorators just use :obj:`<event type>.register(...)`"
|
||||
|
|
@ -125,15 +130,15 @@ msgstr ""
|
|||
"декоратора, але якщо вам не подобаються @decorators, просто "
|
||||
"використовуйте :obj:`<event type>.register(...)` method instead."
|
||||
|
||||
#: ../../dispatcher/router.rst:25
|
||||
#: ../../dispatcher/router.rst:41
|
||||
msgid "Message"
|
||||
msgstr "Повідомлення"
|
||||
|
||||
#: ../../dispatcher/router.rst:30
|
||||
#: ../../dispatcher/router.rst:46
|
||||
msgid "Be attentive with filtering this event"
|
||||
msgstr "Будьте уважні при фільтруванні цієї події"
|
||||
|
||||
#: ../../dispatcher/router.rst:32
|
||||
#: ../../dispatcher/router.rst:48
|
||||
msgid ""
|
||||
"You should expect that this event can be with different sets of "
|
||||
"attributes in different cases"
|
||||
|
|
@ -141,13 +146,13 @@ msgstr ""
|
|||
"Вам слід очікувати, що ця подія може мати різні набори атрибутів у різних"
|
||||
" випадках"
|
||||
|
||||
#: ../../dispatcher/router.rst:34
|
||||
#: ../../dispatcher/router.rst:50
|
||||
msgid ""
|
||||
"(For example text, sticker and document are always of different content "
|
||||
"types of message)"
|
||||
msgstr "(Наприклад, текст, стікер та документ завжди мають різні типи вмісту)"
|
||||
|
||||
#: ../../dispatcher/router.rst:36
|
||||
#: ../../dispatcher/router.rst:52
|
||||
msgid ""
|
||||
"Recommended way to check field availability before usage, for example via"
|
||||
" :ref:`magic filter <magic-filters>`: :code:`F.text` to handle text, "
|
||||
|
|
@ -158,62 +163,62 @@ msgstr ""
|
|||
":code:`F.text` для обробки тексту, :code:`F.sticker` для обробки лише "
|
||||
"стікерів і тощо."
|
||||
|
||||
#: ../../dispatcher/router.rst:47
|
||||
#: ../../dispatcher/router.rst:63
|
||||
msgid "Edited message"
|
||||
msgstr "Відредаговане повідомлення"
|
||||
|
||||
#: ../../dispatcher/router.rst:55
|
||||
#: ../../dispatcher/router.rst:71
|
||||
msgid "Channel post"
|
||||
msgstr "Пост на каналі"
|
||||
|
||||
#: ../../dispatcher/router.rst:63
|
||||
#: ../../dispatcher/router.rst:79
|
||||
msgid "Edited channel post"
|
||||
msgstr "Відредагований пост на каналі"
|
||||
|
||||
#: ../../dispatcher/router.rst:72
|
||||
#: ../../dispatcher/router.rst:88
|
||||
msgid "Inline query"
|
||||
msgstr "Inline запит"
|
||||
|
||||
#: ../../dispatcher/router.rst:80
|
||||
#: ../../dispatcher/router.rst:96
|
||||
msgid "Chosen inline query"
|
||||
msgstr "Вибраний результат inline запиту"
|
||||
|
||||
#: ../../dispatcher/router.rst:88
|
||||
#: ../../dispatcher/router.rst:104
|
||||
msgid "Callback query"
|
||||
msgstr "Запит зворотної відповіді"
|
||||
|
||||
#: ../../dispatcher/router.rst:96
|
||||
#: ../../dispatcher/router.rst:112
|
||||
msgid "Shipping query"
|
||||
msgstr "Запит підтвердження доставки"
|
||||
|
||||
#: ../../dispatcher/router.rst:104
|
||||
#: ../../dispatcher/router.rst:120
|
||||
msgid "Pre checkout query"
|
||||
msgstr "Запит перед оформленням замовлення"
|
||||
|
||||
#: ../../dispatcher/router.rst:112
|
||||
#: ../../dispatcher/router.rst:128
|
||||
msgid "Poll"
|
||||
msgstr "Опитування"
|
||||
|
||||
#: ../../dispatcher/router.rst:120
|
||||
#: ../../dispatcher/router.rst:136
|
||||
msgid "Poll answer"
|
||||
msgstr "Відповідь на опитування"
|
||||
|
||||
#: ../../dispatcher/router.rst:128
|
||||
#: ../../dispatcher/router.rst:144
|
||||
msgid "Errors"
|
||||
msgstr "Помилки"
|
||||
|
||||
#: ../../dispatcher/router.rst:135
|
||||
#: ../../dispatcher/router.rst:151
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
"Is useful for handling errors from other handlers, error event described "
|
||||
":ref:`here <error-event>`"
|
||||
msgstr "Корисно для обробки помилок інших обробників"
|
||||
|
||||
#: ../../dispatcher/router.rst:142
|
||||
#: ../../dispatcher/router.rst:158
|
||||
msgid "Nested routers"
|
||||
msgstr "Вкладені маршрутизатори"
|
||||
|
||||
#: ../../dispatcher/router.rst:147
|
||||
#: ../../dispatcher/router.rst:163
|
||||
msgid ""
|
||||
"Routers by the way can be nested to an another routers with some "
|
||||
"limitations:"
|
||||
|
|
@ -221,7 +226,7 @@ msgstr ""
|
|||
"До речі, маршрутизатори можуть бути вкладеними в інші маршрутизатори з "
|
||||
"деякими обмеженнями:"
|
||||
|
||||
#: ../../dispatcher/router.rst:147
|
||||
#: ../../dispatcher/router.rst:163
|
||||
msgid ""
|
||||
"1. Router **CAN NOT** include itself 1. Routers **CAN NOT** be used for "
|
||||
"circular including (router 1 include router 2, router 2 include router 3,"
|
||||
|
|
@ -232,39 +237,39 @@ msgstr ""
|
|||
"(маршрутизатор 1 включає маршрутизатор 2, маршрутизатор 2 включає "
|
||||
"маршрутизатор 3, маршрутизатор 3 включає маршрутизатор 1)"
|
||||
|
||||
#: ../../dispatcher/router.rst:151
|
||||
#: ../../dispatcher/router.rst:167
|
||||
msgid "Example:"
|
||||
msgstr "Приклад:"
|
||||
|
||||
#: ../../dispatcher/router.rst:153
|
||||
#: ../../dispatcher/router.rst:169
|
||||
#, fuzzy
|
||||
msgid "module_1.py"
|
||||
msgstr "module_2.py"
|
||||
|
||||
#: ../../dispatcher/router.rst:163
|
||||
#: ../../dispatcher/router.rst:179
|
||||
msgid "module_2.py"
|
||||
msgstr "module_2.py"
|
||||
|
||||
#: ../../dispatcher/router.rst:175
|
||||
#: ../../dispatcher/router.rst:191
|
||||
msgid "Update"
|
||||
msgstr "Оновлення"
|
||||
|
||||
#: ../../dispatcher/router.rst:184
|
||||
#: ../../dispatcher/router.rst:200
|
||||
msgid "The only root Router (Dispatcher) can handle this type of event."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:188
|
||||
#: ../../dispatcher/router.rst:204
|
||||
msgid ""
|
||||
"Dispatcher already has default handler for this event type, so you can "
|
||||
"use it for handling all updates that are not handled by any other "
|
||||
"handlers."
|
||||
msgstr ""
|
||||
|
||||
#: ../../dispatcher/router.rst:191
|
||||
#: ../../dispatcher/router.rst:207
|
||||
msgid "How it works?"
|
||||
msgstr "Як це працює?"
|
||||
|
||||
#: ../../dispatcher/router.rst:193
|
||||
#: ../../dispatcher/router.rst:209
|
||||
msgid ""
|
||||
"For example, dispatcher has 2 routers, the last router also has one "
|
||||
"nested router:"
|
||||
|
|
@ -276,7 +281,7 @@ msgstr ""
|
|||
msgid "Nested routers example"
|
||||
msgstr "Приклад вкладених маршрутизаторів"
|
||||
|
||||
#: ../../dispatcher/router.rst:198
|
||||
#: ../../dispatcher/router.rst:214
|
||||
msgid "In this case update propagation flow will have form:"
|
||||
msgstr "У цьому випадку потік розповсюдження оновлення матиме вигляд:"
|
||||
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -18,17 +18,9 @@ msgstr ""
|
|||
"Generated-By: Babel 2.12.1\n"
|
||||
|
||||
#: ../../../README.rst:3
|
||||
msgid "aiogram |beta badge|"
|
||||
msgid "aiogram"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:94
|
||||
msgid "Beta badge"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:6
|
||||
msgid "This version is still in development!"
|
||||
msgstr "Ще в розробці!"
|
||||
|
||||
#: ../../../README.rst:-1
|
||||
msgid "MIT License"
|
||||
msgstr ""
|
||||
|
|
@ -61,7 +53,7 @@ msgstr "Тести"
|
|||
msgid "Codecov"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:40
|
||||
#: ../../../README.rst:37
|
||||
msgid ""
|
||||
"**aiogram** is a modern and fully asynchronous framework for `Telegram "
|
||||
"Bot API <https://core.telegram.org/bots/api>`_ written in Python 3.8 "
|
||||
|
|
@ -74,39 +66,27 @@ msgstr ""
|
|||
"<https://docs.python.org/3/library/asyncio.html>`_ та `aiohttp "
|
||||
"<https://github.com/aio-libs/aiohttp>`_."
|
||||
|
||||
#: ../../../README.rst:45
|
||||
#: ../../../README.rst:42
|
||||
msgid "Make your bots faster and more powerful!"
|
||||
msgstr "Зробіть своїх ботів швидшими та потужнішими!"
|
||||
|
||||
#: ../../../README.rst:50
|
||||
#: ../../../README.rst:47
|
||||
msgid "Documentation:"
|
||||
msgstr "Документація"
|
||||
|
||||
#: ../../../README.rst:48
|
||||
#: ../../../README.rst:45
|
||||
msgid "🇺🇸 `English <https://docs.aiogram.dev/en/dev-3.x/>`_"
|
||||
msgstr "🇺🇸 `English <https://docs.aiogram.dev/en/dev-3.x/>`_"
|
||||
|
||||
#: ../../../README.rst:49
|
||||
#: ../../../README.rst:46
|
||||
msgid "🇺🇦 `Ukrainian <https://docs.aiogram.dev/uk_UA/dev-3.x/>`_"
|
||||
msgstr "🇺🇦 `Українською <https://docs.aiogram.dev/uk_UA/dev-3.x/>`_"
|
||||
|
||||
#: ../../../README.rst:54
|
||||
msgid "**Breaking News:**"
|
||||
msgstr "**Важливі новини**"
|
||||
|
||||
#: ../../../README.rst:56
|
||||
msgid "*aiogram* 3.0 has breaking changes."
|
||||
msgstr "*aiogram* 3.0 має зміни, що ламають зворотну сумісність."
|
||||
|
||||
#: ../../../README.rst:58
|
||||
msgid "It breaks backward compatibility by introducing new breaking changes!"
|
||||
msgstr "Порушує зворотну сумісність, вводячи нові критичні зміни!"
|
||||
|
||||
#: ../../../README.rst:61
|
||||
#: ../../../README.rst:50
|
||||
msgid "Features"
|
||||
msgstr "Особливості"
|
||||
|
||||
#: ../../../README.rst:63
|
||||
#: ../../../README.rst:52
|
||||
msgid ""
|
||||
"Asynchronous (`asyncio docs "
|
||||
"<https://docs.python.org/3/library/asyncio.html>`_, :pep:`492`)"
|
||||
|
|
@ -114,7 +94,7 @@ msgstr ""
|
|||
"Асинхронність (`asyncio docs "
|
||||
"<https://docs.python.org/3/library/asyncio.html>`_, :pep:`492`)"
|
||||
|
||||
#: ../../../README.rst:64
|
||||
#: ../../../README.rst:53
|
||||
msgid ""
|
||||
"Has type hints (:pep:`484`) and can be used with `mypy <http://mypy-"
|
||||
"lang.org/>`_"
|
||||
|
|
@ -122,20 +102,20 @@ msgstr ""
|
|||
"Має анотації типів (:pep:`484`) та може використовуватись з `mypy <http"
|
||||
"://mypy-lang.org/>`_"
|
||||
|
||||
#: ../../../README.rst:65
|
||||
#: ../../../README.rst:54
|
||||
msgid "Supports `PyPy <https://www.pypy.org/>`_"
|
||||
msgstr "Працює з `PyPy <https://www.pypy.org/>`_"
|
||||
|
||||
#: ../../../README.rst:66
|
||||
#: ../../../README.rst:55
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
"Supports `Telegram Bot API 6.7 <https://core.telegram.org/bots/api>`_ and"
|
||||
"Supports `Telegram Bot API 6.8 <https://core.telegram.org/bots/api>`_ and"
|
||||
" gets fast updates to the latest versions of the Bot API"
|
||||
msgstr ""
|
||||
"Підтримує `Telegram Bot API 6.3 <https://core.telegram.org/bots/api>`_ та"
|
||||
" швидко отримує оновлення до нових версії АПІ"
|
||||
|
||||
#: ../../../README.rst:67
|
||||
#: ../../../README.rst:56
|
||||
msgid ""
|
||||
"Telegram Bot API integration code was `autogenerated "
|
||||
"<https://github.com/aiogram/tg-codegen>`_ and can be easily re-generated "
|
||||
|
|
@ -145,28 +125,28 @@ msgstr ""
|
|||
"/tg-codegen>`_ що надає змогу дуже легко оновлювати фреймворк до останніх"
|
||||
" версій АПІ"
|
||||
|
||||
#: ../../../README.rst:68
|
||||
#: ../../../README.rst:57
|
||||
msgid "Updates router (Blueprints)"
|
||||
msgstr "Має роутери подій (Blueprints)"
|
||||
|
||||
#: ../../../README.rst:69
|
||||
#: ../../../README.rst:58
|
||||
msgid "Has Finite State Machine"
|
||||
msgstr "Має вбудований кінцевий автомат"
|
||||
|
||||
#: ../../../README.rst:70
|
||||
#: ../../../README.rst:59
|
||||
msgid ""
|
||||
"Uses powerful `magic filters "
|
||||
"<https://docs.aiogram.dev/en/dev-3.x/dispatcher/filters/magic_filters.html"
|
||||
"#magic-filters>`"
|
||||
"<https://docs.aiogram.dev/en/latest/dispatcher/filters/magic_filters.html"
|
||||
"#magic-filters>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:71
|
||||
#: ../../../README.rst:60
|
||||
msgid "Middlewares (incoming updates and API calls)"
|
||||
msgstr ""
|
||||
"Підтримує мідлвари (для вхідних подій від АПІ та для вихідних запитів до "
|
||||
"АПІ)"
|
||||
|
||||
#: ../../../README.rst:72
|
||||
#: ../../../README.rst:61
|
||||
msgid ""
|
||||
"Provides `Replies into Webhook <https://core.telegram.org/bots/faq#how-"
|
||||
"can-i-make-requests-in-response-to-updates>`_"
|
||||
|
|
@ -175,13 +155,13 @@ msgstr ""
|
|||
"<https://core.telegram.org/bots/faq#how-can-i-make-requests-in-response-"
|
||||
"to-updates>`_"
|
||||
|
||||
#: ../../../README.rst:73
|
||||
#: ../../../README.rst:62
|
||||
msgid "Integrated I18n/L10n support with GNU Gettext (or Fluent)"
|
||||
msgstr ""
|
||||
"Має вбудовану інтеграцію для використання інтернаціоналізації та "
|
||||
"локалізації GNU Gettext (або Fluent)"
|
||||
|
||||
#: ../../../README.rst:78
|
||||
#: ../../../README.rst:67
|
||||
msgid ""
|
||||
"It is strongly advised that you have prior experience working with "
|
||||
"`asyncio <https://docs.python.org/3/library/asyncio.html>`_ before "
|
||||
|
|
@ -191,39 +171,39 @@ msgstr ""
|
|||
"починати використовувати цей фреймворк. `asyncio "
|
||||
"<https://docs.python.org/3/library/asyncio.html>`_"
|
||||
|
||||
#: ../../../README.rst:82
|
||||
#: ../../../README.rst:71
|
||||
msgid "If you have any questions, you can visit our community chats on Telegram:"
|
||||
msgstr "Якщо є якість додаткові запитання, ласкаво просимо до онлайн-спільнот:"
|
||||
|
||||
#: ../../../README.rst:84
|
||||
#: ../../../README.rst:73
|
||||
msgid "🇺🇸 `@aiogram <https://t.me/aiogram>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:85
|
||||
#: ../../../README.rst:74
|
||||
msgid "🇺🇦 `@aiogramua <https://t.me/aiogramua>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:86
|
||||
#: ../../../README.rst:75
|
||||
msgid "🇺🇿 `@aiogram_uz <https://t.me/aiogram_uz>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:87
|
||||
#: ../../../README.rst:76
|
||||
msgid "🇰🇿 `@aiogram_kz <https://t.me/aiogram_kz>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:88
|
||||
#: ../../../README.rst:77
|
||||
msgid "🇷🇺 `@aiogram_ru <https://t.me/aiogram_ru>`_"
|
||||
msgstr "💩 `@aiogram_ru <https://t.me/aiogram_ru>`_"
|
||||
|
||||
#: ../../../README.rst:89
|
||||
#: ../../../README.rst:78
|
||||
msgid "🇮🇷 `@aiogram_fa <https://t.me/aiogram_fa>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:90
|
||||
#: ../../../README.rst:79
|
||||
msgid "🇮🇹 `@aiogram_it <https://t.me/aiogram_it>`_"
|
||||
msgstr ""
|
||||
|
||||
#: ../../../README.rst:91
|
||||
#: ../../../README.rst:80
|
||||
msgid "🇧🇷 `@aiogram_br <https://t.me/aiogram_br>`_"
|
||||
msgstr ""
|
||||
|
||||
|
|
@ -237,3 +217,27 @@ msgstr "Зміст"
|
|||
|
||||
#~ msgid "[Telegram] aiogram live"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "aiogram |beta badge|"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "Beta badge"
|
||||
#~ msgstr ""
|
||||
|
||||
#~ msgid "This version is still in development!"
|
||||
#~ msgstr "Ще в розробці!"
|
||||
|
||||
#~ msgid "**Breaking News:**"
|
||||
#~ msgstr "**Важливі новини**"
|
||||
|
||||
#~ msgid "*aiogram* 3.0 has breaking changes."
|
||||
#~ msgstr "*aiogram* 3.0 має зміни, що ламають зворотну сумісність."
|
||||
|
||||
#~ msgid "It breaks backward compatibility by introducing new breaking changes!"
|
||||
#~ msgstr "Порушує зворотну сумісність, вводячи нові критичні зміни!"
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Uses powerful `magic filters "
|
||||
#~ "<https://docs.aiogram.dev/en/dev-3.x/dispatcher/filters/magic_filters.html"
|
||||
#~ "#magic-filters>`"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ msgid ""
|
|||
msgstr ""
|
||||
"Project-Id-Version: aiogram \n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2023-07-30 18:31+0300\n"
|
||||
"POT-Creation-Date: 2023-08-26 23:17+0300\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
|
|
@ -99,17 +99,24 @@ msgid ""
|
|||
"accessed via :code:`data[\"bot\"]`."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:46
|
||||
#: ../../migration_2_to_3.rst:43
|
||||
msgid ""
|
||||
"Now to skip pending updates, you should call the "
|
||||
":class:`aiogram.methods.delete_webhook.DeleteWebhook` method directly "
|
||||
"instead of passing :code:`skip_updates=True` to start polling method."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:47
|
||||
msgid "Filtering events"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:48
|
||||
#: ../../migration_2_to_3.rst:49
|
||||
msgid ""
|
||||
"Keyword filters can no more be used, use filters explicitly. (`Read more "
|
||||
"» <https://github.com/aiogram/aiogram/issues/942>`_)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:49
|
||||
#: ../../migration_2_to_3.rst:50
|
||||
msgid ""
|
||||
"In due to keyword filters was removed all enabled by default filters "
|
||||
"(state and content_type now is not enabled), so you should specify them "
|
||||
|
|
@ -118,19 +125,19 @@ msgid ""
|
|||
"use :code:`@router.message(F.photo)`"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:53
|
||||
#: ../../migration_2_to_3.rst:54
|
||||
msgid ""
|
||||
"Most of common filters is replaced by \"magic filter\". (:ref:`Read more "
|
||||
"» <magic-filters>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:54
|
||||
#: ../../migration_2_to_3.rst:55
|
||||
msgid ""
|
||||
"Now by default message handler receives any content type, if you want "
|
||||
"specific one just add the filters (Magic or any other)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:56
|
||||
#: ../../migration_2_to_3.rst:57
|
||||
msgid ""
|
||||
"State filter now is not enabled by default, that's mean if you using "
|
||||
":code:`state=\"*\"` in v2 then you should not pass any state filter in "
|
||||
|
|
@ -138,38 +145,38 @@ msgid ""
|
|||
"specify the state."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:59
|
||||
#: ../../migration_2_to_3.rst:60
|
||||
msgid ""
|
||||
"Added possibility to register per-router global filters, that helps to "
|
||||
"reduces the number of repetitions in the code and makes easily way to "
|
||||
"control for what each router will be used."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:65
|
||||
#: ../../migration_2_to_3.rst:66
|
||||
msgid "Bot API"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:67
|
||||
#: ../../migration_2_to_3.rst:68
|
||||
msgid ""
|
||||
"Now all API methods is classes with validation (via `pydantic "
|
||||
"<https://docs.pydantic.dev/>`_) (all API calls is also available as "
|
||||
"methods in the Bot class)."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:69
|
||||
#: ../../migration_2_to_3.rst:70
|
||||
msgid ""
|
||||
"Added more pre-defined Enums and moved into `aiogram.enums` sub-package. "
|
||||
"For example chat type enum now is :class:`aiogram.enums.ChatType` instead"
|
||||
" of :class:`aiogram.types.chat.ChatType`. (:ref:`Read more » <enums>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:72
|
||||
#: ../../migration_2_to_3.rst:73
|
||||
msgid ""
|
||||
"Separated HTTP client session into container that can be reused between "
|
||||
"different Bot instances in the application."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:74
|
||||
#: ../../migration_2_to_3.rst:75
|
||||
msgid ""
|
||||
"API Exceptions is no more classified by specific message in due to "
|
||||
"Telegram has no documented error codes. But all errors is classified by "
|
||||
|
|
@ -179,17 +186,17 @@ msgid ""
|
|||
"types>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:81
|
||||
#: ../../migration_2_to_3.rst:82
|
||||
msgid "Middlewares"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:83
|
||||
#: ../../migration_2_to_3.rst:84
|
||||
msgid ""
|
||||
"Middlewares can now control a execution context, e.g. using context "
|
||||
"managers (:ref:`Read more » <middlewares>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:84
|
||||
#: ../../migration_2_to_3.rst:85
|
||||
msgid ""
|
||||
"All contextual data now is shared between middlewares, filters and "
|
||||
"handlers to end-to-end use. For example now you can easily pass some data"
|
||||
|
|
@ -197,75 +204,102 @@ msgid ""
|
|||
"same way as in the handlers via keyword arguments."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:87
|
||||
#: ../../migration_2_to_3.rst:88
|
||||
msgid ""
|
||||
"Added mechanism named **flags**, that helps to customize handler behavior"
|
||||
" in conjunction with middlewares. (:ref:`Read more » <flags>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:92
|
||||
#: ../../migration_2_to_3.rst:93
|
||||
msgid "Keyboard Markup"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:94
|
||||
#: ../../migration_2_to_3.rst:95
|
||||
msgid ""
|
||||
"Now :class:`aiogram.types.inline_keyboard_markup.InlineKeyboardMarkup` "
|
||||
"and :class:`aiogram.types.reply_keyboard_markup.ReplyKeyboardMarkup` has "
|
||||
"no methods to extend it, instead you have to use markup builders "
|
||||
":class:`aiogram.utils.keyboard.ReplyKeyboardBuilder` and "
|
||||
":class:`aiogram.utils.keyboard.KeyboardBuilder` respectively (:ref:`Read "
|
||||
"more » <keyboard-builder>`)"
|
||||
"more » <Keyboard builder>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:102
|
||||
#: ../../migration_2_to_3.rst:103
|
||||
msgid "Callbacks data"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:104
|
||||
#: ../../migration_2_to_3.rst:105
|
||||
msgid ""
|
||||
"Callback data factory now is strictly typed via `pydantic "
|
||||
"<https://docs.pydantic.dev/>`_ models (:ref:`Read more » <callback-data-"
|
||||
"<https://docs.pydantic.dev/>`_ models (:ref:`Read more » <Callback data "
|
||||
"factory>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:109
|
||||
#: ../../migration_2_to_3.rst:110
|
||||
msgid "Finite State machine"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:111
|
||||
#: ../../migration_2_to_3.rst:112
|
||||
msgid ""
|
||||
"State filter will no more added to all handlers, you will need to specify"
|
||||
" state if you want"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:112
|
||||
#: ../../migration_2_to_3.rst:113
|
||||
msgid ""
|
||||
"Added possibility to change FSM strategy, for example if you want to "
|
||||
"control state for each user in chat topics instead of user in chat you "
|
||||
"can specify it in the Dispatcher."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:117
|
||||
#: ../../migration_2_to_3.rst:115
|
||||
msgid ""
|
||||
"Now :class:`aiogram.fsm.state.State` and "
|
||||
":class:`aiogram.fsm.state.StateGroup` don't have helper methods like "
|
||||
":code:`.set()`, :code:`.next()`, etc."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:118
|
||||
msgid ""
|
||||
"Instead of this you should set states by passing them directly to "
|
||||
":class:`aiogram.fsm.context.FSMContext` (:ref:`Read more » <Finite State "
|
||||
"Machine>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:120
|
||||
msgid ""
|
||||
"State proxy is deprecated, you should update the state data by calling "
|
||||
":code:`state.set_data(...)` and :code:`state.get_data()` respectively."
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:125
|
||||
msgid "Sending Files"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:119
|
||||
#: ../../migration_2_to_3.rst:127
|
||||
msgid ""
|
||||
"From now you should wrap sending files into InputFile object before send "
|
||||
"instead of passing IO object directly to the API method. (:ref:`Read more"
|
||||
" » <sending-files>`)"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:124
|
||||
#: ../../migration_2_to_3.rst:132
|
||||
msgid "Webhook"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:126
|
||||
#: ../../migration_2_to_3.rst:134
|
||||
msgid "Simplified aiohttp web app configuration"
|
||||
msgstr ""
|
||||
|
||||
#: ../../migration_2_to_3.rst:127
|
||||
#: ../../migration_2_to_3.rst:135
|
||||
msgid ""
|
||||
"By default added possibility to upload files when you use reply into "
|
||||
"webhook"
|
||||
msgstr ""
|
||||
|
||||
#~ msgid ""
|
||||
#~ "Callback data factory now is strictly"
|
||||
#~ " typed via `pydantic "
|
||||
#~ "<https://docs.pydantic.dev/>`_ models (:ref:`Read "
|
||||
#~ "more » <callback-data-factory>`)"
|
||||
#~ msgstr ""
|
||||
|
|
|
|||
|
|
@ -96,14 +96,14 @@ Keyboard Markup
|
|||
and :class:`aiogram.types.reply_keyboard_markup.ReplyKeyboardMarkup` has no methods to extend it,
|
||||
instead you have to use markup builders :class:`aiogram.utils.keyboard.ReplyKeyboardBuilder`
|
||||
and :class:`aiogram.utils.keyboard.KeyboardBuilder` respectively
|
||||
(:ref:`Read more » <keyboard-builder>`)
|
||||
(:ref:`Read more » <Keyboard builder>`)
|
||||
|
||||
|
||||
Callbacks data
|
||||
==============
|
||||
|
||||
- Callback data factory now is strictly typed via `pydantic <https://docs.pydantic.dev/>`_ models
|
||||
(:ref:`Read more » <callback-data-factory>`)
|
||||
(:ref:`Read more » <Callback data factory>`)
|
||||
|
||||
|
||||
Finite State machine
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
.. _keyboard-builder
|
||||
.. _Keyboard builder:
|
||||
|
||||
================
|
||||
Keyboard builder
|
||||
================
|
||||
|
|
|
|||
|
|
@ -3,7 +3,12 @@ import html
|
|||
import logging
|
||||
|
||||
from aiogram import Bot, Dispatcher, types
|
||||
from aiogram.filters import Command, CommandObject, ExceptionMessageFilter, ExceptionTypeFilter
|
||||
from aiogram.filters import (
|
||||
Command,
|
||||
CommandObject,
|
||||
ExceptionMessageFilter,
|
||||
ExceptionTypeFilter,
|
||||
)
|
||||
from aiogram.types import ErrorEvent
|
||||
|
||||
TOKEN = "42:TOKEN"
|
||||
|
|
|
|||
|
|
@ -45,6 +45,7 @@ dependencies = [
|
|||
"pydantic>=2.1.1,<3",
|
||||
"aiofiles~=23.1.0",
|
||||
"certifi>=2023.7.22",
|
||||
"typing-extensions~=4.7.1",
|
||||
]
|
||||
dynamic = ["version"]
|
||||
|
||||
|
|
@ -102,7 +103,6 @@ dev = [
|
|||
"pre-commit~=3.3.3",
|
||||
"towncrier~=23.6.0",
|
||||
"packaging~=23.0",
|
||||
"typing-extensions~=4.7.1",
|
||||
]
|
||||
|
||||
[project.urls]
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ from unittest.mock import sentinel
|
|||
import pytest
|
||||
|
||||
from aiogram.methods import GetMe, TelegramMethod
|
||||
from aiogram.types import User
|
||||
from aiogram.types import User, TelegramObject
|
||||
from tests.mocked_bot import MockedBot
|
||||
|
||||
|
||||
|
|
@ -16,10 +16,15 @@ class TestTelegramMethodRemoveUnset:
|
|||
[{"foo": "bar", "baz": sentinel.DEFAULT}, {"foo"}],
|
||||
],
|
||||
)
|
||||
def test_remove_unset(self, values, names):
|
||||
validated = TelegramMethod.remove_unset(values)
|
||||
@pytest.mark.parametrize("obj", [TelegramMethod, TelegramObject])
|
||||
def test_remove_unset(self, values, names, obj):
|
||||
validated = obj.remove_unset(values)
|
||||
assert set(validated.keys()) == names
|
||||
|
||||
@pytest.mark.parametrize("obj", [TelegramMethod, TelegramObject])
|
||||
def test_remove_unset_non_dict(self, obj):
|
||||
assert obj.remove_unset("") == ""
|
||||
|
||||
|
||||
class TestTelegramMethodCall:
|
||||
async def test_async_emit_unsuccessful(self, bot: MockedBot):
|
||||
|
|
|
|||
|
|
@ -1,4 +1,8 @@
|
|||
from aiogram.methods import Request, UnpinAllForumTopicMessages, UnpinAllGeneralForumTopicMessages
|
||||
from aiogram.methods import (
|
||||
Request,
|
||||
UnpinAllForumTopicMessages,
|
||||
UnpinAllGeneralForumTopicMessages,
|
||||
)
|
||||
from tests.mocked_bot import MockedBot
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -61,6 +61,7 @@ from aiogram.types import (
|
|||
PollOption,
|
||||
ProximityAlertTriggered,
|
||||
Sticker,
|
||||
Story,
|
||||
SuccessfulPayment,
|
||||
User,
|
||||
UserShared,
|
||||
|
|
@ -73,7 +74,6 @@ from aiogram.types import (
|
|||
VideoNote,
|
||||
Voice,
|
||||
WebAppData,
|
||||
Story,
|
||||
)
|
||||
from aiogram.types.message import ContentType, Message
|
||||
|
||||
|
|
@ -649,6 +649,7 @@ class TestMessage:
|
|||
[TEST_MESSAGE_CONTACT, SendContact],
|
||||
[TEST_MESSAGE_VENUE, SendVenue],
|
||||
[TEST_MESSAGE_LOCATION, SendLocation],
|
||||
[TEST_MESSAGE_STORY, ForwardMessage],
|
||||
[TEST_MESSAGE_NEW_CHAT_MEMBERS, None],
|
||||
[TEST_MESSAGE_LEFT_CHAT_MEMBER, None],
|
||||
[TEST_MESSAGE_INVOICE, None],
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ from typing import Any, Dict, NoReturn, Optional, Union
|
|||
import pytest
|
||||
from pydantic import BaseModel
|
||||
|
||||
from aiogram.dispatcher.event.bases import SkipHandler, UNHANDLED
|
||||
from aiogram.dispatcher.event.bases import UNHANDLED, SkipHandler
|
||||
from aiogram.dispatcher.event.handler import HandlerObject
|
||||
from aiogram.dispatcher.event.telegram import TelegramEventObserver
|
||||
from aiogram.dispatcher.router import Router
|
||||
|
|
@ -13,7 +13,6 @@ from aiogram.exceptions import UnsupportedKeywordArgument
|
|||
from aiogram.filters import Filter
|
||||
from aiogram.types import Chat, Message, User
|
||||
|
||||
|
||||
# TODO: Test middlewares in routers tree
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -19,3 +19,17 @@ class TestMagicFilter:
|
|||
result = magic.resolve(MyObject(text="123"))
|
||||
assert isinstance(result, dict)
|
||||
assert isinstance(result["match"], Match)
|
||||
|
||||
def test_operation_as_not_none(self):
|
||||
# Issue: https://github.com/aiogram/aiogram/issues/1281
|
||||
magic = F.cast(int).as_("value")
|
||||
|
||||
result = magic.resolve("0")
|
||||
assert result == {"value": 0}
|
||||
|
||||
def test_operation_as_not_none_iterable(self):
|
||||
# Issue: https://github.com/aiogram/aiogram/issues/1281
|
||||
magic = F.as_("value")
|
||||
|
||||
result = magic.resolve([])
|
||||
assert result is None
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue