I need to write a small bit of code that will print an error if I cannot resolve the name to IP.
I see that you can use the "socket.gethostbyaddr" methods but I cant seem to find a simple method/exception for when it does not find an IP address.
Also if I change the timeout on this would it affect the dns timeout`s for the whole machine ?
Or is there a simpler method ?
Thanks,