New answers tagged

1

Don't hard-code your URL - slice it up into parameters accepted by a function Omit the friendly baby-kid-stuff. There is a corresponding product category code, baa, that is more important to the requests and less redundant. Pass a parse_only strainer to BeautifulSoup. Move your code out of the global namespace. Why are you using Pandas? Currently it seems to ...


1

Scraping code is often ugly, and this is no exception. There's not much you can do, but it's important to work extra hard to make it readable. Error handling is missing (just throws an error), but that's okay if that's what you want. It makes things more readable. search is too long and nested too deeply. You should limit the number of layers of indentation ...


Top 50 recent answers are included