shrimpy-python icon indicating copy to clipboard operation
shrimpy-python copied to clipboard

client.disconnect() not closing gracefully

Open TheConfax opened this issue 4 years ago • 1 comments

When client.disconnect() is called, an exception is raised:

Exception in thread Thread-1: Traceback (most recent call last): File "C:\Users\theco\AppData\Local\Programs\Python\Python39\lib\threading.py", line 950, in _bootstrap_inner self.run() File "C:\Users\theco\AppData\Local\Programs\Python\Python39\lib\threading.py", line 888, in run self._target(*self._args, **self._kwargs) File "C:\Users\theco\AppData\Local\Programs\Python\Python39\lib\site-packages\shrimpy\shrimpy_ws_client.py", line 92, in _run_socket_thread for task in asyncio.Task.all_tasks(): AttributeError: type object '_asyncio.Task' has no attribute 'all_tasks'

Any help on this?

TheConfax avatar Jan 05 '21 12:01 TheConfax

go to line 92 in "shrimpy_ws_client.py" then change 'asyncio.Task.all_tasks():' to 'asyncio.all_tasks():'

There is use of a deprecated function.

robokrishan avatar May 25 '21 19:05 robokrishan