mirror of
https://github.com/tiennm99/mtprotoproxy.git
synced 2026-10-13 00:14:54 +00:00
add debugging signal
This commit is contained in:
1 parent
b74079c433
commit
5f35b4ed0a
1 file changed
+8
@@ -12,6 +12,7 @@ import binascii
|
||||
import sys
|
||||
import re
|
||||
import runpy
|
||||
import signal
|
||||
|
||||
try:
|
||||
import uvloop
|
||||
@@ -65,6 +66,13 @@ except (ValueError, OSError):
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
|
||||
def debug_signal(signum, frame):
|
||||
import pdb
|
||||
pdb.set_trace()
|
||||
|
||||
signal.signal(signal.SIGUSR1, debug_signal)
|
||||
|
||||
if len(sys.argv) > 1:
|
||||
config = runpy.run_path(sys.argv[1])
|
||||
else:
|
||||
|
||||
Reference in new issue
Block a user