Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

一直得到418 #22

Open
jackcoolpython opened this issue Jul 10, 2020 · 1 comment
Open

一直得到418 #22

jackcoolpython opened this issue Jul 10, 2020 · 1 comment

Comments

@jackcoolpython
Copy link

你好, 我根据你的代码, 可以使用request.get. response.status_code == 418,

这怎样修改? 求教

@HqmJoker
Copy link
Contributor

你好, 我根据你的代码, 可以使用request.get. response.status_code == 418,

这怎样修改? 求教

image
在你的请求哪里加一个请求头
response = requests.get(url,headers={'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64)'})

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants