Skip to content
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion web_programming/fetch_well_rx_price.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def fetch_pharmacy_and_price_list(drug_name: str, zip_code: str) -> list | None:

return pharmacy_price_list

except httpx.HTTPError, ValueError:
except (httpx.HTTPError, ValueError):
return None


Expand Down
2 changes: 1 addition & 1 deletion web_programming/instagram_crawler.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def get_json(self) -> dict:
scripts = BeautifulSoup(html, "html.parser").find_all("script")
try:
return extract_user_profile(scripts[4])
except json.decoder.JSONDecodeError, KeyError:
except (json.decoder.JSONDecodeError, KeyError):
return extract_user_profile(scripts[3])

def __repr__(self) -> str:
Expand Down