Anorov/PySocks

It doesn't work on Brook and Trojan?

GJCav opened this issue · 0 comments

GJCav commented

When a Brook(https://github.com/txthinking/brook) or Trojan(https://github.com/trojan-gfw/trojan) client is running in my local machine, it provides a SOCKS5 service for my apps.
While my Chrome works perfectly, my program using PySocks doesn't work.
The debug model of Brook reveals that none of data is received and the Trojan reminds that 0 byte is received.
My program looks like this:

import requests as R
pxy = { 'https': 'socks5://127.0.0.1:2080', 'http': 'socks5://127.0.0.1:2080' }
R.get('https://www.google.com/', timeout=10, proxies=pxy)

But always, a timeout exception is raised even the timeout is far more enough and the two SOCKS5 providers just indicate that they receive 0 bytes.

More detailed, for Brook client, the negotiate and request processes are working normally but then it remains stuck.