constverum / ProxyBroker

Proxy [Finder | Checker | Server]. HTTP(S) & SOCKS :performing_arts:
http://proxybroker.readthedocs.io
Apache License 2.0
3.82k stars 1.08k forks source link

UserWarning: Not found judges for the protocol (proxybroker\checker.py:105) #127

Open Danil-e opened 5 years ago

Danil-e commented 5 years ago

Suddenly, a warning began to appear and the checker stopped working (only the parser). Reinstalling packages and even a python did not help. Console: ...\proxybroker\checker.py:105: UserWarning: Not found judges for the ['HTTP', 'HTTPS'] protocol. Checking proxy on protocols ['HTTP', 'CONNECT:80', 'SOCKS4', 'SOCKS5', 'HTTPS', 'SMTP'] is disabled. UserWarning,

DarKWinGTM commented 5 years ago

Have same issue how to make it auto retry when found this Warning ?

MikeZ77 commented 5 years ago

Getting the same warning as well. Tried handling it but havn't found anything that works so far.

MikeZ77 commented 5 years ago

Have same issue how to make it auto retry when found this Warning ?

This is the way I am handling it:

    try: 
        loop = asyncio.get_event_loop()
        loop.run_until_complete(asyncio.wait_for(task, 30))
    except asyncio.TimeoutError:
        print("RETRYING PROXIES ...")

Pass wait_for() the task that runs the coroutines and the number of seconds to wait. From the documentation:

If a timeout occurs, it cancels the task and raises asyncio.TimeoutError