Bug 8631 - Crash in tlwebadm "sessions" if vsmserver is down
Summary: Crash in tlwebadm "sessions" if vsmserver is down
Status: NEW
Alias: None
Product: ThinLinc
Classification: Unclassified
Component: Web Administration (show other bugs)
Version: trunk
Hardware: PC Unknown
: P2 Normal
Target Milestone: ---
Assignee: Bugzilla mail exporter
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2025-07-04 14:28 CEST by Pierre Ossman
Modified: 2025-07-04 14:28 CEST (History)
0 users

See Also:
Acceptance Criteria:


Attachments

Description Pierre Ossman cendio 2025-07-04 14:28:20 CEST
If the vsmserver service is unreachable, then visiting Status > Sessions in tlwebadm results in a 500 error page, and this in the log:

> 'GET /status/sessions HTTP/1.1' 500 -
> ----------------------------------------
> Exception happened during processing of request from ('::ffff:127.0.0.1', 65148, 0, 0)
> Traceback (most recent call last):
>   File "/opt/thinlinc/modules/thinlinc/forkingserver.py", line 62, in process_request
>     self . finish_request ( request , client_address )
>     ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/httpserver.py", line 479, in finish_request
>     super ( ) . finish_request ( request , client_address )
>     ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/tlstunnel.py", line 71, in finish_request
>     self . TLSRequestHandlerClass ( request , client_address , self )
>     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/httpserver.py", line 83, in __init__
>     super ( ) . __init__ ( request , client_address , server )
>     ~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/usr/lib64/python3.13/socketserver.py", line 766, in __init__
>     self.handle()
>     ~~~~~~~~~~~^^
>   File "/opt/thinlinc/modules/thinlinc/httpserver.py", line 446, in handle
>     super ( ) . handle ( )
>     ~~~~~~~~~~~~~~~~~~~^^^
>   File "/usr/lib64/python3.13/http/server.py", line 436, in handle
>     self.handle_one_request()
>     ~~~~~~~~~~~~~~~~~~~~~~~^^
>   File "/opt/thinlinc/modules/thinlinc/httpserver.py", line 163, in handle_one_request
>     super ( ) . handle_one_request ( )
>     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^
>   File "/usr/lib64/python3.13/http/server.py", line 424, in handle_one_request
>     method()
>     ~~~~~~^^
>   File "/opt/thinlinc/modules/thinlinc/tlwebadm/server.py", line 165, in do_GET
>     self . post_or_get ( "do_GET" , ooOOOoOO0 )
>     ~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/tlwebadm/server.py", line 179, in post_or_get
>     oO00o00OO , iIi1 = getattr ( OoOo00 , action ) ( i1iI1i , query , oO00o00OO )
>                        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/tlwebadm/main.py", line 132, in do_GET
>      IiII = self . _content_to_bytes (
>             ~~~~~~~~~~~~~~~~~~~~~~~~~^
>     page_name ,
>     ^^^^^^^^^^^
>     self . _GET_METHODS . get ( page_name , self . error_404 ) ( query ) )
>     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/tlwebadm/main.py", line 111, in _content_to_bytes
>     return self . _render_page ( page_name , content ) . encode ( 'utf-8' )
>            ~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^
>   File "/opt/thinlinc/modules/thinlinc/tlwebadm/main.py", line 104, in _render_page
>     return str ( self . _main_page )
>   File "/opt/thinlinc/modules/thinlinc/Cheetah/Template.py", line 1057, in __unicode__
>     return getattr(self, mainMethName)()
>            ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
>   File "_opt_thinlinc_share_tlwebadm_templates_main_tmpl.py", line 121, in respond
>   File "/opt/thinlinc/modules/thinlinc/Cheetah/Filters.py", line 131, in filter
>     output = super(MaxLen, self).filter(val, **kw)
>   File "/opt/thinlinc/modules/thinlinc/Cheetah/Filters.py", line 40, in filter
>     return unicode(val)
>   File "/opt/thinlinc/modules/thinlinc/Cheetah/Template.py", line 1057, in __unicode__
>     return getattr(self, mainMethName)()
>            ~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
>   File "_opt_thinlinc_share_tlwebadm_templates_status_sessions_tmpl.py", line 178, in respond
> TypeError: '>' not supported between instances of 'NoneType' and 'int'
> ----------------------------------------

Unsure if this is a regression. The most likely code has been there since the start, so probably not.

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