Lonami Exo
5c17097d8d
Clean up .get_entity and remove force_fetch
2017-12-27 11:56:05 +01:00
Lonami Exo
86429e7291
Lowercase usernames before adding them to the database
2017-12-27 11:54:08 +01:00
Lonami Exo
aef96f1b68
Remove custom EntityDatabase and use sqlite3 instead
...
There are still a few things to change, like cleaning up the
code and actually caching the entities as a whole (currently,
although the username/phone/name can be used to fetch their
input version which is an improvement, their full version
needs to be re-fetched. Maybe it's a good thing though?)
2017-12-27 00:50:09 +01:00
Lonami Exo
0a4849b150
Small cleanup of the Session class
2017-12-26 16:59:30 +01:00
Lonami Exo
664417b409
Use sqlite3 instead JSON for the session files
2017-12-26 16:45:47 +01:00
Lonami Exo
b11c2e885b
Fix assertion for multiple same flag parameters
2017-12-25 18:00:24 +01:00
Tanuj
c218df87d7
Remove reference to README.rst ( #504 )
2017-12-25 17:26:29 +01:00
Lonami Exo
238198db5a
Create a convenient class to wrap Dialog instances
2017-12-24 16:18:09 +01:00
Lonami Exo
9c66f0b2b4
Fix empty strings not working as expected for flag parameters
2017-12-24 15:15:19 +01:00
Dmitry D. Chernov
fb9813ae61
TelegramClient.send_code_request(): Change logic of methods invocation
...
Before:
First call, force_sms=False: SendCodeRequest
Next call, force_sms=False: SendCodeRequest
First call, force_sms=True: raise ValueError
Next call, force_sms=True: ResendCodeRequest
That's inconvenient because the user must remember whether the code requested at all and whether the request was successful.
In addition, the repeated invocation of SendCodeRequest does nothing.
This commit changes logic to this:
First call, force_sms=False: SendCodeRequest
Next call, force_sms=False: ResendCodeRequest
First call, force_sms=True: SendCodeRequest, ResendCodeRequest
Next call, force_sms=True: ResendCodeRequest
2017-12-24 21:25:17 +10:00
Dmitry D. Chernov
4a2a64ce2f
TcpClient: Catch ConnectionError instead of its particular cases
...
That can be more reliable, especially in the case of using PySocks.
2017-12-23 05:45:23 +10:00
Lonami Exo
992017ddf8
Except ConnectionAbortedError on TcpClient
2017-12-22 11:27:57 +01:00
Lonami Exo
23ab70fc29
Remove unused request_msg_id from the TLObject class
2017-12-20 17:48:41 +01:00
Lonami Exo
c848ae0ace
Move tgread_object() outside specific msg processing calls
2017-12-20 17:45:40 +01:00
Lonami Exo
5842d3741b
Make a proper use of the logging module
2017-12-20 12:47:39 +01:00
Lonami Exo
7d189119f4
Fix salt migration failing with valid signed salts
2017-12-20 12:47:39 +01:00
Alihossein Shahabi
fd291fa014
Fix typo in sessions.rst ( #491 )
2017-12-14 12:16:57 +01:00
Lonami Exo
0e0bc6ecbc
Fix session ID is also signed since d4d7aa9
2017-12-07 12:22:40 +01:00
Lonami Exo
1d19bb22a5
Don't ignore NewSessionCreated salt
2017-12-04 20:34:35 +01:00
Lonami Exo
d4d7aa9063
Use signed salt
2017-12-03 21:10:22 +01:00
Lonami Exo
6662f49bcb
Remove another redundant if
2017-11-30 21:10:02 +01:00
Lonami Exo
21a93d58ec
Use a synchronized queue instead event/deque pair
2017-11-30 21:09:34 +01:00
Lonami Exo
7d7b2cb1fa
Remove redundant checks from UpdateState
2017-11-30 20:40:35 +01:00
Lonami Exo
d515ede7da
Fix TLParser not stripping inline comments
2017-11-30 13:34:55 +01:00
Lonami Exo
9046b46fcd
Document the network/ module
2017-11-30 13:21:01 +01:00
Lonami Exo
7509ba9067
Assert that module was generated correctly on setup.py pypi
2017-11-29 12:34:15 +01:00
Lonami Exo
605c103f29
Add unparse markdown method
2017-11-26 17:16:59 +01:00
Lonami Exo
57a70d0d47
Document the extensions/ module
2017-11-26 17:14:28 +01:00
Lonami Exo
71eb542626
Document the errors/ module
2017-11-26 17:06:09 +01:00
Lonami Exo
a932fb6470
Document the crypto/ module
2017-11-26 16:57:40 +01:00
Lonami Exo
74ec6391d9
Fix-up security assertion ( b42b4bb
for #453 )
2017-11-24 19:05:52 +01:00
Maxim Smirnov
b42b4bb326
Add OpenSSL assertion on authenticator.py ( #453 )
...
aes_ige.c(88): OpenSSL internal error, assertion failed
2017-11-24 18:47:36 +01:00
Dmitry D. Chernov
5a4d6d4a57
tlobject: Represent timestamp as 'int' instead of 'float'
2017-11-23 22:39:35 +10:00
Dmitry D. Chernov
f99d14558f
binary_reader: Parse TL 'date' to UTC datetime instead of local
2017-11-23 02:06:43 +10:00
Lonami Exo
7d4453351b
Update .gitignore to include docs/_build
2017-11-21 12:56:53 +01:00
Lonami
4e5dede7fe
Merge pull request #448 from jeffffc/master
...
Add readthedocs, transfer tutorials from wiki to there too
2017-11-21 12:53:58 +01:00
Lonami Exo
152856dfbc
Add a force_fetch parameter to .get_entity
2017-11-20 10:58:11 +01:00
Jeff
9f033be05a
fix in-docs links
2017-11-20 17:26:31 +08:00
Jeff
07d642a354
tiny fix for readthedocs
2017-11-20 13:58:42 +08:00
Jeff
d0c9324212
final fix for readthedocs
2017-11-20 12:19:53 +08:00
Jeff
f6ec7e47a7
add a bunch more readthedocs from wiki
2017-11-20 12:12:31 +08:00
Jeff
34e7ae026e
add requirements.txt for readthedocs
2017-11-20 01:04:51 +08:00
Jeff
231ecf3f2a
add readthedocs files
2017-11-20 00:56:05 +08:00
Lonami Exo
9767774147
Fix import in markdown parser not being relative
2017-11-17 15:57:48 +01:00
Lonami Exo
01f55200f2
Update to v0.15.5
2017-11-16 19:18:26 +01:00
Lonami Exo
346c5bb303
Add method to md parser to extract text surrounded by entities
2017-11-16 19:13:13 +01:00
Lonami Exo
e5deaf5db8
Fix c4e07cf
, md parsing adding unfinished entity at wrong offset
2017-11-16 19:07:53 +01:00
Lonami Exo
4ddbc78699
Ensure IPv6 addresses are surrounded by '[]' ( #425 )
2017-11-16 13:47:15 +01:00
Lonami Exo
edd73ed69a
Allow switching from IPv4 to IPv6 and vice versa
2017-11-16 13:40:25 +01:00
Vladislav Kolesnichenko
ee5915e86d
Add support for connecting through IPv6 ( #425 for #112 )
2017-11-16 13:30:18 +01:00