[issue24788] HTTPException is derived from Exception instead of IOError

Pastafarianist report at bugs.python.org
Tue Aug 4 22:10:42 CEST 2015


New submission from Pastafarianist:

In both Python 2 and Python 3, HTTPException is derived from Exception. This is not quite convenient, since catching all connection-related errors while performing an HTTP query requires catching both IOError (which is subclassed by socket.error) and HTTPException. It might be better to change the parent class to IOError instead.

----------
components: Library (Lib)
messages: 247995
nosy: Pastafarianist
priority: normal
severity: normal
status: open
title: HTTPException is derived from Exception instead of IOError
type: enhancement
versions: Python 3.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue24788>
_______________________________________


More information about the Python-bugs-list mailing list