Handling exceptions with Py2 and Py3

Pavlos Parissis pavlos.parissis at gmail.com
Fri May 27 08:24:38 EDT 2016


Hi,

So, we have ConnectionRefusedError in Python3 but not in Python2.
Six module doesn't provide a wrapper about this.

What is most efficient way to handle this situation in a try-catch block?

Cheers,
Pavlos

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://mail.python.org/pipermail/python-list/attachments/20160527/f5ed9aed/attachment.sig>


More information about the Python-list mailing list