Bug 5665 - often incorrect log message in VSMXMLRPCCall exception handler
Summary: often incorrect log message in VSMXMLRPCCall exception handler
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: Other (show other bugs)
Target Milestone: 4.16.0
Assignee: Pierre Ossman
Keywords: prosaic
Depends on:
Reported: 2015-10-01 16:37 CEST by Pierre Ossman
Modified: 2023-11-29 12:56 CET (History)
2 users (show)

See Also:
Acceptance Criteria:


Description Pierre Ossman cendio 2015-10-01 16:37:10 CEST

2015-10-01 15:42:11 ERROR vsmserver.session: Unhandled exception trying to unbind ports for display 1 on VSM Agent <type 'exceptions.TypeError'> 'NoneType' object has no attribute '__getitem__' Tr
aceback (most recent call last):
  File "/opt/thinlinc/modules/thinlinc/vsm/async.py", line 112, in iii11
    obj . handle_read_event ( )
  File "/usr/lib64/python2.7/asyncore.py", line 449, in handle_read_event
  File "/usr/lib64/python2.7/asynchat.py", line 147, in handle_read
  File "/opt/thinlinc/modules/thinlinc/vsm/xmlrpc.py", line 405, in found_terminator
    self . handle_response ( )
  File "/opt/thinlinc/modules/thinlinc/vsm/xmlrpc.py", line 437, in handle_response
    self . handle_returnvalue ( )
  File "/opt/thinlinc/modules/thinlinc/vsm/call_unbindports.py", line 41, in handle_returnvalue
    self . callback ( )
  File "/opt/thinlinc/modules/thinlinc/vsm/loginhandler_common.py", line 71, in run_sessionscripts
    self . send_response ( )
  File "/opt/thinlinc/modules/thinlinc/vsm/loginhandler_common.py", line 88, in send_response
    oOOoo ) [ 'sessionkey' ]
TypeError: 'NoneType' object has no attribute '__getitem__'
. Marking agent as down.

The crash had nothing to do with unbinding ports, but is presented that way only because of the way we stack callbacks on top of each other.

Not sure there's an easy fix for this. We would probably have to redesign things to avoid this nesting.
Comment 1 Pierre Ossman cendio 2015-10-06 10:38:45 CEST
A very simple solution is to change the message to something more generic, like "Unhandled exception:".
Comment 2 Pierre Ossman cendio 2023-11-20 17:01:55 CET
This got resolved when we redesigned things in bug 8224.

There is no longer any manually added description text for context, as these kinds of things will be handled by a common, generic exception handler.

Fortunately, the stacks are also a lot shallower in the new system, so you shouldn't have to filter the tracebacks as much for what's relevant.
Comment 3 Frida cendio 2023-11-29 12:56:12 CET
Tested this, and it got fixed by the redesign in 8224.

Note You need to log in before you can comment on or make changes to this bug.