Changeset 1735 for pykota/trunk

Show
Ignore:
Timestamp:
09/22/04 21:22:27 (20 years ago)
Author:
jalet
Message:

Just loop in case a network error occur

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/pykota/accounters/hardware.py

    r1734 r1735  
    2222# 
    2323# $Log$ 
     24# Revision 1.20  2004/09/22 19:22:27  jalet 
     25# Just loop in case a network error occur 
     26# 
    2427# Revision 1.19  2004/09/22 14:29:01  jalet 
    2528# Fixed nasty typo 
     
    101104 
    102105try : 
     106    from pysnmp.mapping.udp import SnmpOverUdpError 
    103107    from pysnmp.mapping.udp.role import Manager 
    104108    from pysnmp.proto.api import alpha 
     
    135139            try : 
    136140                tsp.sendAndReceive(req.berEncode(), (self.printerHostname, 161), (self.handleAnswer, req)) 
    137             except pysnmp.mapping.udp.SnmpOverUdpError, msg :     
    138                 raise PyKotaAccounterError, _("Network error while doing SNMP queries : %s") % msg 
     141            except SnmpOverUdpError, msg :     
     142                self.parent.filter.printInfo(_("Network error while doing SNMP queries : %s") % msg, "warn") 
    139143            tsp.close() 
    140144