Maybe `ssl_version=ssl.PROTOCOL_SSLv23` here, for clarity, since `2 != ssl.PROTOCOL_SSLv2`.