Answer the question
In order to leave comments, you need to log in
Why does a 407 socks python error occur?
I am writing an asynchronous apishka to tg.
question.
proxy = (socks.HTTP, 'host', port, 'login', 'password')
tg = TG(
sessionFile=os.path.join(config.SESSIONS, str(data['session_file'])),
apiId=int(data['app_id']),
apiHash=str(data['app_hash']),
proxy=proxy,
deviceModel=str(data['device']),
appVersion=str(data['app_version']),
langCode=str(data['system_lang_pack']).split('-')[0]
)
Attempt 1 at connecting failed: ConnectionError: [Errno Proxy error: 407 Proxy Authentication Required] Could not connect to proxy хххххххх:ххххх [407]
Attempt 2 at connecting failed: ConnectionError: [Errno Proxy error: 407 Proxy Authentication Required] Could not connect to proxy хххххххх:ххххх [407]
Attempt 3 at connecting failed: ConnectionError: [Errno Proxy error: 407 Proxy Authentication Required] Could not connect to proxy хххххххх:ххххх [407]
←[32mINFO←[0m: 127.0.0.1:52364 - "←[1mPOST /api/v1/sendMessage HTTP/1.1←[0m" ←[32m200 OK←[0m
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question