Commit Graph

128 Commits

Author SHA1 Message Date
Lonami Exo
934c733ccb Treat users "kicking themselves" as leaving (#1116) 2019-02-27 19:42:17 +01:00
Lonami Exo
f540c4e089 Fix order of inline results not being preserved 2019-02-14 20:03:02 +01:00
Lonami Exo
628a16f287 Document new errors and limits for inline results 2019-02-14 19:45:25 +01:00
Lonami Exo
5ac88f764d Fix and update links in the documentation 2019-01-12 13:06:14 +01:00
Lonami Exo
d31aaa5d0d Make Message.edit respect preview and buttons 2019-01-12 12:45:37 +01:00
Lonami Exo
09f994c105 Except TypeError on empty access hash from 5018879 thoroughly 2018-12-18 08:39:36 +01:00
Lonami Exo
4a8a85d7a6 Refetch ChatAction service message to get input users 2018-11-28 18:59:49 +01:00
Lonami Exo
d214c78bd0 Add missing @property decorator 2018-11-19 12:06:18 +01:00
Lonami Exo
e5fc9d8674 Fix several broken links in the docs 2018-10-17 11:50:11 +02:00
Lonami Exo
a9a2401e44 Fix CallbackQuery using string regex 2018-10-17 11:44:08 +02:00
Lonami Exo
74f7ae525f Document InlineBuilder 2018-10-12 12:38:46 +02:00
Manuel1510
2468b32fc5 Implement next_offset and allow empty results in answer() (#1017) 2018-10-04 09:12:12 +02:00
Lonami Exo
ec0aa65fe1 An user -> a user 2018-09-22 19:18:42 +02:00
Lonami Exo
d5d3733fd4 Create events.register and siblings for "handler templates"
This can be thought of as a different approach to Flask's blueprints.
2018-09-22 12:51:58 +02:00
Lonami Exo
5e13a6f7a8 Fix-up get_message failing for UpdateInlineBotCallbackQuery 2018-09-19 16:42:22 +02:00
Lonami Exo
ac59cfa25b Return chat from inline queries that "don't have it" 2018-09-19 16:40:35 +02:00
Lonami Exo
2f09e5c335 Support custom-callback filter for all events 2018-09-09 15:48:54 +02:00
Lonami Exo
576ac666d9 Fix resolving events while disconnected 2018-08-27 01:20:01 +02:00
Lonami Exo
fbc46bd388 Use loop.create_future instead asyncio.Future 2018-08-21 12:22:06 +02:00
Lonami Exo
d3a6822fc9 Properly resolve events 2018-08-21 12:18:12 +02:00
Lonami Exo
47190d7d55 Fix event loop not being passed into many asyncio calls 2018-08-21 11:31:14 +02:00
Lonami Exo
d474458136 Simplify event resolving logic
Although this commit introduces a race condition since an
event may only be half-resolved. A lock is thus needed,
but it depends on an event-loop to which we don't have
access in the class-level.
2018-08-21 11:08:08 +02:00
Lonami Exo
f4b9c9d6d4 Remove critical code from assert statements 2018-08-14 19:14:13 +02:00
Lonami Exo
96742334a4 Fix incoming = outgoing = True not working 2018-07-29 13:03:10 +02:00
Lonami Exo
7b22c72c3e Use UTC timezone for events.UserUpdate 2018-07-24 20:38:38 +02:00
Lonami Exo
1c0d595205 Replace custom.Message creation with ._finish_init 2018-07-22 19:20:55 +02:00
Lonami Exo
7f78d7ed2f Use classmethod for all Event.build 2018-07-19 01:47:32 +02:00
Lonami Exo
2d7c8908eb Create events.InlineQuery 2018-07-15 11:31:24 +02:00
Lonami Exo
8b4c8d30e7 Fix events.MessageDeleted setting readonly properties 2018-07-11 11:34:20 +02:00
Lonami Exo
1d0fd6801d Build events only once per update 2018-07-11 11:22:43 +02:00
Lonami Exo
f6c45dcc63 Support filtering events.CallbackQuery 2018-07-10 17:59:13 +02:00
Lonami Exo
05e8e60291 Create events.CallbackQuery 2018-07-10 17:59:13 +02:00
Lonami Exo
8eecd9c226 Reuse code to get chat and sender 2018-07-10 17:59:13 +02:00
Lonami Exo
3a9cce8720 Add missing async/await to events' documentation 2018-07-08 15:11:10 +02:00
Lonami Exo
72835dfb44 Update to v1.0 2018-06-27 13:41:20 +02:00
Lonami Exo
75dc4809f5 Remove all deprecated methods 2018-06-26 11:10:11 +02:00
Lonami Exo
c1046c2acc Fix "user joined" being "user added itself" 2018-06-25 13:21:23 +02:00
Lonami Exo
410518aa65 Stop using await with properties 2018-06-25 11:38:56 +02:00
Lonami Exo
efc9f4c414 Get rid of all remaining async properties 2018-06-25 11:03:20 +02:00
Lonami Exo
266d44dd86 Fix EventsCommon still having async properties 2018-06-24 13:05:58 +02:00
Lonami Exo
1a1d9d346c Fix most private messages being outgoing since 56ddaae
56ddaae checked to_id and from_id to compare if they were equal,
and if they were, mark the event as outgoing for convenience in
your private chat (saved messages).

However when reconstructing the Message from UpdateShortMessage
to_id didn't mimic 100% Telegram's behaviour (the chat to which
the message is sent is "different" depending on who sent the
messages). This bug is what actually caused most messages to
be outgoing, even though 56ddaae's logic is correct.
2018-06-22 10:25:20 +02:00
Lonami Exo
f733f8e565 Rewrite the first part of the docs for asyncio 2018-06-21 21:54:54 +02:00
Lonami Exo
9e3f6483e8 Fix pattern= and move pattern_match to events.NewMessage 2018-06-20 20:03:44 +02:00
Lonami Exo
c893eaaa84 Allow filtering new messages by sender/forwards 2018-06-20 11:58:44 +02:00
Lonami Exo
c85ba4accc Revisit documentation, cross-references and unnecessary indents 2018-06-20 11:06:03 +02:00
Lonami Exo
56ddaaee6f Make non-fwded messages sent to yourself outgoing 2018-06-16 17:35:24 +02:00
Lonami Exo
24d2074e0c Set _input_chat on custom.Message creation/fixup input_chat 2018-06-14 23:40:44 +02:00
Lonami Exo
f95400ea7e Try again to get input_chat on EventsCommon 2018-06-14 23:26:04 +02:00
Lonami Exo
179af9894f Add missing parenthesis around await 2018-06-14 22:25:03 +02:00
Lonami Exo
908dfa148b Revisit codebase to add missing async/await 2018-06-14 17:09:20 +02:00