removed import simplejson to remove deprecation warning, _get_response() now raises an exception. I think it is better to catch a SocketClosed than an AttributeError because response is set to None