Commit graph

21 commits

Author SHA1 Message Date
Kostiantyn Kriuchkov
c516ea9d6a
Refactor and improve bot examples (#1256)
* Refactor and improve bot messages

Refactored bot code to use aiogram enumerations and enhanced chat messages with markdown beautifications for a more user-friendly display.

CommandStart() is now used instead of Command('start') for readability.

Furthermore, the bot's 'stop' command was improved, ensuring it executes appropriately during KeyboardInterrupt or SystemExit.

Additionally, the bot's logging was adjusted to output to sys.stdout for better logs' readability.

* Added Changelog

* Add guidance comments on obtaining bot tokens from environment variables

* Remove hardcoded tokens, opt for environment variable

* Remove unnecessary spaces and reorganize imports

* Fix error, switch default storage from Redis to Memory, and add logging to multibot example
2023-08-10 22:10:30 +03:00
Alex Root Junior
b311d59fce
Webhook docs (#1248)
* Added documentation for polling/webhook modes

* Added changelog

* Added changelog
2023-08-06 16:59:29 +03:00
Andrey
2dd019d486
Fix typo (#1164) 2023-04-17 00:31:33 +03:00
Alex Root Junior
46218b8696
Towncrier build 2023-02-19 18:10:11 +02:00
Alex Root Junior
0e0dbe7e59
Deprecate filters factory (#976)
* Deprecate filters factory

* Added changelog

* Update filters usage in docs and examples
2022-08-14 18:40:41 +03:00
Alex Root Junior
4315ecf1a2
Dev 3.x flat package (#961)
* Move packages

* Added changelog

* Update examples/echo_bot.py

Co-authored-by: Oleg A. <t0rr@mail.ru>

* Rename `handler` -> `handlers`

* Update __init__.py

Co-authored-by: Oleg A. <t0rr@mail.ru>
2022-08-14 01:07:52 +03:00
Alex Root Junior
286cf39c8a
Beta 3 (#884)
* Rework middlewares, separate management to `MiddlewareManager` class

* Rework middlewares

* Added changes description for redis

* Added changes description for redis

* Fixed tests with Redis // aioredis replacement

* Changed msg.<html/md>_text attributes behaviour

* Added changelog for spoilers

* Added possibility to get command magic result as handler arguments
2022-04-16 19:07:32 +03:00
Gabben
a37bbba38c
Fix docs and examples (#864)
* Update magic_data Allowed handlers

* Fix ChatMemberUpdated example

* Fix examples with `.in_(...)` and delete with `@`

* Fix commands in examples

* Change List to Set
2022-03-26 17:30:46 +02:00
Alex Root Junior
f022b4441c Added more aliases, refactor CallbackData factory, added base exceptions classification mechanism 2021-05-25 00:56:44 +03:00
Alex Root Junior
4008a3114d
Upgrade architecture + 5.0 Bot API (#469)
Upgrade architecture + 5.0 Bot API (#469)
* Moved `methods`, `types` and `client` to root package
* Removed update handler from routers to dispatcher
* Reworked events propagation mechanism to handlers
* Reworked inner middlewares logic (very small change)
* Updated to Bot API 5.0
* Initial migration from MkDocs to Sphinx + config for readthedocs
2021-01-26 21:20:52 +02:00
jrootjunior
65815e509f Clean obsolete code and change configs 2019-11-15 12:44:24 +02:00
Suren Khorenyan
3867b72df6 Refactor examples/echo_bot.py 2019-08-10 00:08:11 +03:00
Alex Root Junior
9f13e11e6b Bump examples, docs and executor (nothing) 2018-10-28 19:35:06 +02:00
Alex Root Junior
06df482061 Partial update examples. 2018-07-14 16:28:20 +03:00
Alex Root Junior
ef3b59c63c Typo 'pooling' -> 'polling'. 2017-11-21 00:53:53 +02:00
Alex Root Junior
801ca1558e Upd examples. 2017-11-19 01:05:50 +02:00
Alex Root Junior
986ffa0ebd Annotate another eecution method in example echo bot. 2017-09-16 20:00:00 +03:00
Alex Root Junior
c19890a7d2 Oops. Invalid example. This method is already deprecated. 2017-08-01 00:41:43 +03:00
Alex Root Junior
2192d4b7ea handler(message: types.Message) 2017-06-03 10:53:13 +03:00
Alex Root Junior
92b3e027db Refactoring. AIOGramBot -> Bot and allow to use 'from aiogram import Bot' 2017-06-02 05:09:09 +03:00
Alex Root Junior
2fdd804114 Add example. Simple Echo bot. 2017-05-27 03:11:20 +03:00