From: Oleg Broytman Date: Sun, 12 Nov 2023 13:49:28 +0000 (+0300) Subject: Fix(Py3): Some socket errors are reported as `OSError` X-Git-Tag: 5.0.0~48 X-Git-Url: https://git.phdru.name/?a=commitdiff_plain;ds=sidebyside;h=30b81f6ecef5e78c70e2700a9b2837fa8f081095;p=bookmarks_db.git Fix(Py3): Some socket errors are reported as `OSError` --- diff --git a/Robots/bkmk_rurllib_py3.py b/Robots/bkmk_rurllib_py3.py index aca07cd..2b73347 100644 --- a/Robots/bkmk_rurllib_py3.py +++ b/Robots/bkmk_rurllib_py3.py @@ -115,6 +115,11 @@ class robot_urllib_py3(robot_base): except RedirectException as e: return None, e.errcode, e.newurl, None, None + except OSError as e: + error = str(e) + self.log(' Error: %s' % error) + return error, None, None, None, None + except IOError as e: if (e[0] == "http error") and (e[1] == -1): error = None