python-scraping icon indicating copy to clipboard operation
python-scraping copied to clipboard

Chapter04_CrawlingModels.ipynb, Dealing with different website layouts have wrong codes

Open yeop-sang opened this issue 4 years ago • 0 comments

line 25: body = bs.find('div', {'class', 'post-body'}).text

A Parameter named 'attrs' should be dic type, but the example code and the book has wrong codes.

I recommed change the code like body = bs.find('div', {'class': 'post-body'}).text

yeop-sang avatar Jan 14 '21 23:01 yeop-sang