From 97c8b1ce5d45a05567ed01d545cb43174a2dcbb9 Mon Sep 17 00:00:00 2001 From: Kondrahin Anton Date: Tue, 26 Oct 2021 12:17:26 +0300 Subject: [PATCH] feat: Add embed_mentions argument in answer_message method (#215) --- botx/bots/mixins/sending.py | 5 ++++- docs/changelog.md | 7 +++++++ pyproject.toml | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/botx/bots/mixins/sending.py b/botx/bots/mixins/sending.py index 5d290891..da2d93ff 100644 --- a/botx/bots/mixins/sending.py +++ b/botx/bots/mixins/sending.py @@ -120,6 +120,7 @@ async def answer_message( # noqa: WPS211 file: Optional[Union[BinaryIO, TextIO, File]] = None, markup: Optional[MessageMarkup] = None, options: Optional[MessageOptions] = None, + embed_mentions: bool = False, ) -> UUID: """Answer on incoming message and return id of new message.. @@ -133,7 +134,8 @@ async def answer_message( # noqa: WPS211 markup: bubbles and keyboard that can be attached to the message. options: additional message options, like mentions or notifications configuration. - metadata: dict of message metadata + metadata: dict of message metadata. + embed_mentions: get mentions from text. Returns: `UUID` of sent event. @@ -144,6 +146,7 @@ async def answer_message( # noqa: WPS211 markup=markup, options=options, metadata=metadata, + embed_mentions=embed_mentions, ) if file: sending_message.add_file(file) diff --git a/docs/changelog.md b/docs/changelog.md index dcdca128..2f6954f4 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,3 +1,10 @@ +## 0.25.1 (Oct 22, 2021) + +### Changed + +* Add `embed_mentions` argument in `answer_message` method. + + ## 0.25.0 (Sep 17, 2021) ### Added diff --git a/pyproject.toml b/pyproject.toml index bfbbfb94..1e74dcea 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "botx" -version = "0.25.0" +version = "0.25.1" description = "A little python framework for building bots for eXpress" license = "MIT" authors = [