Commit Graph

502 Commits

Author SHA1 Message Date
Dan
0ed38518e1 Some stickers don't have DocumentAttributeImageSize 2018-04-25 18:30:33 +02:00
Dan
e22f7896f8 Add incoming and outgoing filters 2018-04-25 17:44:09 +02:00
Dan
3e4135c8e1 New "outgoing" field to easily tell in/out messages apart 2018-04-25 15:27:16 +02:00
Dan
fefcb81dde Move object ids ot the top 2018-04-25 10:30:33 +02:00
Dan
9173c49938 Allow Filters.command to pass command and arguments
This is done by using the new "command" field in the Message type
2018-04-25 10:27:55 +02:00
Dan
e5de670d40 Allow Filters.regex to pass all matches (as list)
This is done by using the new "matches" field in the Message type
2018-04-25 09:33:44 +02:00
Dan
7a20c8bca8 Clean all types and add docs 2018-04-24 16:41:52 +02:00
Dan
6e78935857 Accommodate the new types 2018-04-24 16:08:33 +02:00
Dan
59bca1c109 Clean ChatMember type 2018-04-24 15:10:15 +02:00
Dan
c457fc6ae3 Clean ChatPhoto type 2018-04-24 15:07:32 +02:00
Dan
d8f7f3bcc9 Clean UserProfilePhotos type 2018-04-24 15:06:54 +02:00
Dan
a52d4846e6 Clean Venue type 2018-04-24 15:05:51 +02:00
Dan
ba254e6643 Clean Location type 2018-04-24 15:05:08 +02:00
Dan
d10326605f Clean Contact type 2018-04-24 15:04:25 +02:00
Dan
76980ffc96 Clean Sticker type 2018-04-24 15:02:58 +02:00
Dan
5f7dd681f4 Clean VideoNote type 2018-04-24 15:00:36 +02:00
Dan
48284e7629 Clean Voice type 2018-04-24 14:57:22 +02:00
Dan
be8f0ad765 Clean Video type 2018-04-24 14:55:29 +02:00
Dan
7765942fc9 Clean Document type 2018-04-24 14:52:43 +02:00
Dan
d5ebeef4be Clean Audio type 2018-04-24 14:50:23 +02:00
Dan
38621f8239 Clean PhotoSize type 2018-04-24 14:44:50 +02:00
Dan
fe0f30b2f9 Clean MessageEntity type 2018-04-24 14:40:49 +02:00
Dan
79c3c8c0dd Clean Message type 2018-04-24 14:38:46 +02:00
Dan
3609d37752 Clean Chat type 2018-04-23 19:25:38 +02:00
Dan
b8473c9f7f Clean User type 2018-04-23 19:00:20 +02:00
Dan
730d5e74f0 Clean Update type 2018-04-23 18:56:06 +02:00
Dan
50252caec3 Move pyrogram types outside and make them static 2018-04-23 18:50:58 +02:00
Dan
debc459686 Return the correct message type with forward_messages() 2018-04-23 18:33:20 +02:00
Dan
88f7b35120 Add support for empty messages 2018-04-23 18:16:32 +02:00
Dan
f6415cdc15 Allow passing msg ids as int in get_messages()
Also add support for empty messages
2018-04-23 18:15:51 +02:00
Dan
a2640775dc Allow passing msg ids as int in forward_messages() 2018-04-23 13:49:31 +02:00
Dan
3d9b1cd4b0 Enable logging using debug=True 2018-04-23 13:37:50 +02:00
Dan
7054310138 Add docstrings for workdir parameter 2018-04-22 12:41:50 +02:00
Eric Blundell
40b768e97c Make Client.signal_handler reentrant (#57) 2018-04-21 20:50:30 +02:00
Dan
ae98732b95 Add workdir parameter
This makes possible to define a custom working directory.
A working directory is used to store session files. Defaults to "."
2018-04-19 10:06:41 +02:00
Dan
d6448c2044 Handle STICKERSET_INVALID error 2018-04-18 16:39:42 +02:00
Dan
0bba5daea4 Update docstrings 2018-04-18 11:15:09 +02:00
Dan
9dff99cf36 Add set_name and emoji to Stickers 2018-04-17 15:17:40 +02:00
Dan
d78dfb4f9e Don't use raw functions when getting messages 2018-04-17 00:26:30 +02:00
Dan
ebe806e2b7 Add missing notice 2018-04-16 21:07:02 +02:00
Dan
f9b1d02af4 Set correct link for the Message type 2018-04-16 13:28:53 +02:00
Dan
a547eb6fa1 Update get_messages docstrings 2018-04-16 12:52:32 +02:00
Dan
e210b22aaa Fix wrong users when joining by link 2018-04-16 12:43:02 +02:00
Dan
f47f903f7f Make get_messages return the correct type 2018-04-16 12:42:31 +02:00
Dan
d0ddb63830 Use raw functions when getting messages 2018-04-16 12:19:04 +02:00
Dan
06685cfe15 Make edit_message_caption return the new type 2018-04-16 12:03:31 +02:00
Dan
fbc8cafe4d Make edit_message return the new type 2018-04-16 12:01:42 +02:00
Dan
20bd4fb605 Make send_contact return the new type 2018-04-16 11:56:52 +02:00
Dan
797e8ba4e9 Don't pass empty last_name or user_id, pass None instead 2018-04-16 11:56:43 +02:00
Dan
58c9f321b4 Make send_venue return the new type 2018-04-16 11:53:38 +02:00
Dan
4bbdadaa17 Don't pass an empty string, use None instead 2018-04-16 11:53:26 +02:00
Dan
cd9f44183e Make send_location return the new type 2018-04-16 11:51:32 +02:00
Dan
b4b5373505 Deprecate download_photo 2018-04-16 11:49:00 +02:00
Dan
d9b3d67126 Update download_media docstrings 2018-04-16 11:44:05 +02:00
Dan
fdac67de69 Rework download_media to accept the new Message type 2018-04-16 01:07:02 +02:00
Dan
6275a4003f Add mime_type, file_name and date to Sticker objects 2018-04-16 00:59:41 +02:00
Dan
ddfce4b7ea Add file_name, mime_type and date to VideoNote objects 2018-04-16 00:30:49 +02:00
Dan
f35d922c97 Add thumb, file_name and date to Voice type 2018-04-16 00:24:43 +02:00
Dan
7184710948 Add file_name and date fields to Video objects 2018-04-16 00:01:27 +02:00
Dan
44dda8550f Add date field to Document type 2018-04-15 23:54:46 +02:00
Dan
e08e2850ee Add thumb, date and file_name to Audio type 2018-04-15 23:51:10 +02:00
Dan
d5f3684310 Add date field for PhotoSize 2018-04-15 23:30:40 +02:00
Dan
d9fdd89c49 Add ChatPhoto to User objects 2018-04-15 22:28:08 +02:00
Dan
ab1d780a61 Add ChatPhoto to Chat objects 2018-04-15 22:23:58 +02:00
Dan
94c9e7c52b Add some TODOs 2018-04-14 21:55:23 +02:00
Dan
b705391f79 Enhance send_media_group by accepting file_ids 2018-04-14 21:48:15 +02:00
Dan
5e26ae1894 Enhance send_video_note by accepting file_ids 2018-04-14 20:49:16 +02:00
Dan
c52ecadb76 Enhance send_voice by accepting file_ids and URLs 2018-04-14 20:42:32 +02:00
Dan
1fdb3386ff Enhance send_video by accepting file_ids and URLs 2018-04-14 20:41:23 +02:00
Dan
4f615bd6dc Enhance send_sticker by accepting file_ids and URLs 2018-04-14 19:56:11 +02:00
Dan
8446129003 Enhance send_document by accepting file_ids and URLs 2018-04-14 19:48:15 +02:00
Dan
0dd5ebef80 Fix raw update handler throwing errors 2018-04-14 16:59:34 +02:00
Dan
e8193435a9 Fix service filter and add media filter 2018-04-14 14:02:48 +02:00
Dan
17259d1b7b Join threads before closing the connection 2018-04-13 19:09:00 +02:00
Dan
e3c70c84ba Merge branch 'master' into new-api 2018-04-13 18:55:20 +02:00
Dan
83c4ba8a78 Handle flood wait when getting dialogs chunks 2018-04-13 18:53:55 +02:00
Dan
70173adca9 Iterate over copies 2018-04-13 18:35:36 +02:00
Dan
2f52b0e144 Merge branch 'master' into new-api 2018-04-13 16:42:26 +02:00
Dan
75cbd18ede Add ability to re-fetch usernames and contacts 2018-04-13 16:41:20 +02:00
Dan
ebc34e71d3 Optimize imports 2018-04-13 16:30:19 +02:00
Dan
e05c6a76d5 Merge branch 'master' into new-api
# Conflicts:
#	pyrogram/client/client.py
#	pyrogram/client/utils.py
2018-04-13 16:29:39 +02:00
Dan
846b7ec710 Increase sync interval 2018-04-13 16:21:18 +02:00
Dan
077930f85e Lower offline sleep 2018-04-13 16:20:51 +02:00
Dan
973cb4b2b6 Make dialogs and contacts fetching smarter 2018-04-13 16:20:21 +02:00
Dan
d9aa2a3ab0 Fix channels ids 2018-04-13 15:40:35 +02:00
Dan
9631dc7780 Accommodate Syncer 2018-04-13 15:21:34 +02:00
Dan
b84628e01d Add syncer module 2018-04-13 15:20:47 +02:00
Dan
e38da08e25 Load peers from session file 2018-04-13 15:20:37 +02:00
Dan
2ad3e113a0 Add utils module 2018-04-13 15:17:21 +02:00
Dan
a4b6674d4d Add date field 2018-04-13 15:05:46 +02:00
Dan
01775d0bd7 Don't pass session_name 2018-04-13 15:03:46 +02:00
Dan
6dcdeda244 Make proxy loading simpler 2018-04-13 12:30:13 +02:00
Dan
346d3da175 Add more info in case of an error 2018-04-12 14:11:01 +02:00
Dan
98937dbc3b Update Docs 2018-04-11 23:18:17 +02:00
Dan
3f16390193 Update docstrings 2018-04-11 15:16:29 +02:00
Dan
b5f1d3a2a5 Update docstrings 2018-04-11 03:53:10 +02:00
Dan
472ed8e355 Document the new features 2018-04-11 03:16:48 +02:00
Dan
84b1e697bb Add phone_number field in users 2018-04-10 19:48:44 +02:00
Dan
c4f2906009 Add via_bot field in messages 2018-04-10 19:37:52 +02:00
Dan
847b8dd5d4 Add views field in messages 2018-04-10 19:30:55 +02:00