We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7d31945 commit af6ecc9Copy full SHA for af6ecc9
scrapers/cim.py
@@ -43,9 +43,9 @@ def get_sections() -> Iterable[Tag]:
43
try:
44
with urlopen(CIM_URL, timeout=5) as cim_req:
45
soup = BeautifulSoup(cim_req.read().decode("utf-8"), "html.parser")
46
- except Exception as e:
47
- print(f"error in get_sections: {e}")
48
- raise e
+ except (URLError, socket.timeout) as error:
+ print(f"error in get_sections: {error}")
+ raise error
49
50
return (
51
item
0 commit comments