Open imsanjoykb opened 2 years ago
import requests from urllib.error import HTTPError url = 'https://www.geeksforgeeks.org/implementing-web-scraping-python-beautiful-soup/amp/' try: response = requests.get(url) response.raise_for_status() except HTTPError as hp: print(hp) else:
print("it's worked")