mirror of
https://github.com/TeamPGM/pyrogram.git
synced 2024-11-16 12:51:18 +00:00
Make Client.signal_handler reentrant (#57)
This commit is contained in:
parent
6e8077df2b
commit
40b768e97c
@ -810,7 +810,6 @@ class Client:
|
||||
log.debug("{} stopped".format(name))
|
||||
|
||||
def signal_handler(self, *args):
|
||||
self.stop()
|
||||
self.is_idle = False
|
||||
|
||||
def idle(self, stop_signals: tuple = (SIGINT, SIGTERM, SIGABRT)):
|
||||
@ -830,6 +829,8 @@ class Client:
|
||||
while self.is_idle:
|
||||
time.sleep(1)
|
||||
|
||||
self.stop()
|
||||
|
||||
def send(self, data: Object):
|
||||
"""Use this method to send Raw Function queries.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user