puresnmp
puresnmp copied to clipboard
Timeout takes too long if community string is incorrect
I've noticed when using an incorrect community string, a sent message never times out while waiting for a response (or it takes longer that I was willing to wait). Perhaps a sock.settimeout(2) or something similar should be added in the puresnmp.transport.send() function. It could also be made adjustable by adding a default argument in function calls.
I just submitted pull request #2 as an example of how I was about to resolve the issue. The ability to manipulate the default time-out value needs to be added into other function calls that use send().
#2 has been merged. I'll leave this open for now as the timeout value is not yet exposed to the top-level functions.