Pastafarianist added the comment: I agree that the five exception types you mentioned (UnknownProtocol, UnknownTransferEncoding, IncompleteRead, BadStatusLine, LineTooLong) should be derived from IOError. EOFError is probably not a good choice here. It's not something I would expect to see in networking code. ValueError may be better, but I don't know enough about the library to tell whether it is common to use ValueError in similar contexts.
However, ImproperConnectionState (specifically, CannotSendRequest) may be not a programmer error, and, thus, it might be better to have it derived from IOError. See https://hg.python.org/cpython/file/3.5/Lib/http/client.py#l933. Depending on your point of view, you may consider this to be a programmer error or not. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue24788> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com