Closed do-me closed 3 years ago
Update: Working again but sometimes still displaying the same issue as in #19 : "unknown document received":
ERROR:root:[ignored]
Traceback (most recent call last):
File "C:\Users\dome\Anaconda3\lib\site-packages\torpy\utils.py", line 78, in newfn
return func(*args, **kwargs)
File "C:\Users\dome\Anaconda3\lib\site-packages\torpy\consesus.py", line 168, in renew
raise Exception('Unknown document has been received')
Exception: Unknown document has been received
WARNING:torpy.utils:Retry with another authority...
ERROR:torpy.utils:[ignored] torpy.documents.network_status.FetchDescriptorError: Can't fetch descriptor from http://<someip>:8080/tor/server/fp/<somehash>
WARNING:torpy.utils:Retry with another router...
Update 2: It's really odd, sometimes it's only working on Windows, sometimes only on Ubuntu. Does anyone have an idea where the OS differences come from?
I have a newly setup windows 10 installation and it returns a very similar error when I run your code block:
ERROR:torpy.cell_socket:timed out
ERROR:root:[ignored]
Traceback (most recent call last):
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\cell_socket.py", line 63, in connect
self._socket.connect((self._router.ip, self._router.or_port))
File "C:\Users\leond\anaconda3\lib\ssl.py", line 1342, in connect
self._real_connect(addr, False)
File "C:\Users\leond\anaconda3\lib\ssl.py", line 1329, in _real_connect
super().connect(addr)
socket.timeout: timed out
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\utils.py", line 78, in newfn
return func(*args, **kwargs)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 152, in renew
raw_string = self.download_consensus(prev_hash)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 306, in download_consensus
with self._get_auth_dir_client() as dir_client:
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 287, in _get_auth_dir_client
return self._auth_dir_circuit.create_dir_client()
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\utils.py", line 60, in __get__
value = obj.__dict__[self.func.__name__] = self.func(obj)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 283, in _auth_dir_circuit
self._auth_guard, circuit = self._create_dir_circuit(authority=True, purpose='Consensus/PublicKeys downloader')
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 278, in _create_dir_circuit
guard = TorGuard(router, purpose=purpose)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\guard.py", line 66, in __init__
self.__tor_socket.connect()
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\cell_socket.py", line 69, in connect
raise TorSocketConnectError(e)
torpy.cell_socket.TorSocketConnectError: timed out
WARNING:torpy.utils:Retry with another authority...
ERROR:root:[ignored]
Traceback (most recent call last):
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\utils.py", line 78, in newfn
return func(*args, **kwargs)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 171, in renew
raise Exception('Invalid consensus')
Exception: Invalid consensus
WARNING:torpy.utils:Retry with another authority...
ERROR:root:[ignored]
Traceback (most recent call last):
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\utils.py", line 78, in newfn
return func(*args, **kwargs)
File "C:\Users\leond\anaconda3\lib\site-packages\torpy\consesus.py", line 171, in renew
raise Exception('Invalid consensus')
Exception: Invalid consensus
WARNING:torpy.utils:Retry with another authority...
Does it currently work on Ubuntu for you?
Around 18 hours ago it only worked on Windows and not on Ubuntu. Otherwise until now I noticed it generally works better on Ubuntu (if it works at all). At the moment no OS is working for me.
Because of errors and not optimal logic inside torpy tor authority server was under high traffic load. And was trying to block torpy. See https://gitlab.torproject.org/tpo/core/tor/-/issues/33018 for details.
445bc22 should fix this
do you guys still have the same issue ?
do you guys still have the same issue ?
Tor V2 is deprecated, this library won't work until it supports Tor V3
Torpy is not running anymore on Windows. The following minimal example always results in a timeout.
Returns:
If on Jupyter, it returns the Windows Error code as well
ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host