puresnmp icon indicating copy to clipboard operation
puresnmp copied to clipboard

Timeout takes too long if community string is incorrect

Open sulbig opened this issue 8 years ago • 2 comments

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.

sulbig avatar Sep 12 '16 03:09 sulbig

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().

sulbig avatar Sep 12 '16 04:09 sulbig

#2 has been merged. I'll leave this open for now as the timeout value is not yet exposed to the top-level functions.

exhuma avatar Sep 12 '16 08:09 exhuma