[크롤링] Yahoo Finance 404 Error
BeautifulSoup을 이용해 Yahoo Finance 데이터를 수신하려고 하는데 아래와 같이 404 에러가 발생 했다. ticker = 'AAPL' URL = 'https://finance.yahoo.com/quote/{0}/key-statistics?p={0}'.format(ticker) response = requests.get(URL) if response.status_code == 200: html = response.text soup = BeautifulSoup(html, 'lxml') print(soup) else: print(response.status_code) $ python3 test.py 404 코드를 아래와 같이 수정하여 위 문제를 해결 함. ticker = 'AAPL' URL..
2022.03.31