You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Aborting connection: Server shutdown
Exception in callback _SelectorSocketTransport._call_connection_lost(None)
handle: <Handle _SelectorSocketTransport._call_connection_lost(None)>
Traceback (most recent call last):
File "/usr/lib/python3.7/asyncio/events.py", line 88, in _run
self._context.run(self._callback, *self._args)
File "/usr/lib/python3.7/asyncio/selector_events.py", line 916, in _call_connection_lost
super()._call_connection_lost(exc)
File "/usr/lib/python3.7/asyncio/selector_events.py", line 690, in _call_connection_lost
self._protocol.connection_lost(exc)
File "/home/.../.local/lib/python3.7/site-packages/aiocoap/transports/tcp.py", line 167, in connection_lost
self._ctx._dispatch_error(self, exc)
File "/home/.../.local/lib/python3.7/site-packages/aiocoap/transports/tcp.py", line 259, in _dispatch_error
if self._tokenmanager is None:
AttributeError: 'TCPClient' object has no attribute '_tokenmanager'
The reason this was not found in automated tests was because aiocoap-client didn't do proper shutdown. Now on to the underlying issue -- the change you proposed does fix it, but now the lack of proper shutdown for TCP connections start spitting warnings, fixing that.
The following code:
results in
This is apparently caused by the use of
del
inaiocoap/aiocoap/transports/tcp.py
Line 406 in f819627
That variable should probably be set to
None
instead.The text was updated successfully, but these errors were encountered: