feedparser
feedparser copied to clipboard
`ConnectionResetError` not handled
It seems that ConnectionResetError is not handled when opening the feed in parse():
try:
data = _open_resource(url_file_stream_or_string, etag, modified, agent, referrer, handlers, request_headers, result)
except urllib.error.URLError as error:
result.update({
'bozo': True,
'bozo_exception': error,
})
return result
both ConnectionResetError and urllib.error.URLError are subclasses of OSError. Catching ConnectionError would take care of a lot of cases.