Added exception handling to the connect_server method
This pull request eliminates the boolean that was returned by the connect_server method and raises exceptions when errors occur.
Different errors are mapped to different exceptions types (see errors.py ) with custom error messages according to the action that raised the error.
setdefauttimeout is added before ssl.get_server_certificate, to handle cases when the server name exists but is not the correct one (doesn't correspond to a blindai server)
Debug mode allows seeing the whole error traceback and the original exception.
To do after validation
Edit documentation accordingly
Decide wether to raise exceptions in the other methods also, or to edit reply.ok to false (as it is right now)
Added exception handling to the connect_server method
This pull request eliminates the boolean that was returned by the connect_server method and raises exceptions when errors occur.
setdefauttimeout
is added before ssl.get_server_certificate, to handle cases when the server name exists but is not the correct one (doesn't correspond to a blindai server)To do after validation