import requests from bs4 import BeautifulSoup def create_soup(url): header = {"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.45 Safari/537.36"} res = requests.get(url, headers=header) res.raise_for_status() soup = BeautifulSoup(res.text, "lxml") return soup def scrape_weather(): url = "https://search.naver.com/search.naver?sm=tab_h..