junzis / pyModeS

Python decoder for Mode S and ADS-B signals
GNU General Public License v3.0
546 stars 153 forks source link

AttributeError: 'NoneType' object has no attribute 'put' #78

Closed imanolpg closed 4 years ago

imanolpg commented 4 years ago

I have copied the code to customize the streaming module shown in the README file but I get this error:

Traceback (most recent call last):
  File "/usr/local/lib/python3.7/site-packages/pyModeS/extra/tcpclient.py", line 263, in run
    received = [i for i in self.socket.recv(4096)]
  File "zmq/backend/cython/socket.pyx", line 791, in zmq.backend.cython.socket.Socket.recv
  File "zmq/backend/cython/socket.pyx", line 827, in zmq.backend.cython.socket.Socket.recv
  File "zmq/backend/cython/socket.pyx", line 191, in zmq.backend.cython.socket._recv_copy
  File "zmq/backend/cython/socket.pyx", line 186, in zmq.backend.cython.socket._recv_copy
  File "zmq/backend/cython/checkrc.pxd", line 20, in zmq.backend.cython.checkrc._check_rc
zmq.error.Again: Resource temporarily unavailable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/projectPath/main.py", line 33, in <module>
    client.run()
  File "/usr/local/lib/python3.7/site-packages/pyModeS/extra/tcpclient.py", line 287, in run
    exception_queue.put(tb)
AttributeError: 'NoneType' object has no attribute 'put'

Hoping it was a python error I have launched modeslive --source rtlsdr in terminal and I get this output befor exiting

Found Rafael Micro R820T tuner
[R82XX] PLL not locked!
Exact sample rate is: 2000000.052982 Hz

I have used the module pyrtlsdr with no problem and I am able to use the dongle with Gqrx app

junzis commented 4 years ago

Should be fixed with commit 0ced97e now. You can install the version from the main branch and try again.