Commit Graph

239 Commits

Author SHA1 Message Date
Hasibul Kobir
ecab62ce84
Add support for both sync and async filters (#437)
* support for both sync and async filters

* Add whitespace for readability

* moving to handler.check for coroutine function

Ref: https://github.com/pyrogram/pyrogram/pull/437#discussion_r451626488

* add last line

Co-authored-by: Dan <14043624+delivrance@users.noreply.github.com>
2020-08-21 07:33:24 +02:00
Dan
834d34363f Merge branch 'develop' into asyncio-dev 2020-07-17 18:30:52 +02:00
Dan
74e5a5a5e1 Add Mention link 2020-07-08 23:37:24 +02:00
Dan
6dbd842106 Merge develop -> asyncio-dev 2020-04-03 17:19:06 +02:00
Dan
fa157b59f1 Add support for ChosenInlineResult objects 2020-04-03 17:15:28 +02:00
Dan
aa6c935d83 Merge develop -> asyncio-dev 2020-03-30 17:45:18 +02:00
Dan
1996fb1481 Update Copyright 2020-03-21 15:43:32 +01:00
Dan
51f88ef1bf Revert "Allow stop, restart and add/remove_handler to be non-blocking"
This reverts commit 8e9e8b4a
2020-02-01 16:05:58 +01:00
Dan
42c9bafa0c Update copyright notice 2020-02-01 14:04:33 +01:00
Dan
8e9e8b4ac4 Allow stop, restart and add/remove_handler to be non-blocking 2019-10-27 09:37:28 +01:00
Dan
c929ce3097 Merge develop -> asyncio 2019-10-27 08:59:07 +01:00
Dan
51cd186559 Fix group, channel and supergroup ChatPhoto downloads
Closes #326
2019-10-19 16:24:23 +02:00
Dan
a541bb45db Merge develop -> asyncio 2019-09-21 22:21:20 +02:00
Dan
91d3508c13 Rename encode/decode to encode/decode_file_id 2019-09-21 22:17:42 +02:00
Dan
92c1b48132 Fix FILE_REFERENCE_* errors for uploads 2019-09-21 22:13:02 +02:00
Dan
1cd94520bf Fix FILE_REFERENCE_* errors for downloads 2019-09-21 21:12:11 +02:00
Dan
826885a821 Merge develop -> asyncio 2019-09-14 20:42:06 +02:00
Dan
840a9d1cc7 Update ChatPhoto parser 2019-09-14 19:30:07 +02:00
Dan
928ce5d850 Merge develop -> asyncio 2019-09-08 19:27:37 +02:00
Dan
a015f998fa Revert "Stop instantiating logger objects and directly use the logging module"
This reverts commit 792068d7
2019-09-08 19:24:06 +02:00
Dan
8f0b8babc2 Merge develop -> asyncio 2019-09-08 13:26:10 +02:00
Dan
792068d7c8 Stop instantiating logger objects and directly use the logging module 2019-09-08 12:59:28 +02:00
Dan
481e4ee339 Set the updates workers pool from 1 to 4 2019-09-08 11:59:26 +02:00
Dan
96334e0dba Merge develop -> asyncio 2019-09-07 16:01:31 +02:00
Dan
047fe37860 Add support for scheduled messages 2019-09-07 15:56:46 +02:00
Dan
ce72a7edd9 Merge develop -> asyncio 2019-09-07 13:40:26 +02:00
Dan
fb771441ed Merge branch 'layer-104' into develop 2019-09-07 12:47:25 +02:00
Dan
7daf51af9b Split start() into reusable methods
This allows custom authorization processes to be implemented much more
easily. Refactors #281
2019-08-13 13:15:58 +02:00
Dan
7badcd38b4 Merge develop -> asyncio 2019-08-03 10:48:35 +02:00
Dan
adda199c77 Revert "Replace ensure_future usages to create_task"
This reverts commit 9940dd67
2019-08-03 10:37:48 +02:00
Dan
94603f1ff2 Replace create_task with ensure_future for compatibility 2019-08-03 10:36:57 +02:00
Dan
6bbd79db86 Update download_media and util methods to work with new file_id formats 2019-08-02 02:33:52 +02:00
Dan
64939e5289 Update Document file ids to make them compatible again with the Bot API
Telegram changed something server side on 29 July, 2019 starting
exactly at 04:00 AM UTC+1 (DST), logs say. Looks like Document file ids,
just like Photo-like ids, are going to change as well after all, if we
want to keep them compatible with the Bot API
2019-08-02 01:15:01 +02:00
Dan
aa135ea457 Reformat project 2019-08-01 19:11:43 +02:00
Dan
ad0f8284f6 Use the correct way to parse peer identifiers 2019-08-01 19:07:08 +02:00
Dan
8700e3a0f3 Fix some methods not being defined using async 2019-07-31 13:33:04 +02:00
Dan
0f9029202e Merge develop -> asyncio 2019-07-30 00:06:06 +02:00
Mendel E
02451ffeb5 Try/except handler.check()
Previously, when handler.check raised errors, it would be excepted by
the try on line 153, and would fail to loop through the rest of the
groups/handlers.
2019-07-29 07:31:07 -04:00
Dan
9940dd678f Replace ensure_future usages to create_task 2019-07-15 00:51:32 +02:00
Dan
385ab22b68 Rework Client.idle()
idle() is now static and doesn't stop the client anymore
2019-07-11 19:59:56 +02:00
Dan
fed8cbf87e Add new set_parse_mode utility method 2019-07-11 19:28:33 +02:00
Dan
d441f16879 Merge develop -> asyncio 2019-07-11 04:17:46 +02:00
Dan
2f07e7abc4 Rework user.status, add last_online_date and next_offline_date 2019-07-11 01:35:02 +02:00
Dan
8ef97f2177 Merge branch 'develop' into asyncio
# Conflicts:
#	pyrogram/client/methods/messages/edit_message_text.py
#	pyrogram/client/methods/messages/send_animation.py
#	pyrogram/client/methods/messages/send_audio.py
#	pyrogram/client/methods/messages/send_cached_media.py
#	pyrogram/client/methods/messages/send_document.py
#	pyrogram/client/methods/messages/send_message.py
#	pyrogram/client/methods/messages/send_photo.py
#	pyrogram/client/methods/messages/send_video.py
#	pyrogram/client/methods/messages/send_voice.py
#	pyrogram/client/parser/html.py
#	pyrogram/client/parser/markdown.py
#	pyrogram/client/types/input_message_content/input_text_message_content.py
2019-06-26 19:34:49 +02:00
Dan
f05e79e0f4 Update usages of Parser all around the library 2019-06-26 16:08:24 +02:00
Dan
656aa4a7ca Enable scheduling of more than 1 updates worker 2019-06-24 17:33:33 +02:00
Dan
633e11531a Fix coroutine scheduling when adding/removing handlers 2019-06-23 13:56:12 +02:00
Dan
84278f9cee Merge branch 'develop' into asyncio
# Conflicts:
#	pyrogram/client/ext/dispatcher.py
2019-06-22 00:49:13 +02:00
Dan
e7fffd2f76 Fix workers not running concurrently anymore after using a shared Lock 2019-06-22 00:45:49 +02:00
Dan
2ba445d21e Fix asyncio lock not being awaited properly 2019-06-21 21:48:35 +02:00