Message291126
create_connection will try multiple times to connect if there are multiple addresses returned by getaddrinfo. If all connections file it inspects the exceptions, and raises the first one if they are all equal. But since the addresses are often different (else why would we try multiple times?), the messages will usually be different. When the messages are different, the code raises an OSError with a list of the exceptions so the user can see them all. This, however, looses the information as to *what* kind of exception occurred (ie: ConnectioRefusedError, etc).
I propose that if all of the exceptions raised are of the same subclass, that that subclass be raised with the multi-message list, rather than the base OSError. |
|
Date |
User |
Action |
Args |
2017-04-04 17:12:21 | r.david.murray | set | recipients:
+ r.david.murray, yselivanov |
2017-04-04 17:12:21 | r.david.murray | set | messageid: <1491325941.34.0.941861469291.issue29980@psf.upfronthosting.co.za> |
2017-04-04 17:12:21 | r.david.murray | link | issue29980 messages |
2017-04-04 17:12:21 | r.david.murray | create | |
|