【发布时间】:2021-12-29 02:05:26
【问题描述】:
我的代码如下:
import requests
import urllib
from bs4 import BeautifulSoup
year_url = r"https://www.sec.gov/Archives/edgar/daily-index/2020/index.json"
year_content = requests.get(year_url)
decoded_year_url = year_content.json()
去年我可以运行完全相同的代码,但是当我昨天运行它时,弹出了警告: “JSONDecodeError:预期值:第 1 行第 1 列(字符 0)” 为什么?我应该如何解决问题?非常感谢!
【问题讨论】:
-
print(year_content.text),输出:We do not offer technical support for developing or debugging scripted downloading processes出错 -
网站不想为机器人服务。