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

list index out of range #33

Open
yingxincui opened this issue Jan 20, 2018 · 2 comments
Open

list index out of range #33

yingxincui opened this issue Jan 20, 2018 · 2 comments

Comments

@yingxincui
Copy link

python3 crawler.py
Traceback (most recent call last):
File "crawler.py", line 163, in
crawler.run()
File "crawler.py", line 90, in run
for index, url in enumerate(self.parse_menu(self.request(self.start_url))):
File "crawler.py", line 116, in parse_menu
menu_tag = soup.find_all(class_="uk-nav uk-nav-side")[1]
IndexError: list index out of range

@EricDuy
Copy link

EricDuy commented Apr 20, 2018

我也遇到了同样的问题,请问你解决了吗?

@zys864
Copy link

zys864 commented Jan 19, 2019

添加headers,修改user-agent

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

3 participants