change assert is_controller_okay to log.warn and count the error
Created by: juga0
I think that we should not get that exception and instead log the error and count one more circuit error (if it is not already being count, i've not checked). @pastly: if it easy for you, would you do it?, otherwise i'll check:
[2018-06-15 16:58:51,788] [sbws.core.scanner] [ERROR] Unhandled exception in worker thread
Traceback (most recent call last):
File "/path/simple-bw-scanner/sbws/core/scanner.py", line 257, in dispatch_worker_thread
return measure_relay(*a, **kw)
File "/path/simple-bw-scanner/sbws/core/scanner.py", line 170, in measure_relay
cb.controller, conf.getfloat('general', 'http_timeout'))
File "/path/simple-bw-scanner/sbws/util/requests.py", line 7, in make_session
socks_info = stem_utils.get_socks_info(controller)
File "/path/simple-bw-scanner/sbws/util/stem.py", line 197, in get_socks_info
assert is_controller_okay(controller)
AssertionError
Also:
Traceback (most recent call last):
File "/path/.virtualenvs/simplebwscanner3/bin/sbws", line 11, in <module>
load_entry_point('sbws', 'console_scripts', 'sbws')()
File "/path/simple-bw-scanner/sbws/sbws.py", line 51, in main
exit(comm['f'](*comm['a'], **comm['kw']))
File "/path/simple-bw-scanner/sbws/core/scanner.py", line 402, in main
run_speedtest(args, conf)
File "/path/simple-bw-scanner/sbws/core/scanner.py", line 362, in run_speedtest
for target in rp.best_priority():
File "/path/simple-bw-scanner/sbws/lib/relayprioritizer.py", line 49, in best_priority
relays = copy.deepcopy(self.relay_list.relays)
File "/path/simple-bw-scanner/sbws/lib/relaylist.py", line 132, in relays
self._refresh()
File "/path/simple-bw-scanner/sbws/lib/relaylist.py", line 175, in _refresh
self._relays = self._init_relays()
File "/path/simple-bw-scanner/sbws/lib/relaylist.py", line 169, in _init_relays
assert stem_utils.is_controller_okay(c)