From 4fe9f5e79e96b614d818701d8d710a4a31172807 Mon Sep 17 00:00:00 2001 From: pauget Date: Sun, 2 Oct 2005 15:27:00 +0200 Subject: [PATCH] Distinction des problmes rencontrs lors de l'interrogation des switchs. darcs-hash:20051002132700-41617-b0ac177321821147575d30b079e62ff19baa72b3.gz --- gestion/whos.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/gestion/whos.py b/gestion/whos.py index df486f57..7ae92bcc 100755 --- a/gestion/whos.py +++ b/gestion/whos.py @@ -709,7 +709,7 @@ def prise_etat(chbre) : f = u'' try: # On met aussi l'état - from hptools import sw_chbre + from hptools import sw_chbre, ConversationError prise = sw_chbre(chbre) f += u'prise %s' % prise.prise_brute rows, cols = get_screen_size() @@ -748,10 +748,12 @@ def prise_etat(chbre) : f+= u', ' + coul(u'prise désactivée','rouge') else : f+= u', activée, lien non détecté' + except ConversationError: + # Switch non manageable ou down + f = u'info prise non dispo : erreur de communication' except : - # Switch non manageable - f = u'informations prise non disponibles' - + f = u'info prise non dispo : erreur prog' + return f ##############################################################################