Lonami Exo
0f72aa8f94
Fix set union
2018-03-03 17:08:49 +01:00
Lonami Exo
96a1f580a4
Remove useless if condition on the memory session
2018-03-03 17:01:06 +01:00
Lonami Exo
81f8b7f76e
Add back _entity_values_to_row
2018-03-03 16:48:57 +01:00
Lonami Exo
57f50889b0
Fix non-aggressive get_participants and inverted condition
2018-03-03 15:12:48 +01:00
Lonami Exo
0e0e7f1c9e
Avoid unnecessary "or 0" in the session classes
2018-03-03 14:59:30 +01:00
Lonami Exo
6060b3430c
Fix sqlite session clone causing integrity error
...
Triggered on migrations, the dc id would be None.
2018-03-03 14:02:48 +01:00
Lonami Exo
67a782a6d7
Fix wrong peer type being used when not found in the session
2018-03-03 12:22:02 +01:00
Lonami Exo
a9c83250a1
Small clean-up of the session classes
2018-03-03 12:51:35 +01:00
Lonami Exo
1e420f7f91
Document the new abstract session better
2018-03-03 12:13:42 +01:00
Lonami
30f7a49263
Abstract Session class (merge #657 from tulir/sessions)
2018-03-03 11:33:47 +01:00
Tulir Asokan
9bf5cb7ed8
Add new sessions docs
2018-03-03 12:28:18 +02:00
Lonami Exo
74bffd2ae3
Support multiple captions when sending albums
2018-03-02 21:33:49 +01:00
Lonami Exo
2e31a686e8
Upgrade to layer 75
...
Captions are now "messages" and also support message entities.
2018-03-02 21:28:33 +01:00
Tulir Asokan
290afd85fc
Fix AlchemySession session table updating
2018-03-02 21:58:16 +02:00
Tulir Asokan
47cdcda9e2
Move device info out of Session
2018-03-02 21:05:09 +02:00
Tulir Asokan
5e88b21aa9
Use single quotes
2018-03-02 20:42:51 +02:00
Tulir Asokan
f805914c80
Handle SQLAlchemy import errors
2018-03-02 20:40:03 +02:00
Tulir Asokan
c1a8896faa
Fix SQLAlchemy implementation
2018-03-02 20:14:11 +02:00
Tulir Asokan
dc2229fdba
Move salt and ID to base session and remove unused imports
2018-03-02 18:39:04 +02:00
Lonami Exo
a7f98fd3cc
Ignore bad file descriptor while closing
2018-03-02 17:26:42 +01:00
Tulir Asokan
e1d7cc541f
Add setters for non-persistent values that apps might change
2018-03-02 18:23:18 +02:00
Tulir Asokan
03d4ab3765
Fix create_engine check
2018-03-02 13:25:40 +02:00
Tulir Asokan
07c2fc50ec
Add SQLAlchemy-based session
2018-03-02 13:22:30 +02:00
Tulir Asokan
118d9b10e8
Add more abstraction
2018-03-02 13:20:11 +02:00
Tulir Asokan
d9a73744a4
Remove old sqlite session variables and clone code
2018-03-02 12:36:39 +02:00
Tulir Asokan
df3faaeb7f
Fix abstract Session method ordering
2018-03-02 11:11:59 +02:00
Lonami Exo
4c7224e56a
Fix n might be None when stopping workers
2018-03-02 10:10:59 +01:00
Tulir Asokan
4c64d53e71
Move non-persistent stuff to base Session class
2018-03-02 11:10:11 +02:00
Tulir Asokan
c5e6f7e265
Split Session into three parts and make a module for sessions
2018-03-01 23:40:28 +02:00
Lonami Exo
f09ab6c6b6
Fix-up 771c573
to properly stop background update workers
...
The "special" StopIteration object didn't actually make any sense.
Instead looping forever, workers now loop while there are workers,
so that they stop looping once the count is cleared.
Dummy values are still inserted so that they don't need to timeout
on the queue before exiting (these values are None) so in essence,
this keeps the best of both of worlds.
2018-03-01 20:13:21 +01:00
Lonami Exo
3a3f221bd1
Look in all dialogs when getting entities by peer ID
2018-03-01 20:03:51 +01:00
Lonami Exo
771c573db1
Better attempt at joining update worker threads
2018-03-01 13:31:39 +01:00
Lonami Exo
3d68c879dd
Avoid using undefined variable in the README.rst
2018-03-01 13:25:38 +01:00
Joscha Götzer
835ff51e25
Multiple small changes/fixed typos to docs/error messages ( #623 )
2018-03-01 13:21:28 +01:00
Joscha Götzer
3184641549
Allow access to events' pattern match ( #654 )
2018-03-01 00:15:30 +01:00
Lonami Exo
3655df50dc
Postpone events resolution
2018-02-28 21:09:05 +01:00
Lonami Exo
3afd7dca84
Invoke multiple getParticipant's at the same time ( #580 )
2018-02-28 17:10:44 +01:00
Lonami Exo
057c6a0b12
Support getting more than 10k members on .get_participants()
...
Discussed on #580 , original PR made on #639 .
2018-02-28 13:24:44 +01:00
Lonami Exo
229cd78df0
Fix markdown's URL regex not acceping newlines
2018-02-27 14:10:02 +01:00
Lonami Exo
d5832e4f3b
Fix time offset failing if system time was ahead of time
...
While the offset was working, the last message ID was never reset,
so it would always pick an higher message ID (safety check), which
completely defeated the purpose of negative time offsets. Should
close #496 .
2018-02-27 11:43:42 +01:00
Joscha Götzer
0b662f3b04
Support stopping propagation of events ( #622 )
2018-02-27 11:30:42 +01:00
Lucas Yuji Suguinoshita Aciole
29f10f2771
Fix named arguments after kwargs ( #646 )
...
In Python3, you're unable to send named parameters after **kwargs
* Use single quotes
2018-02-27 10:05:27 +01:00
Lonami Exo
8d1b6629cb
Sending open()'ed files would make their name the entire path
2018-02-26 14:14:44 +01:00
Lonami Exo
5a54e2279f
Avoid relying on .__iter__ to tell iterators apart
...
.send_file() would fail with stream objects (those from open())
since they are iterable, and asserting that they weren't bytes
or str was not enough.
2018-02-26 14:12:21 +01:00
Lonami Exo
6f16aeb553
Add logging calls on the TcpClient
2018-02-26 13:41:07 +01:00
Lonami Exo
9604161c91
Fix incoming private messages not working with whitelists
...
For some reason this was only happening with bots and not
actual private messages. The fix doesn't seem to affect
previous behaviour with actual users in private messages.
2018-02-26 12:15:53 +01:00
Lonami Exo
3b0ab7794b
Get name attribute from streams instead always 'unnamed'
2018-02-25 20:35:55 +01:00
Lonami Exo
623c1bd7d1
Add missing parameters to TelegramClient.send_voice_note
2018-02-25 20:34:40 +01:00
Lonami Exo
098602ca13
Let events.Raw.resolve() be a no-op
2018-02-25 10:36:53 +01:00
Lonami Exo
cfc5ecfded
Fix tiny bug regarding .get_me(input_peer=True) crashing events
2018-02-25 10:35:39 +01:00