Menu

#7 better info for snmp error 'errorReportReceived'

open
nobody
None
5
2011-08-09
2011-08-09
Anonymous
No

In pysnmp/proto/mpmod/frc3412.py is a dictionary with well known error oids implemented (_snmpErrors).
Any oid not defined in this dictionary creates the default text 'errorReportReceived', the oid itself gets lost.
It would be helpful to add the oid to this text, eg.
errorIndication=_snmpErrors.get(
varBinds[0][0], 'errorReportReceived %r'%(varBinds[0][0],)

This helps a lot for debugging. It is never a good idea to throw away valuable information.

Discussion